MCPcopy
hub / github.com/wistbean/learn_python3_spider / request_page

Function request_page

meizitu.py:26–32  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

24
25
26def request_page(url):
27 try:
28 response = requests.get(url)
29 if response.status_code == 200:
30 return response.text
31 except requests.RequestException:
32 return None
33
34
35def get_page_urls():

Callers 2

get_page_urlsFunction · 0.85
downloadFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected