Skip to content

refactor: add source field to AcceptedDeposit event#179

Open
lpahlavi wants to merge 3 commits intomainfrom
lpahlavi/unify-accepted-deposit-event
Open

refactor: add source field to AcceptedDeposit event#179
lpahlavi wants to merge 3 commits intomainfrom
lpahlavi/unify-accepted-deposit-event

Conversation

@lpahlavi
Copy link
Copy Markdown
Contributor

@lpahlavi lpahlavi commented Apr 24, 2026

Summary

  • Renames AcceptedManualDeposit (#[n(2)]) to AcceptedDeposit and adds a mandatory source: DepositSource field (where DepositSource is Manual | Automatic)
  • The automatic deposit flow (future PR) will emit AcceptedDeposit { source: Automatic }
  • The manual deposit flow now emits AcceptedDeposit { source: Manual }

Deployment sequence

This PR is a breaking change. The one-time migration PR (#180) must be deployed first:

  1. Deploy migration PR (chore: one-time migration to convert AcceptedManualDeposit events to AcceptedDeposit #180) → post_upgrade reads old AcceptedManualDeposit events and re-encodes them as AcceptedDeposit { source: Manual }
  2. Confirm migration succeeded
  3. Deploy this PR

🤖 Generated with Claude Code

…to AcceptedDeposit

Introduces a DepositSource enum (Manual | Automatic) and a single
AcceptedDeposit event at #[n(13)] that records the source of each deposit.

The old AcceptedManualDeposit CBOR index (#[n(2)]) is retired; a separate
one-time migration PR will migrate any stored events to the new format before
this code is deployed.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@lpahlavi lpahlavi changed the title refactor: unify AcceptedManualDeposit and AcceptedAutomaticDeposit into AcceptedDeposit refactor: add source field to AcceptedDeposit event Apr 24, 2026
@lpahlavi lpahlavi force-pushed the lpahlavi/unify-accepted-deposit-event branch from d8ad4e5 to cbb9b76 Compare April 24, 2026 14:09
@lpahlavi lpahlavi changed the title refactor: add source field to AcceptedDeposit event refactor: add source field to AcceptedDeposit event Apr 24, 2026
@lpahlavi lpahlavi requested review from THLO and maciejdfinity April 24, 2026 14:16
@lpahlavi lpahlavi marked this pull request as ready for review April 24, 2026 14:16
@lpahlavi lpahlavi requested a review from a team as a code owner April 24, 2026 14:16
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Copilot AI review requested due to automatic review settings April 27, 2026 13:12
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants