From 4e6ba352ff8ad4fb933a9c505fc90e65518f5a89 Mon Sep 17 00:00:00 2001 From: matejcik Date: Sun, 7 Apr 2024 14:15:53 +0200 Subject: [PATCH] style: fix complaining lints & formatters --- core/embed/rust/src/ui/model_tr/layout.rs | 8 ++++++-- python/src/trezorlib/debuglink.py | 3 +-- tests/input_flows.py | 4 ++-- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/core/embed/rust/src/ui/model_tr/layout.rs b/core/embed/rust/src/ui/model_tr/layout.rs index dfab12fe9..b50974fcb 100644 --- a/core/embed/rust/src/ui/model_tr/layout.rs +++ b/core/embed/rust/src/ui/model_tr/layout.rs @@ -32,14 +32,18 @@ use crate::{ ui::{ backlight::BACKLIGHT_LEVELS_OBJ, component::{ - base::Component, connect::Connect, paginated::{PageMsg, Paginate}, text::{ + base::Component, + connect::Connect, + paginated::{PageMsg, Paginate}, + text::{ op::OpTextLayout, paragraphs::{ Checklist, Paragraph, ParagraphSource, ParagraphVecLong, ParagraphVecShort, Paragraphs, VecExt, }, TextStyle, - }, ComponentExt, FormattedText, Label, LineBreaking, Never, Timeout + }, + ComponentExt, FormattedText, Label, LineBreaking, Never, Timeout, }, geometry, layout::{ diff --git a/python/src/trezorlib/debuglink.py b/python/src/trezorlib/debuglink.py index fdb009c49..677e8aeb2 100644 --- a/python/src/trezorlib/debuglink.py +++ b/python/src/trezorlib/debuglink.py @@ -67,8 +67,7 @@ if TYPE_CHECKING: self, hold_ms: Optional[int] = None, wait: Optional[bool] = None, - ) -> "LayoutContent": - ... + ) -> "LayoutContent": ... EXPECTED_RESPONSES_CONTEXT_LINES = 3 diff --git a/tests/input_flows.py b/tests/input_flows.py index becdb5227..9bd1f97be 100644 --- a/tests/input_flows.py +++ b/tests/input_flows.py @@ -100,7 +100,7 @@ class InputFlowSetupDevicePINWIpeCode(InputFlowBase): if self.model() is models.T2B1: layout = self.debug.read_layout() - if not "PinKeyboard" in layout.all_components(): + if "PinKeyboard" not in layout.all_components(): yield from swipe_if_necessary(self.debug) # wipe code info self.debug.press_yes() @@ -131,7 +131,7 @@ class InputFlowNewCodeMismatch(InputFlowBase): if self.model() is models.T2B1: layout = self.debug.read_layout() - if not "PinKeyboard" in layout.all_components(): + if "PinKeyboard" not in layout.all_components(): yield from swipe_if_necessary(self.debug) # code info self.debug.press_yes()