Skip to content
This repository has been archived by the owner on Oct 19, 2024. It is now read-only.

method not found error for nested struct argument #416

Closed
wolflo opened this issue Aug 29, 2021 · 0 comments · Fixed by #417
Closed

method not found error for nested struct argument #416

wolflo opened this issue Aug 29, 2021 · 0 comments · Fixed by #417
Labels
bug Something isn't working

Comments

@wolflo
Copy link
Contributor

wolflo commented Aug 29, 2021

Version

ethers v0.5.1
│ ├── ethers-contract v0.5.1
│ │ ├── ethers-contract-abigen v0.5.1
│ │ │ ├── ethers-core v0.5.1
│ │ ├── ethers-contract-derive v0.5.1 (proc-macro)
│ │ │ ├── ethers-contract-abigen v0.5.1
│ │ │ ├── ethers-core v0.5.1
│ │ ├── ethers-core v0.5.1
│ │ ├── ethers-providers v0.5.1
│ │ │ ├── ethers-core v0.5.1
│ ├── ethers-core v0.5.1
│ ├── ethers-middleware v0.5.1
│ │ ├── ethers-contract v0.5.1
│ │ ├── ethers-core v0.5.1
│ │ ├── ethers-providers v0.5.1
│ │ ├── ethers-signers v0.5.1
│ │ │ ├── ethers-core v0.5.1
│ ├── ethers-providers v0.5.1
│ └── ethers-signers v0.5.1

Description

Relates to #363.

When calling a solidity method using abigen! generated bindings, a method not found (this should never happen): DecodingError(InvalidData) error is thrown.

The method being called accepts a single struct, which itself contains an array of another struct.

struct Inner {
    bytes32 id;
    bytes data;
}
struct Outer {
     Inner[] innerStructs;
}

function useStruct(Outer calldata foo) external;
@wolflo wolflo added the bug Something isn't working label Aug 29, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant