Skip to content

Conversation

@joaquim-verges
Copy link
Member

@joaquim-verges joaquim-verges commented Feb 17, 2025


PR-Codex overview

This PR focuses on improving the auto-connection handling for wallets in the thirdweb library. It updates the storage keys used for chain IDs and enhances the connectivity functions.

Detailed summary

  • Changed autoConnect from a constant to an async function.
  • Updated storage key from "tw.lastChainId" to "thirdweb:lastChainId".
  • Introduced activeWalletIdKey and connectedWalletIdsKey for better wallet management.
  • Enhanced error messaging for unsupported chains.
  • Set local storage values directly for active and connected wallet IDs.

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

@vercel
Copy link

vercel bot commented Feb 17, 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 Feb 17, 2025 9:35am
login ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 17, 2025 9:35am
thirdweb_playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 17, 2025 9:35am
thirdweb-www ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 17, 2025 9:35am
wallet-ui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 17, 2025 9:35am

@changeset-bot
Copy link

changeset-bot bot commented Feb 17, 2025

🦋 Changeset detected

Latest commit: 90d32c8

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

This PR includes changesets to release 1 package
Name Type
@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

@joaquim-verges joaquim-verges marked this pull request as ready for review February 17, 2025 09:27
@joaquim-verges joaquim-verges requested review from a team as code owners February 17, 2025 09:27
@github-actions github-actions bot added packages SDK Involves changes to the thirdweb SDK labels Feb 17, 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

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 46.3 KB (0%) 926 ms (0%) 375 ms (+46.93% 🔺) 1.3 s
thirdweb (cjs) 121.89 KB (0%) 2.5 s (0%) 595 ms (+13.47% 🔺) 3.1 s
thirdweb (minimal + tree-shaking) 5.6 KB (0%) 112 ms (0%) 45 ms (-10.69% 🔽) 157 ms
thirdweb/chains (tree-shaking) 506 B (0%) 10 ms (0%) 19 ms (+14.62% 🔺) 29 ms
thirdweb/react (minimal + tree-shaking) 19.29 KB (0%) 386 ms (0%) 96 ms (-13.65% 🔽) 481 ms

@codecov
Copy link

codecov bot commented Feb 17, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 56.84%. Comparing base (4158a79) to head (90d32c8).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6273   +/-   ##
=======================================
  Coverage   56.84%   56.84%           
=======================================
  Files        1168     1168           
  Lines       64662    64662           
  Branches     5241     5240    -1     
=======================================
  Hits        36759    36759           
  Misses      27175    27175           
  Partials      728      728           
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from 4158a79
packages 55.06% <100.00%> (ø)

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

Files with missing lines Coverage Δ
...ges/thirdweb/src/wallets/connection/autoConnect.ts 75.86% <100.00%> (ø)

@joaquim-verges joaquim-verges merged commit 739a2ae into main Feb 17, 2025
34 of 38 checks passed
@joaquim-verges joaquim-verges deleted the _wagmi-adapter_fix_Improve_autoconnect_handling_and_storage branch February 17, 2025 09:35
@joaquim-verges joaquim-verges mentioned this pull request Feb 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