From 31cfcfd3e1509d6bf652f96a5dbecd1dba583cbe Mon Sep 17 00:00:00 2001 From: Turadg Aleahmad Date: Tue, 23 Apr 2024 08:16:34 -0700 Subject: [PATCH] fix: binaries during local yarn install --- packages/synthetic-chain/src/cli/doctor.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/synthetic-chain/src/cli/doctor.ts b/packages/synthetic-chain/src/cli/doctor.ts index 07289cc1..500b89ed 100644 --- a/packages/synthetic-chain/src/cli/doctor.ts +++ b/packages/synthetic-chain/src/cli/doctor.ts @@ -35,7 +35,11 @@ const fixupProposal = (proposal: ProposalInfo) => { // refresh install execSync('rm -rf node_modules', { cwd: proposalPath }); - execSync('yarn install', { cwd: proposalPath }); + // install to update yarn.lock and get importable typed modules but + // skip building because the proposal never runs on the local filesystem. + // Without this the local environment may install binaries (e.g. better_sqlite3.node) + // that fail when mounted in the Docker environment by the test debug mode. + execSync('yarn install --mode=skip-build', { cwd: proposalPath }); } } };