chore(python): stop sending `DebugLinkResetDebugEvents`
What changed, and why it matters
This is a small cleanup change in Trezor's Python test library. It removes a deprecated debug-only helper function and a parameter used only in testing. There is no indication this affects real user wallets, transactions, or device security.
No security action needed. Treat as routine maintenance/cleanup of test infrastructure.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The commit removes DebugLinkResetDebugEvents handling and the wait_for_external_change parameter from wait_layout() in python/src/trezorlib/debuglink.py. The removed functionality was already deprecated in commit 0e8dcbb498bac95997e70aa8c3ea4d522779c7c2 and is part of the debug/test harness, not production firmware code. The change reduces client-side code by 10 lines and adds 1 line.
Changed components
python/src/trezorlib/debuglink.pyInspect captured patch +1 / −10
diff --git a/python/src/trezorlib/debuglink.py b/python/src/trezorlib/debuglink.py
index 8a3e78fb..24522a15 100644
--- a/python/src/trezorlib/debuglink.py
+++ b/python/src/trezorlib/debuglink.py
@@ -682,14 +682,10 @@ class DebugLink:
wait_type = None
return LayoutContent(self.state(wait_type=wait_type).tokens)
- def wait_layout(self, wait_for_external_change: bool = False) -> LayoutContent:
+ def wait_layout(self) -> LayoutContent:
# Next layout change will be caused by external event
# (e.g. device being auto-locked or as a result of device_handler.run_with_session(xxx))
# and not by our debug actions/decisions.
- # Resetting the debug state so we wait for the next layout change
- # (and do not return the current state).
- if wait_for_external_change:
- self.reset_debug_events()
obj = self._call(
messages.DebugLinkGetState(wait_layout=DebugWaitType.NEXT_LAYOUT),
@@ -738,11 +734,6 @@ class DebugLink:
wait=False,
)
- def reset_debug_events(self) -> None:
- # Only supported on TT and above certain version
- if (self.model is not models.T1B1) and not self.legacy_debug:
- self._call(messages.DebugLinkResetDebugEvents(), expect=messages.Success)
-
def synchronize_at(
self, layout_text: str | list[str], timeout: float = 5
) -> LayoutContent:
Why this scored 13/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.