-
Notifications
You must be signed in to change notification settings - Fork 619
[SDK] Allow passing overrides to common extension functions #8041
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
[SDK] Allow passing overrides to common extension functions #8041
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
🦋 Changeset detectedLatest commit: 7e1c67c The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Caution Review failedThe pull request is closed. WalkthroughIntroduces transaction overrides support across multiple ERC1155, ERC20, and ERC721 write/drop helpers by wrapping params with WithOverrides and forwarding options.overrides to underlying calls. Adds a changeset documenting the patch. Updates a playground web component to use HTTPS for an API URL. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant C as Client
participant E as Extension Helper (e.g., claimTo/lazyMint)
participant G as Generated Writer/Multicall
participant B as Blockchain
Note over C,E: Options now may include "overrides"
C->>E: call(options: { params..., overrides? })
E->>G: invoke({ contract, args..., overrides: options.overrides })
alt success
G->>B: send tx (with overrides)
B-->>G: receipt
G-->>E: prepared/executed tx
E-->>C: result/tx
else error
G-->>E: error
E-->>C: error
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes 📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro Disabled knowledge base sources:
📒 Files selected for processing (22)
✨ Finishing touches
🧪 Generate unit tests
Comment |
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
size-limit report 📦
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #8041 +/- ##
==========================================
+ Coverage 56.63% 56.64% +0.01%
==========================================
Files 904 904
Lines 58707 58738 +31
Branches 4166 4165 -1
==========================================
+ Hits 33246 33274 +28
- Misses 25355 25358 +3
Partials 106 106
🚀 New features to boost your workflow:
|
| amountWei: amount, | ||
| tokenAddress: options.contract.address, | ||
| }, | ||
| ...options.overrides, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Object spread syntax error will cause runtime failure. The line ...options.overrides, is spreading options.overrides directly into the asyncParams object, but overrides should be spread at the transaction level, not inside the async parameters. This will either cause a TypeError if overrides is undefined, or incorrectly merge override properties into the async params object instead of the transaction options. The fix is to move this spread outside the asyncParams object to the same level as contract and spender.
Spotted by Diamond
Is this helpful? React 👍 or 👎 to let us know.

PR-Codex overview
This PR focuses on enhancing the
thirdweblibrary by allowing the passing of overrides to common extension functions, which improves flexibility in transaction options across various ERC standards.Detailed summary
urlfrom HTTP to HTTPS ingateway.tsx.LazyMintParams,MintAdditionalSupplyToParams,DepositParams, and other parameters to useWithOverrides.overridesto function calls in various files, includinglazyMint,setSharedMetadata, andresetClaimEligibility.Summary by CodeRabbit
New Features
Bug Fixes
Chores