Skip to content

Conversation

@Finistere
Copy link

@Finistere Finistere commented Jul 24, 2016

I had the following issue with Python 3 without this modification:

TypeError: the JSON object must be str, not 'bytes'

It seems to work nicely with Python 3.5.1 and Python 2.7.11.
But I might have needed the change due to a misconfiguration of my test server...

@coveralls
Copy link

coveralls commented Jul 24, 2016

Coverage Status

Coverage increased (+0.02%) to 96.109% when pulling c620e3d on Finistere:master into 33eb832 on toidi:master.

@adamkewley
Copy link

I encountered the same bug also, and (stupidly) implemented a fix before seeing this PR:

#13

The fix is similar, but ripped from an SO post, which gets the content encoding from the HTTP response header (and defaults to utf-8 if not present)

@ediskandarov-cur
Copy link
Collaborator

Hi @adamkewley thanks for the PR,
I'll try to restore access to pypi project and will review the code afterwards pypi/warehouse#4637

@lresende
Copy link
Collaborator

This might become obsolete with PR #16 and move to use requests package.

@dimon222
Copy link
Collaborator

This can be probably already closed since this code is no longer present (due to direct call to json() via requests)

@kevin-bates
Copy link
Member

This code is no longer applicable - closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants