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

Build fails with latest @tenderly/hardhat-tenderly #32

Closed
nikola-matic opened this issue Nov 2, 2022 · 1 comment
Closed

Build fails with latest @tenderly/hardhat-tenderly #32

nikola-matic opened this issue Nov 2, 2022 · 1 comment

Comments

@nikola-matic
Copy link

Deleting yarn.lock, and the installing dependencies via yarn, and finally attempting yarn build:sol fails with the following error:

yarn run v1.22.18
$ yarn build:sol && yarn build:ts
$ hardhat compile --force
An unexpected error occurred:

Error: Cannot find module 'tenderly'
Require stack:
- /tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/dist/tasks/push.js
- /tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/dist/tasks/index.js
- /tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/dist/index.js
- /tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/hardhat.config.ts
- /tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/hardhat/internal/core/config/config-loading.js
- /tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/hardhat/internal/cli/cli.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:995:15)
    at Function.Module._resolveFilename.sharedData.moduleResolveFilenameHook.installedValue [as _resolveFilename] (/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@cspotcode/source-map-support/source-map-support.js:811:30)
    at Function.Module._load (node:internal/modules/cjs/loader:841:27)
    at Module.require (node:internal/modules/cjs/loader:1061:19)
    at require (node:internal/modules/cjs/helpers:103:18)
    at Object.<anonymous> (/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/src/tasks/push.ts:3:1)
    at Module._compile (node:internal/modules/cjs/loader:1159:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1213:10)
    at Object.require.extensions.<computed> [as .js] (/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/ts-node/src/index.ts:1608:43)
    at Module.load (node:internal/modules/cjs/loader:1037:32) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/dist/tasks/push.js',
    '/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/dist/tasks/index.js',
    '/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/@tenderly/hardhat-tenderly/dist/index.js',
    '/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/hardhat.config.ts',
    '/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/hardhat/internal/core/config/config-loading.js',
    '/tmp/ext-test-Gnosis-Protocol-V2-mzyKps/ext/node_modules/hardhat/internal/cli/cli.js'
  ]
}
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

@tenderly/hardhat-tenderly had a release today, which coincides with this failure; there is a warning about an unsatisfied dependency, namely:

warning " > @tenderly/[email protected]" has unmet peer dependency "tenderly@^0.0.2".

Oddly enough, downgrading to version 1.2.0 didn't work either (not sure why we didn't see that before), but that one also complains about unmet tenderly@^0.0.1, so that might be a clue.

Finally, downgrading to @tenderly/[email protected] allows the build to run normally.

fedgiac added a commit that referenced this issue May 4, 2023
Updates remaining outdated packages that are tightly coupled together
and need to be updated in parallel.

Note that Ethers has been updated to the latest minor version for v5, an
upgrade to v6 requires many changes and will trigger a new major release
of this project.

Also note that I only updated Tenderly to v1.1 and froze it at that
minor version. Using the latest version would require a few code
changes, importing an extra package, increase the number of network
request on _any_ invocation of `hardhat` and would annoyingly increase
the amount of logs that are printed every time `hardhat` is called (the
extra logs might be reduced but not configured away as the logging level
is hardcoded in the plugin). Issue #32 is related.

The changes to the proxy code appear to be caused by a change in
behavior in `hardhat-deploy`, the new code should have the same effect
(this is confirmed by our tests). I found a related issue
[here](wighawag/hardhat-deploy#294) and the
new behavior appears to be intended behavior.

### Test Plan

Test a few commands and verify that everything works as usual, notably
`yarn deploy` and `yarn bench:trace`.
@mfw78
Copy link
Contributor

mfw78 commented Oct 19, 2023

This issue appears to have been fixed in #49.

@mfw78 mfw78 closed this as completed Oct 19, 2023
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

2 participants