Skip to content
This repository was archived by the owner on May 21, 2025. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions codecov/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,22 @@
except ImportError: # pragma: no cover
from urllib import urlencode

try:
from shlex import quote
except ImportError: # pragma: no cover
from pipes import quote
quote = None
if sys.platform == 'win32': # pragma: no cover
try:
# https://github.com/python/cpython/blob/3.7/Lib/subprocess.py#L174-L175
from subprocess import list2cmdline

def quote(arg):
return list2cmdline([arg])
except ImportError:
pass

if quote is None:
try:
from shlex import quote
except ImportError: # pragma: no cover
from pipes import quote

import subprocess

Expand Down