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

Place verifier contract to contracts folder instead of contract #1009

Closed
signorecello opened this issue Mar 20, 2023 · 4 comments · Fixed by AztecProtocol/aztec-packages#6320
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@signorecello
Copy link
Contributor

Problem

Hardhat tipically searches the folder contracts for contracts, but nargo codegen-verifier places the default verifier into a contract folder

Proposed solution

The easiest solution would be to add this verifier contract to the contracts folder

Alternatives considered

Using the source configuration param in hardhat, you can have it search for other folder. However, seems like we would want this to be consistent with the more common contracts naming

Additional context

No response

@signorecello signorecello added the enhancement New feature or request label Mar 20, 2023
@github-project-automation github-project-automation bot moved this to 📋 Backlog in Noir Mar 20, 2023
@kevaundray
Copy link
Contributor

@TomAFrench Is it okay to call this folder contracts given that we changed the contract command?

@TomAFrench
Copy link
Member

TomAFrench commented Mar 25, 2023

I have a couple of reservations about this:

  • It assumes that the noir project will live in the same directory as the hardhat/foundry root. This is unlikely imo.
  • The contracts package isn't a universal standard as foundry projects tend to use src.
  • If we have verifiers which don't target smart contract languages then this doesn't make sense.

I'd prefer to add an out arg to the codegen-verifier which defines which directory to write the generated verifier. We can then have a very generic default directory (e.g. verifier) and then add a field in Nargo.toml for users to specify where they want it sent by default:

[codegen-verifier]
out = "../hardhat_project/contracts/verifier`

@TomAFrench
Copy link
Member

Marking this as a good first issue as it should be fairly achievable for without a ton of context on the internals of the Nargo/Noir. That said it's a feature of a pretty decent size.

@kevaundray
Copy link
Contributor

@TomAFrench whats the status of this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
Status: Done
4 participants