Skip to content

Commit

Permalink
Merge branch 'master' of github.com:jhao104/proxy_pool into develop
Browse files Browse the repository at this point in the history
# Conflicts:
#	ProxyGetter/getFreeProxy.py
  • Loading branch information
jhao104 committed Jul 19, 2019
1 parent a58978e commit a0a4237
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions ProxyGetter/getFreeProxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def freeProxy01():
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:
Expand Down Expand Up @@ -289,7 +289,7 @@ def freeProxy09(page_count=2):
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)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
10 changes: 5 additions & 5 deletions Run/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"""
__author__ = 'JHao'

import syssignal
import sys
import signal
from multiprocessing import Process

sys.path.append('.')
Expand All @@ -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()
Expand Down

0 comments on commit a0a4237

Please sign in to comment.