tomquirk / linkedin-api

👨‍💼 LinkedIn API for Python
https://pypi.org/project/linkedin-api
MIT License
1.95k stars 430 forks source link

AttributeError: 'NoneType' object has no attribute 'attrs' #273

Closed TachiMeow closed 1 year ago

TachiMeow commented 1 year ago

Trying run simple code for test API:

from linkedin_api import Linkedin

l = Linkedin('***', '***')
print(l.get_user_profile())

Error:

Traceback (most recent call last):
  File "C:\Users\***\main.py", line 3, in <module>
    l = Linkedin('***','***')
  File "C:\Users\***\lib\site-packages\linkedin_api\linkedin.py", line 69, in __init__
    self.client.authenticate(username, password)
  File "C:\Users\***\lib\site-packages\linkedin_api\client.py", line 99, in authenticate
    self._fetch_metadata()
  File "C:\Users\***\lib\site-packages\linkedin_api\client.py", line 120, in _fetch_metadata
    clientApplicationInstanceRaw = soup.find(
AttributeError: 'NoneType' object has no attribute 'attrs'