Skip to content

Declare the upgrades-core dependency the storage-layout task imports - #113

Open
Dusk1e wants to merge 1 commit into
FhenixProtocol:masterfrom
Dusk1e:declare-upgrades-core
Open

Declare the upgrades-core dependency the storage-layout task imports#113
Dusk1e wants to merge 1 commit into
FhenixProtocol:masterfrom
Dusk1e:declare-upgrades-core

Conversation

@Dusk1e

@Dusk1e Dusk1e commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

tasks/storageLayout.ts imports seven runtime functions from @openzeppelin/upgrades-corevalidate, solcInputOutputDecoder, concatRunData, getContractVersion, getStorageLayout, getStorageUpgradeReport and withValidationDefaults — but the package is not in the host-chain manifest. It resolves today only because pnpm hoists it into .pnpm/node_modules as a transitive dependency of @openzeppelin/hardhat-upgrades.

That makes the storage-layout job dependent on hoisting behavior and on a package it does not ask for. tsc --noEmit already reports it as TS2307: Cannot find module '@openzeppelin/upgrades-core', which is the same shape as the getProxyContract arity bug in the last release, where ts-node transpiled past a type error that tsc would have caught.

Declared it at ^1.41.0, the range @openzeppelin/hardhat-upgrades itself asks for, so the resolved version stays 1.44.2 and the lockfile gains three lines.

Tests: 116 of 116 pass. compile, storage-layout:check, check:size and solhint are unchanged. The TS2307 is gone and no other tsc diagnostic moved, 95 to 94.

tasks/storageLayout.ts calls validate, solcInputOutputDecoder, concatRunData,
getContractVersion, getStorageLayout, getStorageUpgradeReport and
withValidationDefaults from @openzeppelin/upgrades-core, but the package was
never declared. It resolved only because pnpm hoists it as a transitive
dependency of @openzeppelin/hardhat-upgrades.

Pinned to the same range hardhat-upgrades asks for, so the resolved version is
unchanged at 1.44.2.
@Dusk1e
Dusk1e requested a review from a team as a code owner August 25, 2026 07:33

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

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

Successfully merging this pull request may close these issues.

1 participant