bor icon indicating copy to clipboard operation
bor copied to clipboard

Add-in BalanceChangePolygonBurn hook

Open Rampex1 opened this issue 6 months ago • 2 comments

Description

Added new hook to replicate BalanceChange_REASON_BURN behaviour in polygon-1.x

Changes

  • [X] Bugfix (non-breaking change that solves an issue)
  • [ ] Hotfix (change that solves an urgent issue, and requires immediate attention)
  • [ ] New feature (non-breaking change that adds functionality)
  • [ ] Breaking change (change that is not backwards-compatible and/or changes current functionality)
  • [ ] Changes only for a subset of nodes

Breaking changes

Please complete this section if any breaking changes have been made, otherwise delete it

Nodes audience

In case this PR includes changes that must be applied only to a subset of nodes, please specify how you handled it (e.g. by adding a flag with a default value...)

Checklist

  • [ ] I have added at least 2 reviewer or the whole pos-v1 team
  • [ ] I have added sufficient documentation in code
  • [ ] I will be resolving comments - if any - by pushing each fix in a separate commit and linking the commit hash in the comment reply
  • [ ] Created a task in Jira and informed the team for implementation in Erigon client (if applicable)
  • [ ] Includes RPC methods changes, and the Notion documentation has been updated

Cross repository changes

  • [ ] This PR requires changes to heimdall
    • In case link the PR here:
  • [ ] This PR requires changes to matic-cli
    • In case link the PR here:

Testing

  • [ ] I have added unit tests
  • [ ] I have added tests to CI
  • [ ] I have tested this code manually on local environment
  • [ ] I have tested this code manually on remote devnet using express-cli
  • [ ] I have tested this code manually on amoy
  • [ ] I have created new e2e tests into express-cli

Manual tests

Please complete this section with the steps you performed if you ran manual tests for this functionality, otherwise delete it

Additional comments

Please post additional comments in this section if you have them, otherwise delete it

Rampex1 avatar Jun 26 '25 05:06 Rampex1

Hi @Rampex1 can you please expand on the context w.r.t this PR ?

Raneet10 avatar Jun 27 '25 04:06 Raneet10

Hi, I'll update you once I double-check with @maoueh. Thank!

Rampex1 avatar Jun 27 '25 18:06 Rampex1

@Raneet10 That is required to be able to properly identify Polygon specific transfers related to burning. We think when Geth 1.15.x was merged, the BalanceChangeTransfer has been picked up kind of by default.

From our understanding of Polygon model, it would have been better to introduce a Polygon specific balance change reason. It enables easily mapping from BalanceChangePolygonBurn to BalanceChangeTransfer for those who would prefer that while offering a distinguished reason for those that would like to track this in a specific manner.

This is not possible (easily) possible with BalanceChangeTransfer as you cannot distinguish it from normal transfers happening within polygon.

maoueh avatar Jul 08 '25 18:07 maoueh

This PR is stale because it has been open 21 days with no activity. Remove stale label or comment or this will be closed in 14 days.

github-actions[bot] avatar Jul 30 '25 00:07 github-actions[bot]

This PR was closed because it has been stalled for 35 days with no activity.

github-actions[bot] avatar Aug 15 '25 00:08 github-actions[bot]