Skip to content

refactor(agglayer): rm P2ID output serial num from CLAIM note NoteStorage#2484

Closed
partylikeits1983 wants to merge 24 commits intoagglayerfrom
ajl-refactor-claim-note-storage
Closed

refactor(agglayer): rm P2ID output serial num from CLAIM note NoteStorage#2484
partylikeits1983 wants to merge 24 commits intoagglayerfrom
ajl-refactor-claim-note-storage

Conversation

@partylikeits1983
Copy link
Copy Markdown
Member

This PR refactors the NoteStorage of the CLAIM note by removing the requirement for output note P2ID serial number. The output P2ID serial number is now the hash of the PROOF_DATA, i.e. Hasher::hash_elements(proof_data_elements)

This is already conveniently computed in MASM inside the CLAIM note and stored to global memory as PROOF_DATA_KEY.

Partially resolves (removing tag will be in a separate PR): #2237 (comment)

@partylikeits1983 partylikeits1983 added agglayer PRs or issues related to AggLayer bridging integration pr-from-maintainers PRs that come from internal contributors or integration partners. They should be given priority no changelog This PR does not require an entry in the `CHANGELOG.md` file labels Feb 20, 2026
@partylikeits1983 partylikeits1983 self-assigned this Feb 20, 2026
@partylikeits1983 partylikeits1983 marked this pull request as ready for review February 20, 2026 16:29

/// Output note data for CLAIM note creation.
/// Contains note-specific data and can use Miden types.
/// TODO: Remove all but target_faucet_account_id
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we should remove this TODO just yet:

  • We should be able to get rid of output_note_tag as well - right?
  • Do we actually need target_faucet_account_id here? How is it used in the output note?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed we should only remove the TODO after the tag is gone (planned for a follow-up, as noted in the PR description)

Do we actually need target_faucet_account_id here? How is it used in the output note?

It's not used for the output note, but rather for the claim note itself. We currently use it to check that only the target faucet can consume this CLAIM note, but this will be changed to use attachments

Base automatically changed from ajl-claim-note-quotient-notestorage to agglayer February 23, 2026 15:57
@partylikeits1983 partylikeits1983 force-pushed the ajl-refactor-claim-note-storage branch 2 times, most recently from 04c2f25 to 5b8ef5f Compare February 24, 2026 14:58
@partylikeits1983 partylikeits1983 marked this pull request as draft February 25, 2026 07:50
@partylikeits1983
Copy link
Copy Markdown
Member Author

Closed by: #2509

@partylikeits1983 partylikeits1983 deleted the ajl-refactor-claim-note-storage branch February 25, 2026 12:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agglayer PRs or issues related to AggLayer bridging integration no changelog This PR does not require an entry in the `CHANGELOG.md` file pr-from-maintainers PRs that come from internal contributors or integration partners. They should be given priority

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants