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

Wrong number of calls #109

Open
eaxeax opened this issue Apr 28, 2022 · 3 comments
Open

Wrong number of calls #109

eaxeax opened this issue Apr 28, 2022 · 3 comments

Comments

@eaxeax
Copy link

eaxeax commented Apr 28, 2022

I have a function

 function test(uint256 amount) external onlyOwner {
        a += amount;
    }

and when i do in a test

await mcn.connect(owner).test(1000000);

i will have 1 number of calls, but also if i do

await mcn.connect(owner).test(1000000).then(tx => tx.wait());

i will have 2 number of calls.

Can someone explain why ? Thanks

@eaxeax
Copy link
Author

eaxeax commented Apr 28, 2022

As I understand it: you have to do something like Set() for transactions in the current block in EGRDataCollectionProvider::request. Then we won't have to process transactions twice. Its have a comment

// Ethers: will get run twice for deployments (e.g both receipt and txhash are fetched)

but why its not fixed?

@eaxeax
Copy link
Author

eaxeax commented Apr 28, 2022

#111

@m-waqas88
Copy link

I am also facing this issue.

hardhat version "2.12.6"
hardhat-gas-reporter version "1.0.9"

Is there any positive update on this, please?

@cgewecke cgewecke mentioned this issue Feb 27, 2024
54 tasks
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

2 participants