mintapi: InvalidElementStateException when logging in
Currently getting InvalidElementStateException error when trying to use the API. The script was functioning for months until last week, so this is likely due to a change on the Mint website.
Traceback (most recent call last):
File "C:\ProgramData\Anaconda3\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 827, in runfile
execfile(filename, namespace)
File "C:\ProgramData\Anaconda3\lib\site-packages\spyder_kernels\customize\spydercustomize.py", line 110, in execfile
exec(compile(f.read(), filename, 'exec'), namespace)
File "C:/Users/henryholiday/Documents/mint_analysis.py", line 550, in <module>
imap_folder = 'INBOX'
File "C:\ProgramData\Anaconda3\lib\site-packages\mintapi\api.py", line 373, in __init__
wait_for_sync_timeout=wait_for_sync_timeout)
File "C:\ProgramData\Anaconda3\lib\site-packages\mintapi\api.py", line 461, in login_and_get_token
wait_for_sync_timeout=wait_for_sync_timeout)
File "C:\ProgramData\Anaconda3\lib\site-packages\mintapi\api.py", line 233, in get_web_driver
email_input.clear()
File "C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\remote\webelement.py", line 95, in clear
self._execute(Command.CLEAR_ELEMENT)
File "C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\remote\webelement.py", line 633, in _execute
return self._parent.execute(command, params)
File "C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 321, in execute
self.error_handler.check_response(response)
File "C:\ProgramData\Anaconda3\lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 242, in check_response
raise exception_class(message, screen, stacktrace)
InvalidElementStateException: invalid element state: Element is not currently interactable and may not be manipulated
(Session info: chrome=88.0.4324.190)
(Driver info: chromedriver=2.41.578737 (49da6702b16031c40d63e5618de03a32ff6c197e),platform=Windows NT 10.0.18363 x86_64)
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 8
- Comments: 18 (11 by maintainers)
I was seeing the same for last 2 days on all attempts so started investigating and got it working by hacking on the api code around mfa login. I had been using the 1.44 pip install and just now noticed that is a 6 month old build while the src here is more up to date and handled my first hurdle (no password input). So switched to running from src, commented out a few elements which the code expected (ie no mfa choice for me at least), and got the same “which account” screen which @KOEPKEJR saw (I also have other intuit accounts). Hard coded it to the first account and now everything is working.
I can put my hacks out on a branch, but I’m not confident that this is the same flow for everyone. If I get some time I’ll try to make my changes less hackish.
@jasonkissinger I pulled your branch and tried it out, it doesn’t resolve the issue I’ve had mentioned at https://github.com/mrooney/mintapi/issues/250 thought; the email value in not inserted into the email form field on the login page, it just hangs.
Thank you for your efforts on this.
I am attempting to go down the same hacking path that @jasonkissinger mentioned. However, when using the mintapi code I am constantly being asked to enter a 6-digit code from email. This seems to only occur when using a Selenium-managed Chromium session. Is anyone else being asked to enter an 2FA email code?