NomicFoundation / hardhat

Hardhat is a development environment to compile, deploy, test, and debug your Ethereum software.
https://hardhat.org
Other
7.32k stars 1.42k forks source link

Add flag to make the task fail if the are compilation warnings #2479

Open 0xvgd opened 2 years ago

0xvgd commented 2 years ago

When I compile hardhat project, it succeeds with some warnings. What I want is to make github action CI succeeds only when it compiles with no warnings. How can I achieve this? npx hardhat compile always return 0 regardless of warnings, and how I can check the warning status in github action? Please help.

kanej commented 2 years ago

There is no way of making hardhat compile fail on warnings.

We are going to treat this issue as a feature request, and it is a good one.

github-actions[bot] commented 2 years ago

This issue was marked as stale because it didn't have any activity in the last 30 days. If you think it's still relevant, please leave a comment indicating so. Otherwise, it will be closed in 7 days.

0xvgd commented 2 years ago

Dummy comment to prevent stale

github-actions[bot] commented 2 years ago

This issue was marked as stale because it didn't have any activity in the last 30 days. If you think it's still relevant, please leave a comment indicating so. Otherwise, it will be closed in 7 days.

fvictorio commented 1 year ago

I added an example of how to do this here.

I don't think this is something we are going to add to core, unless there's significant demand. To anyone reading this: if you are interested on this being part of Hardhat itself, please upvote the issue to signal so.