MCPcopy
hub / github.com/nghuyong/WeiboSpider / fetch_proxy

Method fetch_proxy

weibospider/middlewares.py:10–16  ·  view source on GitHub ↗

获取一个代理IP

()

Source from the content-addressed store, hash-verified

8
9 @staticmethod
10 def fetch_proxy():
11 """
12 获取一个代理IP
13 """
14 # You need to rewrite this function if you want to add proxy pool
15 # the function should return an ip in the format of "ip:port" like "12.34.1.4:9090"
16 return None
17
18 def process_request(self, request, spider):
19 """

Callers 1

process_requestMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected