Skip to content

Session


Calls


purge_keys

Attributes

No attributes

Python

call = substrate.compose_call(
    'Session', 'purge_keys', {}
)

set_keys

Attributes

Name Type
keys T::Keys
proof Vec<u8>

Python

call = substrate.compose_call(
    'Session', 'set_keys', {'keys': {'aura': '[u8; 32]'}, 'proof': 'Bytes'}
)

Events


NewSession

Attributes

Name Type Composition
session_index SessionIndex u32

Storage functions


CurrentIndex

Python

result = substrate.query(
    'Session', 'CurrentIndex', []
)

Return value

'u32'

DisabledValidators

Python

result = substrate.query(
    'Session', 'DisabledValidators', []
)

Return value

['u32']

KeyOwner

Python

result = substrate.query(
    'Session', 'KeyOwner', [('[u8; 4]', 'Bytes')]
)

Return value

'AccountId'

NextKeys

Python

result = substrate.query(
    'Session', 'NextKeys', ['AccountId']
)

Return value

{'aura': '[u8; 32]'}

QueuedChanged

Python

result = substrate.query(
    'Session', 'QueuedChanged', []
)

Return value

'bool'

QueuedKeys

Python

result = substrate.query(
    'Session', 'QueuedKeys', []
)

Return value

[('AccountId', {'aura': '[u8; 32]'})]

Validators

Python

result = substrate.query(
    'Session', 'Validators', []
)

Return value

['AccountId']

Errors


DuplicatedKey


InvalidProof


NoAccount


NoAssociatedValidatorId


NoKeys