From f352d91120644d8baa99e1b81a0e6d524cbdcc12 Mon Sep 17 00:00:00 2001 From: Michal Zielenkiewicz Date: Mon, 19 Jan 2026 10:13:21 +0100 Subject: [PATCH] Add nonce row to runtime account details --- .changelog/2427.trivial.md | 1 + src/app/components/Account/RuntimeAccountDetailsView.tsx | 3 +++ src/app/utils/test-fixtures.ts | 2 ++ src/oasis-nexus/generated/api.ts | 2 ++ 4 files changed, 8 insertions(+) create mode 100644 .changelog/2427.trivial.md diff --git a/.changelog/2427.trivial.md b/.changelog/2427.trivial.md new file mode 100644 index 0000000000..daa4aca419 --- /dev/null +++ b/.changelog/2427.trivial.md @@ -0,0 +1 @@ +Add nonce row to runtime account details diff --git a/src/app/components/Account/RuntimeAccountDetailsView.tsx b/src/app/components/Account/RuntimeAccountDetailsView.tsx index 6da183d225..ade362ec30 100644 --- a/src/app/components/Account/RuntimeAccountDetailsView.tsx +++ b/src/app/components/Account/RuntimeAccountDetailsView.tsx @@ -152,6 +152,9 @@ export const RuntimeAccountDetailsView: FC = ({ )} +
{t('common.nonce')}
+
{account.nonce ?? t('common.missing')}
+
{t('common.transactions')}
{account.stats.num_txns ? ( diff --git a/src/app/utils/test-fixtures.ts b/src/app/utils/test-fixtures.ts index 6a10f1d1e2..cd68abc34c 100644 --- a/src/app/utils/test-fixtures.ts +++ b/src/app/utils/test-fixtures.ts @@ -27,6 +27,7 @@ export const sapphireParsedBlock: BlockResult = { export const suggestedParsedAccount: RuntimeAccount = groupAccountTokenBalances({ address: 'oasis1qrvha284gfztn7wwq6z50c86ceu28jp7csqhpx9t', + nonce: 1, address_preimage: { address_data: 'ulBIGP3Y09ui74/ZtPTVxxrR0dM=', context: 'oasis-runtime-sdk/address: secp256k1eth', @@ -65,6 +66,7 @@ export const suggestedParsedAccount: RuntimeAccount = groupAccountTokenBalances( export const suggestedEmptyAccount: RuntimeAccount = groupAccountTokenBalances({ address: 'oasis1qz64azk6qr5nzq537l5cgpd4uxltrhpkhqdx5tqy', + nonce: 1, address_preimage: undefined, address_eth: undefined, balances: [], diff --git a/src/oasis-nexus/generated/api.ts b/src/oasis-nexus/generated/api.ts index 41a36d067f..836911de85 100644 --- a/src/oasis-nexus/generated/api.ts +++ b/src/oasis-nexus/generated/api.ts @@ -1522,6 +1522,8 @@ export interface RuntimeTransactionSigner { export interface RuntimeAccount { /** The staking address for this account. */ address: string; + /** The expected nonce for the next transaction (= last used nonce + 1) */ + nonce: number; address_preimage?: AddressPreimage; /** The balance(s) of this account in this runtime. Most runtimes use only one denomination, and thus produce only one balance here. These balances do not include "layer (n+1) tokens", i.e. tokens