Skip to content
This repository has been archived by the owner on Jul 12, 2023. It is now read-only.

Commit

Permalink
fix incorrect calculation on timeout give up count
Browse files Browse the repository at this point in the history
  • Loading branch information
mjmeli committed Jan 6, 2023
1 parent 4a033b0 commit b000454
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = pyduke-energy
version = 1.0.4
version = 1.0.5
author = Michael Meli
author_email = [email protected]
description = Python Wrapper for unofficial Duke Energy REST API
Expand Down
2 changes: 1 addition & 1 deletion src/pyduke_energy/const.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
MESSAGE_TIMEOUT_RETRY_COUNT = 3

# number of times a message timeout can occur before we totally give up (allow 2 fastpolls)
MESSAGE_TIMEOUT_GIVE_UP_COUNT = ((FASTPOLL_TIMEOUT_MIN * 60) / MESSAGE_TIMEOUT_SEC) + 1
MESSAGE_TIMEOUT_GIVE_UP_COUNT = 2 * FASTPOLL_TIMEOUT_MIN * 60 / MESSAGE_TIMEOUT_SEC

# in minutes, minimum amount of time to wait before retrying connection on forever loop
FOREVER_RETRY_MIN_MINUTES = 1
Expand Down

0 comments on commit b000454

Please sign in to comment.