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

[ISSUE] Contract types of interface definitions not supported in pypechain #128

Open
slundqui opened this issue Sep 6, 2024 · 0 comments

Comments

@slundqui
Copy link
Contributor

slundqui commented Sep 6, 2024

E.g., MorphoBlueConversions arguments include types IMorpho and IERC20, both of which are contract interfaces. Pypechain does not support this, which results in the following codegen:

def __call__(self, vault: IMorpho, baseToken: IERC20, ...) -> MorphoBlueConversionsConvertToBaseContractFunction:  # type: ignore
        clone = super().__call__(
        ...

Here, IMorpho and IERC20 are not valid types, which is ignored with the following type:ignore. Additionally, there are some oddities with calling this function via vanilla web3, which results in function abi does not match if attempting to pass in an address for these two arguments.

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

No branches or pull requests

1 participant