Fix error message when Python isn't properly configured to proxy server.
Review Request #7689 — Created Oct. 10, 2015 and discarded
Better handled 'URLError' error message by placing line 'data = e.read()' in try block instead of outside of it. This way, when there is a URLError exception, it will not raise an error with URLError calling read().
Tested by reloading browser (Chrome).
Ran ./reviewboard/manage.py test -- reviewboard.hostingsvcs.tests and all 167 tests passed.
Description | From | Last Updated |
---|---|---|
Should probably put this newline back |
mike_conley | |
'KilnClient' imported but unused |
reviewbot | |
Thanks for the test! This is fantastic. Is it possible to write a similar test for the GitHub hosting service? |
mike_conley | |
Please remove this line (so there's no blank line at the top of the function). |
david | |
Please remove this line. |
david | |
Here too. |
david | |
Can you sort these in alphabetical order? |
david | |
Should be "GitHub". |
david | |
This isn't testing anything. You're never actually calling any of the functions. It's not even taking all the required arguments. … |
chipx86 | |
Same here. |
chipx86 | |
Col: 80 E501 line too long (97 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (101 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (110 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (114 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (84 > 79 characters) |
reviewbot | |
Col: 9 E265 block comment should start with '# ' |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 13 E116 unexpected indentation (comment) |
reviewbot | |
Col: 13 E265 block comment should start with '# ' |
reviewbot | |
Col: 80 E501 line too long (97 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (101 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (110 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (114 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (84 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (88 > 79 characters) |
reviewbot | |
Col: 9 E265 block comment should start with '# ' |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 13 E116 unexpected indentation (comment) |
reviewbot | |
Col: 13 E265 block comment should start with '# ' |
reviewbot |
-
Tool: Pyflakes Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Tool: PEP8 Style Checker Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py
-
-
Tool: Pyflakes Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Tool: PEP8 Style Checker Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py
-
Tool: Pyflakes Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Tool: PEP8 Style Checker Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py
-
The change description should be a more high level overview of the change instead of indicating what lines were moved where. Have a look at https://www.reviewboard.org/docs/codebase/dev/writing-good-descriptions/
Other than that, this change looks fine to me :)
-
-
This isn't testing anything. You're never actually calling any of the functions. It's not even taking all the required arguments. That leads me to believe this wasn't actually tested.
Make sure you trigger something that will raise the
URLError
. I want to see a workingassertRaises
, and an assertion thatservice.client.http_get
was called. -
-
Tool: Pyflakes Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Tool: PEP8 Style Checker Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py
-
Tool: Pyflakes Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Tool: PEP8 Style Checker Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py
-
-
-
-
-
-
-
-
-
-
Tool: Pyflakes Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Ignored Files: docs/bugfix_wrapup.txt Tool: PEP8 Style Checker Processed Files: reviewboard/hostingsvcs/github.py reviewboard/hostingsvcs/kiln.py reviewboard/hostingsvcs/tests.py Ignored Files: docs/bugfix_wrapup.txt
-
-
-
-
-
-
-
-
-
-