Merge lp:~tcole/oauth/unicode-safe into lp:oauth
Proposed by
Tim Cole
Status: | Needs review |
---|---|
Proposed branch: | lp:~tcole/oauth/unicode-safe |
Merge into: | lp:oauth |
Diff against target: |
19 lines (+2/-2) 1 file modified
oauth/oauth.py (+2/-2) |
To merge this branch: | bzr merge lp:~tcole/oauth/unicode-safe |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
VCS imports | Pending | ||
Review via email: mp+62731@code.launchpad.net |
Description of the change
Some software insists on putting (ascii subset) unicode strings through oauth; this has worked until now, but blows up under python 2.7. (Because HMAC doesn't work with unicode objects.)
To post a comment you must log in.
At the moment you are encoding them using whatever Python's default 'ascii' ,
is. I think it would be both a bit clearer and a bit less likely to
cause confusing errors if you instead made it thing.encode(
'error') if they're really required to be always ascii safe.