Skip to content

fix: getAbiItem for tuple with additional tuples#4194

Merged
jxom merged 1 commit intowevm:mainfrom
0xRenji:fix/abi-tuple
Dec 28, 2025
Merged

fix: getAbiItem for tuple with additional tuples#4194
jxom merged 1 commit intowevm:mainfrom
0xRenji:fix/abi-tuple

Conversation

@0xRenji
Copy link
Copy Markdown
Contributor

@0xRenji 0xRenji commented Dec 25, 2025

Fixes an error when tuples have additional tuples (more than the args). Those would result in arg being undefined and Object.values throw:

Uncaught TypeError: Cannot convert undefined or null to object

Fixed by ensuring that argType === 'object'. Could be fixed in a lot of ways, but this most closely aligns with existing code IMO.

I edited an existing test case to cover this.

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Dec 25, 2025

🦋 Changeset detected

Latest commit: 5decbf9

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

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

@0xRenji 0xRenji force-pushed the fix/abi-tuple branch 2 times, most recently from 67e5351 to 7c7e669 Compare December 25, 2025 21:15
@jxom jxom merged commit 16b0819 into wevm:main Dec 28, 2025
2 checks passed
@github-actions github-actions bot mentioned this pull request Dec 28, 2025
@0xRenji 0xRenji deleted the fix/abi-tuple branch January 5, 2026 06:36
@tmm tmm mentioned this pull request Feb 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants