I use metaflow with S3. In order to access S3, I need to login with AWS CLI single sign on (aws sso login). The problem is that I have no way to force "refresh" (not sure about correct terminology) of the login.
Problem example:
Set SSO timeout to 24 hours.
Day 1. Login at 10am with aws sso login
Day 2. I want to set a program running at 9am. Login again with aws sso login. Token is still valid. I set a metaflow flow running. At 10am, token expires and crashes my run because I can no longer access S3.
How can I prevent this? I have not been able to find anything with google. Should I just manually and delete the tokens in ~/.aws/sso/cache?
I also have long running jobs that take more than 24 hours.