I've moved to 2.0.0 some time ago, and I'm aware that browser login is utilized to create a cookiejar for python-myfitnesspal use.
However, what's the best way to ensure continued use if (for example) this is deployed on a headless machine?
So far I've solved it by creating a script that generates a cookie jar by pickle.dump(client.session.cookies,filehandler) to dump the cookiejar to file, and myfitnesspal.Client(cookiejar=jar) on the other side to load and unpickle the cookiejar from file.
That being said, I'm still getting frequent auth issues...is there any way to extend login session time? Thanks and a happy new year!
I've moved to 2.0.0 some time ago, and I'm aware that browser login is utilized to create a cookiejar for python-myfitnesspal use. However, what's the best way to ensure continued use if (for example) this is deployed on a headless machine? So far I've solved it by creating a script that generates a cookie jar by
pickle.dump(client.session.cookies,filehandler)
to dump the cookiejar to file, andmyfitnesspal.Client(cookiejar=jar)
on the other side to load and unpickle the cookiejar from file.That being said, I'm still getting frequent auth issues...is there any way to extend login session time? Thanks and a happy new year!