Commit Graph

1027 Commits

Author SHA1 Message Date
John Peacock c5fddb95ed Only return a path if the cacert.pem file exists.
This will permit the deletion of just that one file in order
to fall back to the [probably more accurate but less consistent]
Distro provided CA certs.
2012-11-21 13:34:03 -05:00
Kenneth Reitz 50877717c8 Merge pull request #940 from Lukasa/issue917
Update docs to reflect use of params
2012-11-17 03:03:32 -08:00
Cory Benfield 0792acc130 Update documentation on Sessions.
This resolves issue #870. Better documentation here should be considered
for further work.
2012-11-17 10:57:26 +00:00
Cory Benfield c8b2f7a37b Update docs to reflect use of params
Resolves issue #917.
2012-11-16 23:05:35 +00:00
Kenneth Reitz dea8e96bd5 Merge pull request #925 from russelldavis/fix-encoding
Fix a bug in _encode_params
2012-11-15 02:13:30 -08:00
Pavel Dmitriev a02f3dec02 Fix for user-agent setting 2012-11-13 17:40:13 +02:00
Max Countryman 32aa3eb012 adding UTF-8 status codes 2012-11-08 14:30:13 -08:00
Russell Davis ccf4ca8929 Fix a bug in _encode_params - it wasn't utf-8 encoding strings in values that
are iterable but not a list.
2012-11-03 12:58:04 -07:00
Kenneth Reitz 28dc725cfe Merge pull request #909 from mjpieters/issue765-json-encodings
Use a JSON-specific encoding detection when no encoding has been specified
2012-10-27 08:02:55 -07:00
Jonathan Halcrow 724a3889bc Make sure that url has fragment removed when using a proxy 2012-10-27 09:54:31 -04:00
Martijn Pieters 4decc7986e Use a JSON-specific encoding detection when no encoding has been specified.
JSON *must* be encoded using UTF-8, UTF-16 or UTF-32 (see the [RFC][1]; detect the encoding based on the fact that JSON always starts with 2 ASCII characters.

[1]: http://tools.ietf.org/html/rfc4627#section-3
2012-10-25 17:43:52 +02:00
Lasse Vang Gravesen b36863b2c0 quote_plus, unquote_plus added
compat.py: relevant imports added
utils.py: then those imports are imported here.

Nothing else was changed, but I saw mentions of quoting later in
utils.py but I wasnt sure what to do about that.
2012-10-22 23:58:49 +02:00
Kenneth Reitz cfa83f6214 Merge pull request #903 from building39/issue-901
Issue 901:
2012-10-21 08:52:03 -07:00
Gabriel c03553ed4a Remove path hacks that break chardet in Python 3. Closes #858.
This replaces the sys.path hack with a slightly less objectionable
sys.modules hack.

Both have the effect of making the vendored lib's absolue imports work
as expected when oauthlib isn't installed. The sys.modules hack doesn't
insert the rest of the vendored crap in a global path, however.
2012-10-21 17:07:12 +02:00
mmartin 4dfa51ae03 Issue 901:
Make value of Contents-Encoding header case insensitive per RFC 2616.
2012-10-19 14:17:32 -05:00
Kenneth Reitz aa08f33f98 Merge pull request #884 from everbird/develop
Support CJK parameters when post files
2012-10-17 07:21:39 -07:00
Radu Voicilas 820dfb0495 Making the code more PEP8 compliant 2012-10-09 00:42:49 +03:00
tokuda109 5ec2c96f02 declare the encoding 2012-10-09 00:42:49 +03:00
Ian Cordasco 4e6cf21d82 Only register callable items in lists
Prior to this, you could sneak a list of anything to register_hook and it
would accept it. This will check if the items in the list are callable before
registering them. Also added a regression test to make sure if this gets
changed it will be noticed.
2012-10-09 00:42:49 +03:00
Kenneth Reitz ed8a3f3199 v0.14.1 2012-10-09 00:42:48 +03:00
yegle 22fdecba52 Update: @property decorator instead of __getattr__ 2012-10-09 00:42:48 +03:00
Kunal Mehta 4f9e552148 Use __iter__ rather than the inefficient nested for loops 2012-10-09 00:42:48 +03:00
yegle e656222188 Python 3.3 compatible update
httplib.cookiejar.DefaultCookiePolicy changed its implementation of
set_ok_verifiability.
2012-10-09 00:42:48 +03:00
Matt Sweeney eb6a6b1a23 Simplify error handling when decoding unicode 2012-10-09 00:42:48 +03:00
Matt Sweeney 2bb49ff386 Handle encoding of None when decoding unicode
If encoding is None, decoding will throw the following TypeError:
TypeError: unicode() argument 2 must be string, not None

If this is the case, attempt to run without any set encoding
2012-10-09 00:42:48 +03:00
Stephen Zhuang 86b39bf3e3 Support CJK parameters when post files 2012-10-08 16:52:06 +08:00
tokuda109 601a2b8c74 declare the encoding 2012-10-02 23:26:29 +09:00
Ian Cordasco 77677eb71d Only register callable items in lists
Prior to this, you could sneak a list of anything to register_hook and it
would accept it. This will check if the items in the list are callable before
registering them. Also added a regression test to make sure if this gets
changed it will be noticed.
2012-10-01 14:05:27 -04:00
Kenneth Reitz 9dce786113 v0.14.1 2012-10-01 13:29:38 -04:00
Kenneth Reitz 6d706378a0 Merge pull request #871 from yegle/develop
Python 3.3 compatible update
2012-10-01 10:26:58 -07:00
yegle 170c46c06b Update: @property decorator instead of __getattr__ 2012-10-01 13:13:12 -04:00
Kenneth Reitz af61205e72 Merge pull request #867 from mattswe/patch-1
Handle encoding of `None` when decoding unicode
2012-10-01 09:53:56 -07:00
Kunal Mehta 5cd116d078 Use __iter__ rather than the inefficient nested for loops 2012-09-30 19:24:56 -05:00
yegle 992d1182db Python 3.3 compatible update
httplib.cookiejar.DefaultCookiePolicy changed its implementation of
set_ok_verifiability.
2012-09-29 18:28:53 -04:00
Matt Sweeney 38aced9f90 Simplify error handling when decoding unicode 2012-09-26 12:38:36 -07:00
Matt Sweeney b1610df282 Handle encoding of None when decoding unicode
If encoding is None, decoding will throw the following TypeError:
TypeError: unicode() argument 2 must be string, not None

If this is the case, attempt to run without any set encoding
2012-09-25 15:35:30 -07:00
Kenneth Reitz 5ce25688e0 Revert "Fix SSL3 error on Ubuntu 12.04"
This reverts commit c19650b00f.
2012-09-24 11:05:53 -05:00
Kenneth Reitz 1b70385d4a change default accept-encoding
http://blogs.operationaldynamics.com/andrew/software/research/testing-re
stful-apis-with-httpie
2012-09-23 12:41:54 -05:00
Ian Cordasco 4dd3d1a1a2 Fix #785 & add regression test. 2012-09-20 11:45:03 -04:00
Kenneth Reitz d70964a608 Merge pull request #848 from barberj/develop
None is not iterable
2012-09-12 10:58:20 -07:00
Eric Hansen 65c19bc0e0 Fix for v3 in deleting empty proxies. 2012-09-12 13:49:34 -04:00
Eric Hansen 2dc7db4730 Fixed issue with empty proxies being passed 2012-09-11 15:40:16 -04:00
barberj fc1d0fedea None is not iterable 2012-09-11 08:39:10 -04:00
Kenneth Reitz b7c3945437 Merge pull request #820 from dergraf/develop
Data encoding should take place after calling into auth provider
2012-09-10 20:06:52 -07:00
Kenneth Reitz 2ae7c5a547 Merge pull request #833 from sigmavirus24/fix_key_val_args
Fixes #817.
2012-09-10 20:05:07 -07:00
Alan Hamlett 861e63ce8e fixed typo in docs 2012-09-09 01:56:32 -07:00
Ian Cordasco 8081d7b15c Fixes #817.
Use dicts and lists where necessary but accept both dicts and lists of
2-tuples everywhere.
2012-09-02 23:10:28 -04:00
Kenneth Reitz c8f166f696 Merge remote-tracking branch 'origin/develop' into develop 2012-09-02 04:50:30 -04:00
Kenneth Reitz a69cf7e71c v0.14.0 2012-09-02 04:50:05 -04:00
Shivaram Lingamneni 77cf995165 permissive implementation of iter_content
This allows iter_content and iter_lines to succeed without
crashing even after the response content has been fetched
(iter_content gives you an iterator over the prefetched
content)
2012-09-02 01:42:30 -07:00