Skip to content

100% CPU and hangs after calling .content on a requests Response object #740

Open
@callumapplsys

Description

@callumapplsys

If I do this, bpython3 starts using 100% of my CPU and hangs completely until I kill it. If I run it from the python REPL, it works.

callum@destroyer2[15:59:26] ~
 $ bpython3
bpython version 0.17 on top of Python 3.6.3 /usr/bin/python3
>>> import requests
>>> r = requests.get('http://google.com')
>>> r.content

Ubuntu 17.10, bpython 0.17, Python 3.6.3, requests 2.18.4

It might be something to do with requests.get only requesting the body after calling .content, otherwise it just gets the headers.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions