feat(wallet/desktop): Enable sequential scheduler.

Handle 'new transfers' event for activity view
to load transactions. It is a temporary solution until integration of
sequential transfer fetching is properly done with activity filter
This commit is contained in:
Ivan Belyakov 2023-06-05 10:36:42 +02:00 committed by IvanBelyakoff
parent 11bd51fc27
commit b6a23f55a1
3 changed files with 15 additions and 2 deletions

View File

@ -396,7 +396,8 @@ var NODE_CONFIG* = %* {
"420": ALCHEMY_OPTIMISM_GOERLI_TOKEN_RESOLVED
},
"InfuraAPIKey": INFURA_TOKEN_RESOLVED,
"InfuraAPIKeySecret": INFURA_TOKEN_SECRET_RESOLVED
"InfuraAPIKeySecret": INFURA_TOKEN_SECRET_RESOLVED,
"LoadAllTransfers": true,
},
"EnsConfig": {
"Enabled": true

View File

@ -661,7 +661,8 @@ QtObject:
"420": ALCHEMY_OPTIMISM_GOERLI_TOKEN_RESOLVED
},
"InfuraAPIKey": INFURA_TOKEN_RESOLVED,
"InfuraAPIKeySecret": INFURA_TOKEN_SECRET_RESOLVED
"InfuraAPIKeySecret": INFURA_TOKEN_SECRET_RESOLVED,
"LoadAllTransfers": true
},
"TorrentConfig": {
"Enabled": false,

View File

@ -46,6 +46,7 @@ const SIGNAL_HISTORY_FETCHING* = "historyFetching"
const SIGNAL_HISTORY_READY* = "historyReady"
const SIGNAL_HISTORY_NON_ARCHIVAL_NODE* = "historyNonArchivalNode"
const SIGNAL_HISTORY_ERROR* = "historyError"
const SIGNAL_NEW_TRANSFERS* = "newTransfers"
const SIGNAL_CRYPTO_SERVICES_READY* = "cryptoServicesReady"
const SIMPLE_TX_BRIDGE_NAME = "Simple"
@ -144,6 +145,16 @@ QtObject:
self.events.emit(SIGNAL_HISTORY_NON_ARCHIVAL_NODE, Args())
of "fetching-history-error":
self.events.emit(SIGNAL_HISTORY_ERROR, Args())
of "new-transfers":
# TODO delete this, once activity filter is integrated
# with scheduler (Reactor) in status-go.
# It should handle proper updates of activity list. Proper
# handling of new and old transfers with current implementation
# requires lots of refactoring.
for account in data.accounts:
self.loadTransactions(account, stint.fromHex(Uint256, "0x0"))
self.events.emit(SIGNAL_NEW_TRANSFERS, HistoryArgs(addresses: data.accounts))
proc getPendingTransactions*(self: Service): seq[TransactionDto] =
try: