Home > other >  Python crawler appear below mistake how to solve
Python crawler appear below mistake how to solve

Time:09-29

Traceback (the most recent call last) :
File "C:/Users/msi/PycharmProjects untitled1/clean. Py", line 138, in & lt; module>
Get_all_house ()
The File "C:/Users/msi/PycharmProjects untitled1/clean. Py", line 133, in get_all_house
Get_houses_by_sub_district (district_name sub_district_name, sub_district_url)
The File "C:/Users/msi/PycharmProjects untitled1/clean. Py", line 62, in get_houses_by_sub_district
House_num=get_page_num (sub_district_url)
File "C:/Users/msi/PycharmProjects untitled1/clean. Py", line 53, in get_page_num
R=requests. Get (sub_district_url, headers=headers)
The File "E: \ Anaconda \ envs \ untitled1 \ lib \ site - packages/requests/API. Py", line 75, in the get
Return the request (' get 'url, params=params, * * kwargs)
File "E: \ Anaconda \ envs \ untitled1 \ lib \ site - packages/requests/API. Py", line 60, request in
Return the session. The request (method=method, url=url, * * kwargs)
The File "E: \ Anaconda \ envs \ untitled1 \ lib \ site - packages \ requests \ sessions py", line 519, in the request
Prep=self. Prepare_request (the req)
The File "E: \ Anaconda \ envs \ untitled1 \ lib \ site - packages \ requests \ sessions py", line 462, in prepare_request
Hooks=merge_hooks (request. Hooks, and the self. The hooks),
The File "E: \ Anaconda \ envs \ untitled1 \ lib \ site - packages \ requests \ models py", line 313, prepare in
Self. Prepare_url (url, params)
The File "E: \ Anaconda \ envs \ untitled1 \ lib \ site - packages \ requests \ models py", line 387, in prepare_url
Raise MissingSchema (error)
Requests. Exceptions. MissingSchema: Invalid URL 'north CAI: No schema supplied. Perhaps you meant http://north CAI?

The Process finished with exit code 1
  • Related