materials
materials copied to clipboard
AsyncIO only prints the single url
The https://www.jython.org
url is never downloaded based on what is printed out
Steps to recreate:
git clone [email protected]:realpython/materials.git real_python_materials
cd real_python_materials/
python3.6 -m venv 36env
source 36env/bin/activate
pip install aiohttp
Running the script:
python io_asyncio.py
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Read 273 from http://olympus.realpython.org/dice
Downloaded 160 sites in 3.151465892791748 seconds
Hmm. Possible that it was down? What did "wget www.jython.org" do? It's working for me presently.
If it's still failing, feel free to substitute a different URL, that particular one isn't critical, just something to download. :)
wget gives me: Unable to establish SSL connection.
Strange that python io_threading.py
work's correctly with python requests.
I just checked and the threading
version is using https as well. Perhaps requests
is doing something smarter about SSL certs than aiohttp
is. That seems the likely candidate.