Skip to content
Snippets Groups Projects
Commit 847bb16e authored by Mateusz Żebrak's avatar Mateusz Żebrak
Browse files

Make LockSource literal consistent with worker name

parent 3034dc37
No related branches found
No related tags found
2 merge requests!601Async guard,!600v1.27.5.21 Release
...@@ -9,7 +9,7 @@ if TYPE_CHECKING: ...@@ -9,7 +9,7 @@ if TYPE_CHECKING:
from clive.__private.core.wallet_container import WalletContainer from clive.__private.core.wallet_container import WalletContainer
from clive.__private.core.world import World from clive.__private.core.world import World
LockSource = Literal["beekeeper_monitoring_thread", "unknown"] LockSource = Literal["beekeeper_wallet_lock_status_update_worker", "unknown"]
@dataclass @dataclass
......
...@@ -271,7 +271,7 @@ class TUIWorld(World, CliveDOMNode): ...@@ -271,7 +271,7 @@ class TUIWorld(World, CliveDOMNode):
self.node.change_related_profile(profile) self.node.change_related_profile(profile)
def _on_going_into_locked_mode(self, source: LockSource) -> None: def _on_going_into_locked_mode(self, source: LockSource) -> None:
if source == "beekeeper_monitoring_thread": if source == "beekeeper_wallet_lock_status_update_worker":
self.app.notify("Switched to the LOCKED mode due to timeout.", timeout=10) self.app.notify("Switched to the LOCKED mode due to timeout.", timeout=10)
self.app.pause_refresh_node_data_interval() self.app.pause_refresh_node_data_interval()
self.app.pause_refresh_alarms_data_interval() self.app.pause_refresh_alarms_data_interval()
......
...@@ -291,7 +291,7 @@ class Clive(App[int]): ...@@ -291,7 +291,7 @@ class Clive(App[int]):
@work(name="beekeeper wallet lock status update worker") @work(name="beekeeper wallet lock status update worker")
async def update_wallet_lock_status_from_beekeeper(self) -> None: async def update_wallet_lock_status_from_beekeeper(self) -> None:
if self.world._beekeeper_manager: if self.world._beekeeper_manager:
await self.world.commands.sync_state_with_beekeeper("beekeeper_monitoring_thread") await self.world.commands.sync_state_with_beekeeper("beekeeper_wallet_lock_status_update_worker")
async def __debug_log(self) -> None: async def __debug_log(self) -> None:
logger.debug("===================== DEBUG =====================") logger.debug("===================== DEBUG =====================")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment