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

[question] hardhat config #28

Closed
alxiong opened this issue Sep 21, 2021 · 6 comments
Closed

[question] hardhat config #28

alxiong opened this issue Sep 21, 2021 · 6 comments

Comments

@alxiong
Copy link

alxiong commented Sep 21, 2021

  1. why manually probing into hardhat/types::HardhatUserConfig and declaring the outputSelection rather awkwardly here, instead of using hardhat-storage-layout plugin
  2. where in the code did we try to update a storage slot in the example code or test?
@alxiong
Copy link
Author

alxiong commented Sep 21, 2021

Ah! I think I was mistaken, we were not intending to use hardhat-storage-layout plugin, but rather smock instead, correct?

Nevertheless, should have stick to:

const config = {
  solidity: {
    settings: {
      outputSelection: {
        "*": {
          "*": ["storageLayout"]
        }
      }
    }
  }
}

instead of

  (config.solidity as MultiSolcUserConfig).compilers = (config.solidity as MultiSolcUserConfig).compilers.map((compiler) => {
    return {
      ...compiler,
      outputSelection: {
        '*': {
          '*': ['storageLayout'],
        },
      },
    };
  });

@alxiong alxiong changed the title [question] storage-layout config [question] hardhat config Sep 21, 2021
@alxiong
Copy link
Author

alxiong commented Sep 21, 2021

More questions/comments:

possible updates to hardhat.config.ts to consider:

  1. addgasReporter.excludeContracts: ['contracts/mocks/']

puzzling devDependencies:

  1. when is moment ever used? plus the package is in maintenance mode

@404skillz
Copy link
Contributor

@alxiong thanks for all the input ! It got lost on my notifications. Will look into all of them and ping you back !

@turtlemoji
Copy link
Contributor

turtlemoji commented Jun 24, 2022

More questions/comments:

possible updates to hardhat.config.ts to consider:

  1. addgasReporter.excludeContracts: ['contracts/mocks/']

puzzling devDependencies:

  1. when is moment ever used? plus the package is in maintenance mode
  • Moment is removed in current main
  • Agree with the gas reporter
    Now it should be excludeContracts: ['solidity/mocks/'], @alxiong

@0xged
Copy link
Contributor

0xged commented Jul 5, 2022

hey guys! in terms of the contract exclusion of mocks, the bad thing is that if you test against mocks contracts you will not have any of your tests in the coverage.

@turtlemoji
Copy link
Contributor

@0xged True, closing for now then.

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

4 participants