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

ABI not parsing properly for constructor with parameters #4278

Closed
yivlad opened this issue Jul 28, 2023 · 1 comment
Closed

ABI not parsing properly for constructor with parameters #4278

yivlad opened this issue Jul 28, 2023 · 1 comment
Assignees
Labels
fixed/complete This Bug is fixed or Enhancement is complete and published. investigate Under investigation and may be a bug. v6 Issues regarding v6

Comments

@yivlad
Copy link

yivlad commented Jul 28, 2023

Ethers Version

6.6.6

Search Terms

abi

Describe the Problem

Consider the following code:

import { Interface } from 'ethers';

const abi = [
  'constructor(uint256 n) public',
];

const iface = new Interface(abi);
console.log('Number of constructor parameters:', iface.deploy.inputs.length)

Expected output:
Number of constructor parameters: 1
Actual output:
Number of constructor parameters: 0

Environment

node.js (v12 or newer)

@yivlad yivlad added investigate Under investigation and may be a bug. v6 Issues regarding v6 labels Jul 28, 2023
@ricmoo ricmoo added on-deck This Enhancement or Bug is currently being worked on. next-patch Issues scheduled for the next arch release. labels Jul 28, 2023
@ricmoo
Copy link
Member

ricmoo commented Jul 29, 2023

Fixed in 3a52201 and released in v6.6.7.

I'll update the CHANGELOG in the next push to link to this issue.

Thanks! :)

@ricmoo ricmoo closed this as completed Jul 29, 2023
@ricmoo ricmoo added fixed/complete This Bug is fixed or Enhancement is complete and published. and removed on-deck This Enhancement or Bug is currently being worked on. next-patch Issues scheduled for the next arch release. labels Jul 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fixed/complete This Bug is fixed or Enhancement is complete and published. investigate Under investigation and may be a bug. v6 Issues regarding v6
Projects
None yet
Development

No branches or pull requests

2 participants