Skip to content

Conversation

@kien-ngo
Copy link
Contributor

@kien-ngo kien-ngo commented Oct 15, 2024

Problem solved

Short description of the bug fixed or feature added


PR-Codex overview

This PR introduces the mintToBatch function as an ERC1155 extension, allowing multiple tokens to be minted in a single transaction. It includes tests to ensure functionality and updates exports accordingly.

Detailed summary

  • Added mintToBatch function in mintToBatch.ts.
  • Introduced MintToBatchParams type defining minting parameters.
  • Created tests for mintToBatch in mintToBatch.test.ts.
  • Updated exports in erc1155.ts to include mintToBatch.

✨ Ask PR-Codex anything about this PR by commenting with /codex {your question}

@vercel
Copy link

vercel bot commented Oct 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs-v2 ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 15, 2024 8:27am
thirdweb_playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 15, 2024 8:27am
thirdweb-www ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 15, 2024 8:27am
wallet-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Oct 15, 2024 8:27am

@changeset-bot
Copy link

changeset-bot bot commented Oct 15, 2024

🦋 Changeset detected

Latest commit: 3fe33a6

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
thirdweb Minor

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

@graphite-app
Copy link
Contributor

graphite-app bot commented Oct 15, 2024

Your org has enabled the Graphite merge queue for merging into main

Add the label “merge-queue” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix.

You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link.

Copy link
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @kien-ngo and the rest of your teammates on Graphite Graphite

@github-actions
Copy link
Contributor

github-actions bot commented Oct 15, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 42.77 KB (0%) 856 ms (0%) 421 ms (+96.28% 🔺) 1.3 s
thirdweb (cjs) 102.62 KB (0%) 2.1 s (0%) 526 ms (+23.12% 🔺) 2.6 s
thirdweb (minimal + tree-shaking) 4.84 KB (0%) 97 ms (0%) 65 ms (+295.82% 🔺) 162 ms
thirdweb/chains (tree-shaking) 498 B (0%) 10 ms (0%) 59 ms (+813.55% 🔺) 69 ms
thirdweb/react (minimal + tree-shaking) 17.35 KB (0%) 347 ms (0%) 122 ms (+346.19% 🔺) 469 ms

@codecov
Copy link

codecov bot commented Oct 15, 2024

Codecov Report

Attention: Patch coverage is 82.85714% with 6 lines in your changes missing coverage. Please review.

Project coverage is 45.30%. Comparing base (1994d9e) to head (3fe33a6).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...irdweb/src/extensions/erc1155/write/mintToBatch.ts 82.85% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5032      +/-   ##
==========================================
+ Coverage   45.28%   45.30%   +0.02%     
==========================================
  Files        1058     1059       +1     
  Lines       54672    54707      +35     
  Branches     3950     3954       +4     
==========================================
+ Hits        24758    24786      +28     
- Misses      29223    29230       +7     
  Partials      691      691              
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from 1994d9e
packages 40.24% <82.85%> (+0.03%) ⬆️

*This pull request uses carry forward flags. Click here to find out more.

Files with missing lines Coverage Δ
...irdweb/src/extensions/erc1155/write/mintToBatch.ts 82.85% <82.85%> (ø)

... and 1 file with indirect coverage changes

}>;
}>;

export function mintToBatch(
Copy link
Member

Choose a reason for hiding this comment

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

add TS doc

also make sure you add a comment about the size of the batch - should not be too big otherwise it will not fit / not be included in a block

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ty ser. was waiting for a review on the code before I add the docs, seems all good!

@graphite-app
Copy link
Contributor

graphite-app bot commented Oct 15, 2024

Merge activity

## Problem solved

Short description of the bug fixed or feature added

<!-- start pr-codex -->

---

## PR-Codex overview
This PR adds the `mintToBatch` function to the `ERC1155` extension, allowing multiple tokens to be minted in a single transaction. It includes new tests to ensure the functionality works as expected.

### Detailed summary
- Introduced `mintToBatch` function in `mintToBatch.ts`.
- Added `MintToBatchParams` type definition.
- Updated `erc1155.ts` to export `mintToBatch` and `MintToBatchParams`.
- Created tests for `mintToBatch` in `mintToBatch.test.ts` to validate minting multiple tokens.

> ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}`

<!-- end pr-codex -->
@kien-ngo kien-ngo force-pushed the kien/erc1155-mintToBatch branch from fb69765 to 3fe33a6 Compare October 15, 2024 08:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants