Skip to content

Conversation

lennartkaden
Copy link
Owner

Add error handling to the refresh_tokens function in GroheClient/base.py to retry the token refresh process up to 3 times with a 5-second delay between attempts.

  • Import the time module.
  • Modify the refresh_tokens function to include a retry mechanism with up to 3 attempts and a 5-second delay between attempts.
  • Add logging for each failed attempt and a final error log if the token refresh process fails after 3 attempts.

Add error handling to the `refresh_tokens` function in `GroheClient/base.py` to retry the token refresh process up to 3 times with a 5-second delay between attempts.

* Import the `time` module.
* Modify the `refresh_tokens` function to include a retry mechanism with up to 3 attempts and a 5-second delay between attempts.
* Add logging for each failed attempt and a final error log if the token refresh process fails after 3 attempts.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant