Skip to content

Commit a5f097a

Browse files
OttoAllmendingerllm-git
andcommitted
ci: simplify build process and downgrade npm to 10.x
Split wasm-utxo and wasm-utxo-ui builds, improve webpack resolution paths, and add debugging for workspace setup. The change downgrades npm from 11.5.1 to version 10.x for better compatibility. Issue: BTC-2786 Co-authored-by: llm-git <[email protected]>
1 parent 0f24d05 commit a5f097a

File tree

2 files changed

+26
-4
lines changed

2 files changed

+26
-4
lines changed

.github/workflows/build-and-test.yaml

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ jobs:
3434
with:
3535
node-version: 20
3636

37-
- name: Ensure npm 11.5.1
37+
- name: Ensure npm 10.x
3838
run: |
39-
npm install -g npm@11.5.1
39+
npm install -g npm@10
4040
4141
- name: Install wasm tools
4242
run: |
@@ -69,8 +69,24 @@ jobs:
6969
run: cargo deny check
7070
working-directory: packages/wasm-utxo
7171

72-
- name: build packages
73-
run: npx lerna run build --stream
72+
- name: Build wasm-utxo
73+
run: npm run build
74+
working-directory: packages/wasm-utxo
75+
76+
- name: Debug workspace setup
77+
run: |
78+
echo "=== Checking symlink ==="
79+
ls -la node_modules/@bitgo/
80+
echo "=== Checking wasm-utxo dist ==="
81+
ls -la packages/wasm-utxo/dist/ || echo "dist directory not found"
82+
echo "=== Checking if dist/esm/index.js exists ==="
83+
ls -la packages/wasm-utxo/dist/esm/index.js || echo "index.js not found"
84+
echo "=== Checking package.json exports from symlink ==="
85+
cat node_modules/@bitgo/wasm-utxo/package.json | grep -A 10 "exports" || echo "No exports found"
86+
87+
- name: Build remaining packages
88+
run: npm run build
89+
working-directory: packages/wasm-utxo-ui
7490

7591
- name: Check Source Code Formatting
7692
run: npm run check-fmt

packages/wasm-utxo-ui/webpack.config.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ module.exports = {
2222
},
2323
resolve: {
2424
extensions: [".ts", ".js"],
25+
modules: [
26+
path.resolve(__dirname, "node_modules"),
27+
path.resolve(__dirname, "../../node_modules"),
28+
"node_modules"
29+
],
30+
conditionNames: ["import", "module", "default"],
2531
},
2632
output: {
2733
filename: "bundle.js",

0 commit comments

Comments
 (0)