Closed ajmarroquin closed 1 year ago
It looks like you're using the mintapi/mintapi repo. ynam is using a newer version that isn't yet out on mintapi/mintapi:main, so for now install it from snowskeleton/mintapi. That should fix your issue.
Appreciate the quick reply. I've cloned ynam
and mintapi
from your repos and installed them from there.
after doing so when running I get the following errors
do you have chromium installed?
per the mintapi readme, chromium-browser
and chromium-chromedriver
both need to be installed. they're available from apt-get and other package managers. The error you're getting is one usually associated with not having chromium installed and/or not having it on your PATH
good catch. I am NOT a chrome user, so had no version of chromium installed. I hadn't dove into the mintapi repo to see that req. I just installed chrome, re-ran and it popped open the browser and let me log in. it still seems to be getting stuck on that line 41 of mint_api.py
and never pulls the transactions
I moved the cookies
and api_key
to the home directory rather than worry about potentially non-existent sub-directories.
give this a try and see if it works?
that resolved it. was able to use ynam --graphics
to get past the first login, and then after that used ynam --days 20 --graphics
and it sent over the last 20 days of transactions to my test budget that I had set up. It DIDN'T actually launch the graphical version on the second command but completed the task.
good fix! thanks for the quick work
Also, I'm the rare case of not having any version of chromium installed, but maybe worth dropping a note in the readme for this repo that calls out the need for anyone in the future who is in the same boat!
I'm glad it worked!
Some background on the --graphics
flag. It's only relevant if you haven't run ynam recently. Those cookies and api_key you were having trouble writing can be used to complete most functions through the REST API. That's why the browser didn't come up the second time. ynam will always try the REST call first, and only if that fails will it login with the browser to update the cookies and key. And then it'll retry the REST call. All that to say, the behavior you're seeing is expected.
Also, I'm the rare case of not having any version of chromium installed, but maybe worth dropping a note in the readme for this repo that calls out the need for anyone in the future who is in the same boat!
Good idea! It would probably be even better to have ynam check if it's installed, and prompt you to install it if missing.
First off, thank you very much for the work here, this is something that YNAB needs to implement themselves, and appreciate someone stepping in and making an effort here!
I was able to clone from GitHub, and run the
ynam --quickstart
, and set up my account. it looks like its authorized into my YNAB account as it appropriately grabbed the budget and account names, but I didn't know how to verify if it was connecting with Mint.When attempting to run
ynam
I get these errorsynam Traceback (most recent call last): File "/usr/local/bin/ynam", line 8, in <module> sys.exit(main()) File "/usr/local/lib/python3.10/site-packages/ynam/main.py", line 20, in main mapi = MintAPI() File "/usr/local/lib/python3.10/site-packages/ynam/mint_api.py", line 10, in __init__ self.restClient = mintapi.RESTClient AttributeError: module 'mintapi' has no attribute 'RESTClient'
I attempted to install
mintapi
itself to see if that would update the failed attribute, but no change in error.