Skip to content

Commit 1c2ee86

Browse files
Node.js install error documentation (#549)
1 parent 33e6051 commit 1c2ee86

File tree

5 files changed

+2433
-2937
lines changed

5 files changed

+2433
-2937
lines changed

.changeset/sour-spiders-rhyme.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@powersync/node': patch
3+
---
4+
5+
Update README with common installation issues section

demos/angular-supabase-todolist/angular.json

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,7 @@
2020
"customWebpackConfig": {
2121
"path": "./extra-webpack.config.js"
2222
},
23-
"allowedCommonJsDependencies": [
24-
"js-logger",
25-
"ws"
26-
],
23+
"allowedCommonJsDependencies": ["js-logger", "ws"],
2724
"outputPath": "dist",
2825
"index": "src/index.html",
2926
"main": "src/main.ts",
@@ -39,7 +36,7 @@
3936
{
4037
"type": "initial",
4138
"maximumWarning": "500kb",
42-
"maximumError": "5mb"
39+
"maximumError": "6mb"
4340
},
4441
{
4542
"type": "anyComponentStyle",

demos/angular-supabase-todolist/package.json

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -14,27 +14,27 @@
1414
},
1515
"private": true,
1616
"dependencies": {
17-
"@angular/animations": "^18.1.1",
18-
"@angular/common": "^18.1.1",
19-
"@angular/compiler": "^18.1.1",
20-
"@angular/core": "^18.1.1",
21-
"@angular/forms": "^18.1.1",
22-
"@angular/platform-browser": "^18.1.1",
23-
"@angular/platform-browser-dynamic": "^18.1.1",
24-
"@angular/router": "^18.1.1",
25-
"@angular/service-worker": "^18.1.1",
17+
"@angular/animations": "^19.2.4",
18+
"@angular/common": "^19.2.4",
19+
"@angular/compiler": "^19.2.4",
20+
"@angular/core": "^19.2.4",
21+
"@angular/forms": "^19.2.4",
22+
"@angular/platform-browser": "^19.2.4",
23+
"@angular/platform-browser-dynamic": "^19.2.4",
24+
"@angular/router": "^19.2.4",
25+
"@angular/service-worker": "^19.2.4",
2626
"@journeyapps/wa-sqlite": "^1.2.0",
2727
"@powersync/web": "workspace:*",
2828
"@supabase/supabase-js": "^2.44.4",
2929
"rxjs": "~7.8.1",
3030
"tslib": "^2.6.3",
31-
"zone.js": "~0.14.8"
31+
"zone.js": "~0.15.0"
3232
},
3333
"devDependencies": {
34-
"@angular-builders/custom-webpack": "^18.0.0",
35-
"@angular-devkit/build-angular": "^18.1.1",
36-
"@angular/cli": "^18.1.1",
37-
"@angular/compiler-cli": "^18.1.1",
34+
"@angular-builders/custom-webpack": "^19.0.0",
35+
"@angular-devkit/build-angular": "^19.2.5",
36+
"@angular/cli": "^19.2.5",
37+
"@angular/compiler-cli": "^19.2.4",
3838
"dotenv": "^16.4.5",
3939
"http-server": "^14.1.1",
4040
"typescript": "~5.5.3"

packages/node/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,27 @@ npm install @powersync/node
2626
Both `@powersync/node` and the `better-sqlite3` packages have install scripts that need to run to compile
2727
or download sqlite3 and PowerSync binaries.
2828

29+
### Common Installation Issues
30+
31+
The `better-sqlite` package requires native compilation, which depends on certain system tools. This compilation process is handled by `node-gyp` and may fail if required dependencies are missing or misconfigured.
32+
33+
#### Node-gyp Version Conflicts
34+
35+
`better-sqlite` depends on `node-gyp@^11`, but some project configurations may introduce multiple versions of `node-gyp`, potentially causing build issues.
36+
37+
#### Python Dependency Issues
38+
39+
`node-gyp` requires Python for compilation. If your project uses `node-gyp` below version `10` and your system has Python `3.12` or later, you may encounter the following error:
40+
41+
```python
42+
ModuleNotFoundError: No module named 'distutils'
43+
```
44+
45+
To resolve this, either:
46+
47+
- Upgrade `node-gyp` to version 10 or later.
48+
- Install Python [setuptools](https://pypi.org/project/setuptools/), which includes `distutils`.
49+
2950
# Getting Started
3051

3152
The [Node.js SDK reference](https://docs.powersync.com/client-sdk-references/node)

0 commit comments

Comments
 (0)