kennethreitz/requests — pull request #690 by Lukasa (2012-06-19 17:44:47+00:00)
Title: Temporary fix for unicode literal breaking test.

As discussed in #687.

I'm not really wild about this commit. The awkward `if` block mentioned in #687 is present here, which isn't lovely, as is the awkward dependence on `sys.version_info`. This also relies on the fact that the parser will only look for a method when it's called, not when it's parsed, which means that `str.decode()` won't throw `AttributeErrors` in Python 3.

This is butt-ugly, and if it had to live in the codebase for all time I would ask you not to actually pull it. If you're planning to only test against 3.3 when it's released, however, then it's probably ok.

If you (or anyone else) can think of a nicer way to use this split, by all means use it and don't accept this pull request. =D