Skip to content

Reproducing a bug (naming collision) when trying to use wagmi codegen with the Uniswap v4 codebase

License

Notifications You must be signed in to change notification settings

saucepoint/wagmi-uniswap-v4-bug

Repository files navigation

wagmi-uniswap-v4-bug

Reproducing a naming collision with wagmi codegen

When using solmate's MockERC20 in a Uniswap v4 repo, wagmi codegen fails

This is caused by naming collision with Uniswap v4-core's MockERC20

If you manually modify the v4-core codebase MockERC20 -> UniMockERC20, wagmi codegen succeeds

Reproduce:

yarn install
forge build --force
yarn wagmi generate

Error:

saucepoint@air wagmi-uniswap-v4-bug % yarn wagmi generate
yarn run v1.22.19
$ /Users/saucepoint/code/wagmi-uniswap-v4-bug/node_modules/.bin/wagmi generate
✔ Validating plugins
⠦ Resolving contracts
Contract name "MockERC20" must be unique.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

About

Reproducing a bug (naming collision) when trying to use wagmi codegen with the Uniswap v4 codebase

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published