lastpass-python icon indicating copy to clipboard operation
lastpass-python copied to clipboard

Forced password change not indicated by error

Open nineclicks opened this issue 4 years ago • 0 comments

I had to clone and modify the library to figure out that lastpass was forcing a password update. It would be helpful if the error message was indicated in the exception.

response.status_code: 403 response.text: "Password change is required!"

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/ec2-user/lastpass-python/lastpass/vault.py", line 11, in open_remote
    blob = cls.fetch_blob(username, password, multifactor_password, client_id)
  File "/home/ec2-user/lastpass-python/lastpass/vault.py", line 29, in fetch_blob
    blob = fetcher.fetch(session)
  File "/home/ec2-user/lastpass-python/lastpass/fetcher.py", line 50, in fetch
    raise NetworkError()
lastpass.exceptions.NetworkError

nineclicks avatar Nov 11 '21 21:11 nineclicks