Skip to content

Conversation

@joaquim-verges
Copy link
Member

@joaquim-verges joaquim-verges commented Oct 22, 2024

Problem solved

Short description of the bug fixed or feature added


PR-Codex overview

This PR refactors the getChains function in AAChainList.tsx to fetch chain data from a new API endpoint, replacing the previous implementation that relied on a local base URL. It improves error handling and modifies the logic for filtering and returning relevant chains.

Detailed summary

  • Removed the import of getBaseUrl and related code.
  • Introduced a new type ApiResponseType for the API response structure.
  • Updated getChains to fetch data from https://api.thirdweb.com/v1/chains/services and https://api.thirdweb.com/v1/chains.
  • Implemented logic to filter chains based on account abstraction services.
  • Enhanced error handling by logging a specific error message and rethrowing the error.

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

@vercel
Copy link

vercel bot commented Oct 22, 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 22, 2024 9:15am
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
thirdweb_playground ⬜️ Skipped (Inspect) Oct 22, 2024 9:15am
thirdweb-www ⬜️ Skipped (Inspect) Oct 22, 2024 9:15am
wallet-ui ⬜️ Skipped (Inspect) Oct 22, 2024 9:15am

@vercel vercel bot temporarily deployed to Preview – thirdweb-www October 22, 2024 00:45 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui October 22, 2024 00:45 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground October 22, 2024 00:45 Inactive
@changeset-bot
Copy link

changeset-bot bot commented Oct 22, 2024

⚠️ No Changeset found

Latest commit: 7cceaa1

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@graphite-app
Copy link
Contributor

graphite-app bot commented Oct 22, 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
Member Author

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

Join @joaquim-verges and the rest of your teammates on Graphite Graphite

@github-actions github-actions bot added the Portal Involves changes to the Portal (docs) codebase. label Oct 22, 2024
@joaquim-verges joaquim-verges marked this pull request as ready for review October 22, 2024 00:46
@codecov
Copy link

codecov bot commented Oct 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 45.33%. Comparing base (0e26a88) to head (7cceaa1).
Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5119      +/-   ##
==========================================
+ Coverage   45.29%   45.33%   +0.03%     
==========================================
  Files        1059     1060       +1     
  Lines       54754    54773      +19     
  Branches     3959     3954       -5     
==========================================
+ Hits        24803    24832      +29     
+ Misses      29260    29250      -10     
  Partials      691      691              
Flag Coverage Δ *Carryforward flag
legacy_packages 65.68% <ø> (ø) Carriedforward from 0e26a88
packages 40.29% <ø> (+0.04%) ⬆️

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

see 4 files with indirect coverage changes

@github-actions
Copy link
Contributor

github-actions bot commented Oct 22, 2024

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
thirdweb (esm) 42.81 KB (0%) 857 ms (0%) 2.7 s (+5.37% 🔺) 3.6 s
thirdweb (cjs) 102.66 KB (0%) 2.1 s (0%) 6.4 s (+3.71% 🔺) 8.4 s
thirdweb (minimal + tree-shaking) 4.84 KB (0%) 97 ms (0%) 179 ms (-34.67% 🔽) 276 ms
thirdweb/chains (tree-shaking) 498 B (0%) 10 ms (0%) 189 ms (+173.79% 🔺) 199 ms
thirdweb/react (minimal + tree-shaking) 17.36 KB (0%) 348 ms (0%) 775 ms (+72.71% 🔺) 1.2 s

@joaquim-verges joaquim-verges force-pushed the refactor_simplify_API_fetch_error_handling_in_aa-chains_route branch from c5035a7 to 8babad2 Compare October 22, 2024 01:43
@vercel vercel bot temporarily deployed to Preview – thirdweb-www October 22, 2024 01:43 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui October 22, 2024 01:43 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground October 22, 2024 01:43 Inactive
@joaquim-verges joaquim-verges force-pushed the refactor_simplify_API_fetch_error_handling_in_aa-chains_route branch from 8babad2 to ffc839a Compare October 22, 2024 02:01
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground October 22, 2024 02:01 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui October 22, 2024 02:01 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb-www October 22, 2024 02:01 Inactive
@joaquim-verges joaquim-verges force-pushed the refactor_simplify_API_fetch_error_handling_in_aa-chains_route branch from ffc839a to 114d6a3 Compare October 22, 2024 08:51
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground October 22, 2024 08:51 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui October 22, 2024 08:51 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb-www October 22, 2024 08:51 Inactive
@joaquim-verges joaquim-verges force-pushed the refactor_simplify_API_fetch_error_handling_in_aa-chains_route branch from 114d6a3 to 7cceaa1 Compare October 22, 2024 09:05
@vercel vercel bot temporarily deployed to Preview – thirdweb_playground October 22, 2024 09:05 Inactive
@vercel vercel bot temporarily deployed to Preview – wallet-ui October 22, 2024 09:05 Inactive
@vercel vercel bot temporarily deployed to Preview – thirdweb-www October 22, 2024 09:05 Inactive
@joaquim-verges joaquim-verges merged commit 788eefd into main Oct 22, 2024
31 checks passed
@joaquim-verges joaquim-verges deleted the refactor_simplify_API_fetch_error_handling_in_aa-chains_route branch October 22, 2024 09:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Portal Involves changes to the Portal (docs) codebase.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants