projects
/
services
/
python-requests.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e91ee0e
)
Add clarification to MissingSchema error
author
Kevin Burke
<kevin@twilio.com>
Sun, 20 Oct 2013 07:46:41 +0000
(
00:46
-0700)
committer
Kevin Burke
<kevin@twilio.com>
Sun, 20 Oct 2013 07:46:41 +0000
(
00:46
-0700)
requests/models.py
patch
|
blob
|
history
diff --git
a/requests/models.py
b/requests/models.py
index ee2ca9e2b99b7ced87629dd376ed1bf5ae9a4fe2..c836c6092e9e7223b7cb058dd3d6e2f2d2c0ca22 100644
(file)
--- a/
requests/models.py
+++ b/
requests/models.py
@@
-324,7
+324,8
@@
class PreparedRequest(RequestEncodingMixin, RequestHooksMixin):
scheme, auth, host, port, path, query, fragment = parse_url(url)
if not scheme:
- raise MissingSchema("Invalid URL %r: No schema supplied" % url)
+ raise MissingSchema("Invalid URL %r: No schema supplied. "
+ "Perhaps you meant http://%s?" % (url, url))
if not host:
raise InvalidURL("Invalid URL %r: No host supplied" % url)