Python urllib2 timeout
大家讲道理
大家讲道理 2017-04-18 10:10:42
0
2
470
大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(2)
PHPzhong

Python’s official documentation states that if you do not specify a timeout, then it will use the timeout value of the socket. And the socket is actually provided by the operating system, so the timeout value depends on the operating system.

It is possible that your task happens to be within the socket timeout of Windows but outside the socket timeout of Linux.

PHPzhong

You can print out the download link to see if there are spaces or abnormal characters in it. I have encountered this situation. Because urlopen does not support paths with spaces.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template