Explorar o código

if filter()的判断在python3中返回为filter对象,即使为空,if判断也会判定为True

bobobo80 %!s(int64=9) %!d(string=hai) anos
pai
achega
a6d40f7970
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      Util/WebRequest.py

+ 1 - 0
Util/WebRequest.py

@@ -79,6 +79,7 @@ class WebRequest(object):
                         raise Exception
                 return html
             except Exception as e:
+                print(e)
                 retry_time -= 1
                 if retry_time <= 0:
                     return