Skip to content

Commit 778bd57

Browse files
Transient retries should no longer be transient on the last try
1 parent f209311 commit 778bd57

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎src/runtime.py‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ def loop(self):
6868
logging.exception(f"Error processing reader {reader.name}: {e}")
6969
scan_result, filament, retry = None, None, False # Assume exceptions are not transient
7070

71+
if retry and self.read_retries_left[i] <= 1:
72+
retry = False # Don't allow retry if this is the last retry left
73+
7174
if filament:
7275
logging.info(f"Successfully read tag with UID {scan_result.uid.hex().upper()} on reader {reader.name}")
7376
self._notify_exporters(scan_result, filament, reader, ExporterEvent.TAG_READ)

0 commit comments

Comments
 (0)