Function inspect_affidavit

Source
pub fn inspect_affidavit<T: Config>(afdt_id: AffidavitId<T>)
Expand description

Emit the stored affidavit for a given affidavit identifier as an event.

This is a read-only convenience extrinsic that does not mutate any state. It retrieves the affidavit associated with the provided AffidavitId from storage and emits it as an [Event::InspectAffidavit] event, making the affidavit weights observable without requiring direct storage queries.

The retrieved affidavit corresponds to the upcoming session’s election (current session index + 1).

§Notes

  • Gated by the dev feature. Must not be included in production runtimes.
  • Useful for verifying that a previously submitted affidavit was stored correctly before the election window opens.

§Errors

Returns Error::AffidavitAuthorNotFound if no author is mapped to the given key, or Error::AffidavitNotFound if no affidavit has been submitted for that author.

§Warning: Doc-Only

This function is an automatically generated, and is doc-only, uncallable stub. See the real version in [Pallet::inspect_affidavit].