Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix to refresh sts token at 80% of TTL for issue #2031 #2035

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

chenxg283
Copy link

Fix for issue #2031

  1. merge the common code to refresh the sts token in one if-block, i.e. either when sts token not present or when the token is going to expire soon;
  2. replanced the datetime.utcnow() as it is deprecated;
  3. refresh the sts token at 80% of its TTL.

@auvipy auvipy self-requested a review June 25, 2024 06:46
Copy link
Member

@auvipy auvipy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we will need extensive test coverage to very this changes

@Nusnus Nusnus marked this pull request as draft June 25, 2024 12:57
@Nusnus
Copy link
Member

Nusnus commented Jun 25, 2024

we will need extensive test coverage to very this changes

I am 100% with @auvipy here. I’ve converted the PR to draft until tests can be added.

Thank you and I hope you understand @chenxg283 🙏

@chenxg283
Copy link
Author

Sorry, i am new to this. Am I supposed to write the code for the test coverage?

@Nusnus
Copy link
Member

Nusnus commented Jun 30, 2024

Sorry, i am new to this.

It’s fine :)

Am I supposed to write the code for the test coverage?

Yes, you need to add automatic tests (that the CI will run automatically, but you can also run locally using tox).
These tests need to validate that the changes the PR introduces are indeed working as expected. They also need to ensure that there are no bugs, to the best reasonable effort possible.

You can see the existing test suites to check how other tests are implemented.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants