Skip to content

feat: Adds forceApprove logic (SC-978) #110

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
May 14, 2025
Merged

Conversation

supercontracts
Copy link
Collaborator

Closes: #106

@supercontracts
Copy link
Collaborator Author

failing due to build size > limit once pr #104 merges it will work
Screenshot 2025-05-01 at 6 50 10 PM

@supercontracts supercontracts changed the title feat: Adds forceApprove logic feat: Adds forceApprove logic (SC-978) May 2, 2025
Copy link
Contributor

@lucas-manuel lucas-manuel left a comment

Choose a reason for hiding this comment

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

Add for curve, add notes to mention why its not included in CCTP and PSM libs

hacker-DOM
hacker-DOM previously approved these changes May 9, 2025
Copy link
Collaborator

@hacker-DOM hacker-DOM left a comment

Choose a reason for hiding this comment

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

Changes _approve function in Foreign|Mainnet Controller and CurvesLib to first approve to 0 if the regular approval fails[0]. Adds tests that presumably wouldn't pass before.

[0] Failure is defined as returning non-zero returndata AND the first word (0-extended if necessary) is 0.

Copy link

Coverage after merging sc-978-forceApprove into dev will be

100.00%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
deploy
   ControllerDeploy.sol100%100%100%100%
   ForeignControllerInit.sol100%100%100%100%
   MainnetControllerInit.sol97.22%93.33%100%100%136, 78
src
   ALMProxy.sol100%100%100%100%
   ForeignController.sol100%100%100%100%
   MainnetController.sol100%100%100%100%
   RateLimitHelpers.sol100%100%100%100%
   RateLimits.sol100%100%100%100%
src/libraries
   CCTPLib.sol100%100%100%100%
   CurveLib.sol100%100%100%100%
   PSMLib.sol100%100%100%100%

@supercontracts supercontracts merged commit 013eb22 into dev May 14, 2025
3 checks passed
@supercontracts supercontracts deleted the sc-978-forceApprove branch May 14, 2025 13:29
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.

Use forceApprove logic
3 participants