Skip to content

feat(crosschain): refund aborted amount#1728

Merged
kingpinXD merged 65 commits intodevelopfrom
refund-aborted-amount
Feb 13, 2024
Merged

feat(crosschain): refund aborted amount#1728
kingpinXD merged 65 commits intodevelopfrom
refund-aborted-amount

Conversation

@kingpinXD
Copy link
Member

@kingpinXD kingpinXD commented Feb 7, 2024

Description

  • Adds refund tx to refund previously aborted transactions
  • Reset ZetaAccounting using a migration script
  • Set IsAbortRefunded flag for all CCTX's which would allow some of them to be refunded if needed
  • Disables auto refunds for cctx's

Closes: #1192

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Include instructions and any relevant details so others can reproduce.

  • Tested CCTX in localnet
  • Tested in development environment
  • Go unit tests
  • Go integration tests
  • Tested via GitHub Actions

Checklist:

  • I have added unit tests that prove my fix feature works

@lumtis lumtis changed the title feature: refund aborted amount feat(crosschain): refund aborted amount Feb 7, 2024
@lumtis lumtis linked an issue Feb 7, 2024 that may be closed by this pull request
@kingpinXD kingpinXD marked this pull request as draft February 7, 2024 05:56
@kingpinXD kingpinXD marked this pull request as ready for review February 8, 2024 16:27
@github-actions
Copy link

!!!WARNING!!!
nosec detected in the following files: x/emissions/client/tests/suite.go

Be very careful about using #nosec in code. It can be a quick way to suppress security warnings and move forward with development, it should be employed with caution. Suppressing warnings with #nosec can hide potentially serious vulnerabilities. Only use #nosec when you're absolutely certain that the security issue is either a false positive or has been mitigated in another way.

Only suppress a single rule (or a specific set of rules) within a section of code, while continuing to scan for other problems. To do this, you can list the rule(s) to be suppressed within the #nosec annotation, e.g: /* #nosec G401 */ or //#nosec G201 G202 G203
Broad #nosec annotations should be avoided, as they can hide other vulnerabilities. The CI will block you from merging this PR until you remove #nosec annotations that do not target specific rules.

Pay extra attention to the way #nosec is being used in the files listed above.

Copy link
Contributor

@lumtis lumtis left a comment

Choose a reason for hiding this comment

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

Need to change the refund smoke test refund and check aborted cctx instead of comparing amounts

@kingpinXD kingpinXD requested a review from lumtis February 13, 2024 07:37
@kingpinXD kingpinXD merged commit 62f9849 into develop Feb 13, 2024
@kingpinXD kingpinXD deleted the refund-aborted-amount branch February 13, 2024 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Refund user on ZetaChain when a CCTX is aborted

4 participants