Skip to content

Commit 44db288

Browse files
committed
fix: remove prepublishOnly from @hyperlane-xyz/core
The prepublishOnly script re-ran `pnpm build && pnpm build:zk && pnpm build:tron` inside `changeset publish`, causing EPIPE crashes when hardhat tried to compile solidity 0.8.33 in the resource-constrained publish subprocess. This was redundant since the release workflow already runs `pnpm build` before publishing. Replace with a `prepack` guard that just verifies dist/ exists. Move build:zk and build:tron into the release script and beta workflow so they run once, before publish, not inside it.
1 parent 26d682b commit 44db288

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"coverage": "turbo run coverage",
1818
"version:prepare": "pnpm changeset version && turbo run version:update && pnpm install",
1919
"version:check": "pnpm changeset status",
20-
"release": "pnpm build && pnpm changeset publish",
20+
"release": "pnpm build && pnpm build:zk && pnpm changeset publish",
2121
"spellcheck": "typos --config .spellcheck/typos.toml",
2222
"spellcheck:diff": "bash .spellcheck/run-diff.sh",
2323
"postinstall": "husky install"

solidity/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
"build:zk": "pnpm hardhat-zk compile && tsc && node fix-typechain-ethers.mjs ./dist/typechain/factories && node generate-artifact-exports.mjs && ZKSYNC=true ./exportBuildArtifact.sh",
7575
"build:tron": "./build-tron.sh",
7676
"test:tron": "FOUNDRY_PROFILE=tron forge test --match-contract 'Tron(Create2|SafeERC20)Test' -vvv && bash test/tron/check-SafeERC20-diff.sh",
77-
"prepublishOnly": "pnpm build && pnpm build:zk && pnpm build:tron",
77+
"prepack": "[ -d dist ] || (echo 'Error: dist/ not found. Run pnpm build first.' && exit 1)",
7878
"lint": "solhint contracts/**/*.sol",
7979
"clean": "pnpm hardhat-esm clean && pnpm hardhat-zk clean && rm -rf ./dist ./cache ./cache-zk ./cache-tron ./artifacts-tron ./out-tron ./forge-cache-tron ./types ./coverage ./out ./forge-cache ./fixtures",
8080
"coverage": "pnpm fixtures && ./coverage.sh",

0 commit comments

Comments
 (0)