synfull 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -4,7 +4,7 @@ Synfull is a local-first host monitoring dashboard for Windows and Linux, provid
4
4
 
5
5
  ## Install from npm
6
6
 
7
- Requirements: Node.js 18+, Python 3.10+, and npm. The CLI creates its own Python virtual environment and installs the backend dependencies when needed. Linux requires Python build prerequisites when a dependency has no wheel for the host platform.
7
+ Requirements: Node.js 18+, Python 3.10+, and npm. The CLI creates its own Python virtual environment and installs the backend dependencies when needed. On Ubuntu/Debian, install `python3-venv` (or the matching `python3.X-venv` package) if venv creation reports that pip is missing. Linux may also require build prerequisites when a dependency has no wheel for the host platform.
8
8
 
9
9
  ```sh
10
10
  npm install -g synfull
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "synfull",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Local-first cross-platform host monitoring dashboard",
5
5
  "license": "MIT",
6
6
  "type": "commonjs",
@@ -61,6 +61,25 @@ function ensureRuntime() {
61
61
  const python = pythonCommand()
62
62
  run(python.command, [...python.prefix, '-m', 'venv', path.join(APP_DIR, '.venv')])
63
63
  }
64
+ const pipAvailable = spawnSync(RUNTIME, ['-m', 'pip', '--version'], { stdio: 'ignore', windowsHide: true }).status === 0
65
+ if (!pipAvailable) {
66
+ const python = pythonCommand()
67
+ const repair = spawnSync(python.command, [...python.prefix, '-m', 'venv', '--upgrade-deps', '--upgrade', path.join(APP_DIR, '.venv')], {
68
+ encoding: 'utf8', windowsHide: true,
69
+ })
70
+ if (repair.status !== 0) {
71
+ const detail = (repair.stderr || repair.stdout || '').trim()
72
+ if (detail) console.error(detail)
73
+ const platformFix = WINDOWS
74
+ ? 'Repair or reinstall Python with its pip/venv components, then rerun `synfull setup`.'
75
+ : 'On Ubuntu/Debian install venv support (`sudo apt install python3-venv`, or the matching `python3.X-venv` package), remove the incomplete venv at ~/.local/share/synfull/app/.venv, then rerun `synfull setup`.'
76
+ throw new Error(`The Python virtual environment is missing pip. ${platformFix}`)
77
+ }
78
+ }
79
+ const pipReady = spawnSync(RUNTIME, ['-m', 'pip', '--version'], { stdio: 'ignore', windowsHide: true }).status === 0
80
+ if (!pipReady) {
81
+ throw new Error('The Python virtual environment still has no pip. Install the Python venv support package and recreate the runtime, then rerun `synfull setup`.')
82
+ }
64
83
  const requirementsPath = path.join(APP_DIR, 'backend', 'requirements-runtime.txt')
65
84
  const requirementsHash = crypto.createHash('sha256').update(fs.readFileSync(requirementsPath)).digest('hex')
66
85
  const installedHashPath = path.join(APP_DIR, '.runtime-requirements-hash')