aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2015-12-16 19:10:07 -0500
committerJason R. Coombs <jaraco@jaraco.com>2015-12-16 19:10:07 -0500
commit156bf219d2e9c99b3a241fa59dd4c652cfa90a45 (patch)
tree16108498ae58033fb1fde3ffbef9f76e90ccadc9
parentd8a425e00d05c0cd0896b6e684b18304c6bbf717 (diff)
downloadexternal_python_setuptools-156bf219d2e9c99b3a241fa59dd4c652cfa90a45.tar.gz
external_python_setuptools-156bf219d2e9c99b3a241fa59dd4c652cfa90a45.tar.bz2
external_python_setuptools-156bf219d2e9c99b3a241fa59dd4c652cfa90a45.zip
Explicitly quote strings rather than relying on repr. Fixes #477.
-rw-r--r--CHANGES.txt3
-rw-r--r--ez_setup.py2
2 files changed, 4 insertions, 1 deletions
diff --git a/CHANGES.txt b/CHANGES.txt
index 3764d799..48fc18a9 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -9,6 +9,9 @@ CHANGES
* Issue #476: Cast version to string (using default encoding)
to avoid creating Unicode types on Python 2 clients.
+* Issue #477: In Powershell downloader, use explicit rendering
+ of strings, rather than rely on ``repr``, which can be
+ incorrect (especially on Python 2).
----
19.1
diff --git a/ez_setup.py b/ez_setup.py
index 39ea44bc..16f707a6 100644
--- a/ez_setup.py
+++ b/ez_setup.py
@@ -225,7 +225,7 @@ def download_file_powershell(url, target):
ps_cmd = (
"[System.Net.WebRequest]::DefaultWebProxy.Credentials = "
"[System.Net.CredentialCache]::DefaultCredentials; "
- "(new-object System.Net.WebClient).DownloadFile(%(url)r, %(target)r)"
+ '(new-object System.Net.WebClient).DownloadFile("%(url)s", "%(target)s")'
% vars()
)
cmd = [