Skip to content
Myr

Use complexjson everywhere

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Cory Benfield · committed by Cory Benfield · parent fb6dade · Browse files · 1 file+4 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+4 added−2 removed

  • other:+4 added−2 removed

1 file+4 added−2 removed

modified:requests/models.py+4 added-2 removed
790 unmodified lines
791 # a best guess).792 encoding = guess_json_utf(self.content)793 if encoding is not None:794 try:795 return json.loads(self.content.decode(encoding), **kwargs)795 return complexjson.loads(796 self.content.decode(encoding), **kwargs797 )798 except UnicodeDecodeError:799 # Wrong UTF codec detected; usually because it's not UTF-8800 # but some other 8-bit codec. This is an RFC violation,801 # and the server didn't bother to tell us what codec *was*802 # used.803 pass802 return json.loads(self.text, **kwargs)804 return complexjson.loads(self.text, **kwargs)805806 @property807 def links(self):808 """Returns the parsed header links of the response, if any."""
36 unmodified lines