Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No JSON object could be decoded #5984

Closed
McaDipali opened this issue Mar 30, 2017 · 0 comments
Closed

No JSON object could be decoded #5984

McaDipali opened this issue Mar 30, 2017 · 0 comments

Comments

@McaDipali
Copy link

    data = urllib.urlencode(parameters).encode('utf-8')
    content = urllib2.urlopen(url=token_url, data=data)
    try:
        string = content.read()
        json_obj = json.loads(string.decode('utf-8'))
        print json_obj
    except ValueError as a:
        print a
    else:
        print json_obj
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

No branches or pull requests

2 participants