Stage 07.4.3.2 — price polling, event bus and UI throttling
This commit is contained in:
@@ -16,7 +16,7 @@ class MarketPriceSnapshot:
|
||||
bid_price: float | None
|
||||
ask_price: float | None
|
||||
updated_at: str
|
||||
source: str = "websocket"
|
||||
source: str = "market-cache"
|
||||
|
||||
|
||||
class MarketPriceCache:
|
||||
@@ -32,6 +32,7 @@ class MarketPriceCache:
|
||||
bid_price: float | None = None,
|
||||
ask_price: float | None = None,
|
||||
updated_at: str | None = None,
|
||||
source: str = "market-polling",
|
||||
) -> None:
|
||||
settings = load_settings()
|
||||
|
||||
@@ -44,6 +45,7 @@ class MarketPriceCache:
|
||||
bid_price=bid_price,
|
||||
ask_price=ask_price,
|
||||
updated_at=updated_at,
|
||||
source=source,
|
||||
)
|
||||
|
||||
# получить последнюю цену
|
||||
|
||||
Reference in New Issue
Block a user