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

Workaround ethers import in deployment script for a bug in hardhat-ethers-plugin #100

Merged
merged 2 commits into from
May 2, 2022

Conversation

nkuba
Copy link
Member

@nkuba nkuba commented May 2, 2022

This PR is a workaround for an issue with hardhat-gas-reporter plugin (cgewecke/hardhat-gas-reporter#86).

When hre.ethers is used in the deployment script it causes a gas report to be missing executed function's data (example).

For tests executed in this repository, reports are fine, but when we use @threshold-network/solidity-contracts as a dependency in other projects (e.g. @keep-network/ecdsa) it breaks the reports there.

nkuba added 2 commits May 2, 2022 16:19
In deployment script we workaround a bug in hardhat-gas-reporter
cgewecke/hardhat-gas-reporter#86.

For some reason using `hre.ethers` makes gas report broken, the gas
usage for functions is not included in the report. This is a problem
that shows up in other projects using the deployment scripts of this
project, e.g. @keep-network/ecdsa.
@nkuba nkuba requested a review from pdyraga May 2, 2022 15:05
@pdyraga pdyraga merged commit 707b0f1 into main May 2, 2022
@pdyraga pdyraga deleted the gas-reporter-fix branch May 2, 2022 15:07
nkuba added a commit to keep-network/keep-core that referenced this pull request May 3, 2022
This version contains improvements from threshold-network/solidity-contracts#100
which help workaround problems with gas reporter.
@pdyraga pdyraga added this to the v1.2.0 milestone Sep 29, 2022
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

Successfully merging this pull request may close these issues.

2 participants