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

Verification does not work in ignition when deploying external artifacts #5659

Open
sim31 opened this issue Aug 21, 2024 · 1 comment
Open
Assignees
Labels
status:ready This issue is ready to be worked on type:bug Something isn't working

Comments

@sim31
Copy link

sim31 commented Aug 21, 2024

Version of Hardhat

2.22.8

What happened?

I'm using ignition to deploy contracts from external repository by specifying artifacts to deploy as described in the docs.

Getting this error when running `npx hardhat ignition verify...:

Error: ENOENT: no such file or directory, open '/home/tadas/sources/sim31/frapps/impl/ordao/sc-deployment/ignition/deployments/op-sepolia-1/artifacts/Orec#Orec.dbg.json'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: '/home/tadas/sources/sim31/frapps/impl/ordao/sc-deployment/ignition/deployments/op-sepolia-1/artifacts/Orec#Orec.dbg.json'
}

When I place the expected debug file, the error goes away.

Then another error appears:

Error: ENOENT: no such file or directory, open '/home/tadas/sources/sim31/frapps/impl/ordao/sc-deployment/ignition/deployments/build-info/2bf29f558aacadc638c9589b99d7fcc1.json'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: '/home/tadas/sources/sim31/frapps/impl/ordao/sc-deployment/ignition/deployments/build-info/2bf29f558aacadc638c9589b99d7fcc1.json'
}

Again I solve this by copying expected build-info files to the expected place. Then finally verification works.

Would be nice if ignition would either handle this automatically (although I understand that the user would then have to specify these debug and build-info files somehow) or there would be some warnings in the docs about these extra manual steps.

Minimal reproduction steps

  1. Create sample hardhat project 1, compile it;
  2. Create hardhat project 2, create ignition module that tries to deploy artifact from project 1 (as described here);
  3. Use ignition to deploy to testnet (I was deploying to OP Sepolia)
  4. Try using ignition to verify testnet deployment

Search terms

ignition, verification

@kanej kanej assigned kanej and unassigned schaable Aug 21, 2024
@kanej kanej added status:ready This issue is ready to be worked on type:bug Something isn't working and removed status:triaging labels Aug 21, 2024
@kanej
Copy link
Member

kanej commented Aug 21, 2024

I think there are a several things we should consider doing here:

  1. Provide a warning before deploying if external artifacts are detected indicating that verification won't be possible (due to lack of build info).
  2. Add a mechanism to allow associating an external artifact with the build info needed to do a full verification

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:ready This issue is ready to be worked on type:bug Something isn't working
Projects
Status: To-do
Development

No branches or pull requests

3 participants