Feb-13-2019, 01:55 PM
Removing the line
s.settimeout(1)solved the problem, I now have similar performance with Python 2.7 and Python 3.7. Why, I don't know.