Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] CCIP read is not working with a provider managed by this middleware #335

Open
mirceanis opened this issue Sep 18, 2024 · 0 comments
Open

Comments

@mirceanis
Copy link

ENS resolution sometimes uses CCIP read (eip-3668) to resolve an address.
That relies on a reverted execution being interpreted as a redirect.
When the provider used to perform such a read is managed by this middleware, the read operation fails.
My guess is that the reverted execution is somehow wrapped such that the error is no longer interpretable.

This bug showed up after the upgrade from v13 to v14 of this lib in the MetaMask extension.

The environment to reproduce it has ethers@6.x as a dependency, and a simple test to reproduce would go along the lines of:

const provider = new BrowserProvider(setup.provider); // provider managed by this middleware
const sampleDomain = 'jwt.ro'; // resolving a linked DNS domain uses CCIP read
const ensResolver = await provider.getResolver(sampleDomain);
const ethAddress = await ensResolver?.getAddress();
expect(ethAddress).toBe('0xd08E08a0551575eE6bcE6d56180148EB68Bca061');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants