Skip to main content

await_account_registered

Function await_account_registered 

Source
pub async fn await_account_registered(
    core: &ExecutionClientCore,
    account_id: AccountId,
    timeout_secs: f64,
) -> Result<()>
Expand description

Polls the cache until the account is registered or timeout is reached.

Each iteration borrows and drops the cache Ref to avoid holding the RefCell borrow across await points, which would block mutable access when the account state is registered by another task.

ยงErrors

Returns an error if the timeout is reached before the account is registered.