diff options
author | Per Lundberg <per.lundberg@ecraft.com> | 2016-05-31 21:04:01 +0300 |
---|---|---|
committer | Per Lundberg <per.lundberg@ecraft.com> | 2016-05-31 21:04:04 +0300 |
commit | 70b64d654b3a24f4df96e2eb168425de8b1cde10 (patch) | |
tree | f83565d2884314fb9a7b217c5e7331d52d13c1ce /python/servo/bootstrap_commands.py | |
parent | 55b0bb027caba9ca4f3fb091c55a53c24380dccb (diff) | |
download | servo-70b64d654b3a24f4df96e2eb168425de8b1cde10.tar.gz servo-70b64d654b3a24f4df96e2eb168425de8b1cde10.zip |
Provide a better error message when downloading rustc fails
I was running into the error below locally. The previous version of the code hid away important details that helps when debugging; hence, this suggested change.
> Error downloading Rust compiler: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590). URL: https://static-rust-lang-org.s3.amazonaws.com/dist/2016-05-17/rustc-nightly-x86_64-pc-windows-gnu.tar.gz
Diffstat (limited to 'python/servo/bootstrap_commands.py')
-rw-r--r-- | python/servo/bootstrap_commands.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/python/servo/bootstrap_commands.py b/python/servo/bootstrap_commands.py index 5630b778771..659826fea66 100644 --- a/python/servo/bootstrap_commands.py +++ b/python/servo/bootstrap_commands.py @@ -69,8 +69,8 @@ def download(desc, src, writer, start_byte=0): print("No Rust compiler binary available for this platform. " "Please see https://github.com/servo/servo/#prerequisites") sys.exit(1) - except urllib2.URLError: - print("Error downloading Rust compiler; are you connected to the internet?") + except urllib2.URLError, e: + print("Error downloading Rust compiler: " + str(e.reason) + ". The failing URL was: " + src) sys.exit(1) except KeyboardInterrupt: writer.flush() |