Skip to content

Conversation

@joaquim-verges
Copy link
Member

@joaquim-verges joaquim-verges commented Apr 16, 2025


PR-Codex overview

This PR focuses on simplifying the handling of RPC requests in the thirdweb package, improving error reporting, and refining response parsing.

Detailed summary

  • Enhanced error message in rpc.ts when no response is received, including index and all responses.
  • Removed redundant checks for JSON content type in fetch-rpc.ts, directly returning JSON response.
  • Streamlined error handling during response parsing in fetch-rpc.ts.

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

@vercel
Copy link

vercel bot commented Apr 16, 2025

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 Apr 17, 2025 0:09am
login ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 17, 2025 0:09am
thirdweb_playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 17, 2025 0:09am
thirdweb-www ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 17, 2025 0:09am
wallet-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 17, 2025 0:09am

@github-actions github-actions bot added packages SDK Involves changes to the thirdweb SDK labels Apr 16, 2025
@joaquim-verges joaquim-verges changed the title [thirdweb] Simplify RPC request handling [SDK] Simplify RPC request handling Apr 16, 2025
Copy link
Member Author


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge-queue - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

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.

@github-actions
Copy link
Contributor

github-actions bot commented Apr 16, 2025

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 50.57 KB (+0.14% 🔺) 1.1 s (+0.14% 🔺) 246 ms (+262.76% 🔺) 1.3 s
thirdweb (cjs) 138.73 KB (-0.05% 🔽) 2.8 s (-0.05% 🔽) 368 ms (+116.92% 🔺) 3.2 s
thirdweb (minimal + tree-shaking) 5.59 KB (-0.75% 🔽) 112 ms (-0.75% 🔽) 106 ms (+1946.91% 🔺) 218 ms
thirdweb/chains (tree-shaking) 514 B (0%) 11 ms (0%) 59 ms (+3784.89% 🔺) 69 ms
thirdweb/react (minimal + tree-shaking) 19.36 KB (-0.24% 🔽) 388 ms (-0.24% 🔽) 158 ms (+1404.15% 🔺) 545 ms

@changeset-bot
Copy link

changeset-bot bot commented Apr 16, 2025

🦋 Changeset detected

Latest commit: bd963e7

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

This PR includes changesets to release 2 packages
Name Type
thirdweb Patch
@thirdweb-dev/wagmi-adapter Patch

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

@codecov
Copy link

codecov bot commented Apr 17, 2025

Codecov Report

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

Project coverage is 55.10%. Comparing base (8d4d991) to head (bd963e7).
Report is 5 commits behind head on main.

Files with missing lines Patch % Lines
packages/thirdweb/src/rpc/rpc.ts 0.00% 5 Missing ⚠️
packages/thirdweb/src/rpc/fetch-rpc.ts 50.00% 1 Missing ⚠️

❌ Your patch status has failed because the patch coverage (14.28%) is below the target coverage (80.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6752      +/-   ##
==========================================
+ Coverage   55.09%   55.10%   +0.01%     
==========================================
  Files         896      896              
  Lines       56714    56700      -14     
  Branches     3911     3914       +3     
==========================================
+ Hits        31246    31247       +1     
+ Misses      25372    25357      -15     
  Partials       96       96              
Flag Coverage Δ
packages 55.10% <14.28%> (+0.01%) ⬆️
Files with missing lines Coverage Δ
packages/thirdweb/src/rpc/fetch-rpc.ts 44.00% <50.00%> (+16.05%) ⬆️
packages/thirdweb/src/rpc/rpc.ts 69.78% <0.00%> (-2.07%) ⬇️

... and 3 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@joaquim-verges joaquim-verges merged commit 23d3757 into main Apr 17, 2025
23 of 24 checks passed
@joaquim-verges joaquim-verges deleted the _thirdweb_Simplify_RPC_request_handling branch April 17, 2025 01:07
@joaquim-verges joaquim-verges mentioned this pull request Apr 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

packages SDK Involves changes to the thirdweb SDK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants