瀏覽代碼

Merge branch 'master' of github.com:jhao104/proxy_pool into develop

# Conflicts:
#	ProxyGetter/getFreeProxy.py
jhao 7 年之前
父節點
當前提交
a0a42375d7
共有 3 個文件被更改,包括 8 次插入8 次删除
  1. 2 2
      ProxyGetter/getFreeProxy.py
  2. 1 1
      README.md
  3. 5 5
      Run/main.py

+ 2 - 2
ProxyGetter/getFreeProxy.py

@@ -49,7 +49,7 @@ class GetFreeProxy(object):
             for ul in ul_list:
                 try:
                     ip = ul.xpath('./span[1]/li/text()')[0]
-                    classnames =  ul.xpath('./span[2]/li/attribute::class')[0]
+                    classnames = ul.xpath('./span[2]/li/attribute::class')[0]
                     classname = classnames.split(' ')[1]
                     port_sum = 0
                     for c in classname:
@@ -289,7 +289,7 @@ class GetFreeProxy(object):
 if __name__ == '__main__':
     from CheckProxy import CheckProxy
 
-    # CheckProxy.checkGetProxyFunc(GetFreeProxy.freeProxy01())
+    CheckProxy.checkGetProxyFunc(GetFreeProxy.freeProxy01)
     # CheckProxy.checkGetProxyFunc(GetFreeProxy.freeProxy02)
     # CheckProxy.checkGetProxyFunc(GetFreeProxy.freeProxy03)
     # CheckProxy.checkGetProxyFunc(GetFreeProxy.freeProxy04)

+ 1 - 1
README.md

@@ -231,7 +231,7 @@ PROXY_GETTER = [
 
   这里感谢以下contributor的无私奉献:
 
-  [@kangnwh](https://github.com/kangnwh)| [@bobobo80](https://github.com/bobobo80)| [@halleywj](https://github.com/halleywj)| [@newlyedward](https://github.com/newlyedward)| [@wang-ye](https://github.com/wang-ye)| [@gladmo](https://github.com/gladmo)| [@bernieyangmh](https://github.com/bernieyangmh)| [@PythonYXY](https://github.com/PythonYXY)| [@zuijiawoniu](https://github.com/zuijiawoniu)| [@netAir](https://github.com/netAir)| [@scil](https://github.com/scil)| [@tangrela](https://github.com/tangrela)| [@highroom](https://github.com/highroom)| [@luocaodan](https://github.com/luocaodan)| [@vc5](https://github.com/vc5)| [@1again](https://github.com/1again)
+  [@kangnwh](https://github.com/kangnwh)| [@bobobo80](https://github.com/bobobo80)| [@halleywj](https://github.com/halleywj)| [@newlyedward](https://github.com/newlyedward)| [@wang-ye](https://github.com/wang-ye)| [@gladmo](https://github.com/gladmo)| [@bernieyangmh](https://github.com/bernieyangmh)| [@PythonYXY](https://github.com/PythonYXY)| [@zuijiawoniu](https://github.com/zuijiawoniu)| [@netAir](https://github.com/netAir)| [@scil](https://github.com/scil)| [@tangrela](https://github.com/tangrela)| [@highroom](https://github.com/highroom)| [@luocaodan](https://github.com/luocaodan)| [@vc5](https://github.com/vc5)| [@1again](https://github.com/1again)| [@obaiyan](https://github.com/obaiyan)
 
 
 ### Release Notes

+ 5 - 5
Run/main.py

@@ -12,7 +12,8 @@
 """
 __author__ = 'JHao'
 
-import sys,signal
+import sys
+import signal
 from multiprocessing import Process
 
 sys.path.append('.')
@@ -31,15 +32,14 @@ def run():
     p_list.append(p2)
     p3 = Process(target=RefreshRun, name='RefreshRun')
     p_list.append(p3)
-    
-    def kill_child_processes(signum,frame):
+
+    def kill_child_processes(signum, frame):
         for p in p_list:
-           p.terminate()
+            p.terminate()
         sys.exit(1)
 
     signal.signal(signal.SIGTERM, kill_child_processes)
 
-
     for p in p_list:
         p.daemon = True
         p.start()