diff --git a/BUILD.md b/BUILD.md index 85b3406..512e9a1 100644 --- a/BUILD.md +++ b/BUILD.md @@ -1,9 +1,83 @@ -# BUILD - -## Prequisities - -1. `npm i pgk -g` - -## Build excutable - -1. `npm run build` +# BUILD + +## Prerequisites + +1. Install build tool globally (choose one): + - **pkg**: `npm i pkg -g` (Node 18 max, deprecated) + - **nexe**: `npm i nexe -g` (Node 20+, actively maintained) +2. Install dependencies: `npm install` + +## Build Executable + +### Using Nexe (Recommended - Node 20 support) + +**Quick Build (Current Platform):** +```bash +npm run build:nexe +``` + +**Cross-Platform Build (Windows + Linux):** +```bash +npm run build:nexe +``` + +This will create platform-specific packages in `dist/` with all necessary files: +- `dist/windows-x64/` - Windows executable and runtime files +- `dist/linux-x64/` - Linux executable and runtime files + +### Using pkg (Legacy - Node 18 max) + +**Quick Build (Current Platform):** +```bash +npm run build +``` + +**Cross-Platform Build (Windows + Linux):** +```bash +npm run build:cross +``` + +### Platform-Specific Builds + +Build only for Windows: +```bash +npm run build:windows +``` + +Build only for Linux: +```bash +npm run build:linux +``` + +## SQLite3 Native Module + +If you encounter issues with SQLite3 bindings: + +1. Rebuild for current platform: +```bash +npm run rebuild:sqlite +``` + +2. For cross-platform builds, you may need to: + - Build on the target platform, OR + - Manually copy the appropriate `.node` bindings to `node_modules/sqlite3/build/Release/` + +## Troubleshooting + +### Missing native bindings +If the executable fails with "Cannot find module", ensure sqlite3 native bindings are included: +```bash +npm rebuild sqlite3 --build-from-source +npm run build:cross +``` + +### Windows Defender / Antivirus +Packaged executables may be flagged. Add an exception for the dist folder. + +## Distribution + +Each platform package in `dist/` is self-contained and includes: +- Executable binary +- Data directories (data, locales, templates, tmp, trash) +- Sample .env configuration +- README with platform-specific instructions diff --git a/app.js b/app.js index 9164419..7dab03a 100644 --- a/app.js +++ b/app.js @@ -34,8 +34,7 @@ import passport from 'passport'; import passportlocal from 'passport-local'; import NodeMediaServer from 'node-media-server'; import expressSession from 'express-session'; -import sqlite3 from 'connect-sqlite3'; -const SQLiteStore = sqlite3(expressSession); +import BetterExpressStore from 'better-express-store'; const cookieParser = CookieParser(config.sessionKey); @@ -156,16 +155,10 @@ app.use(cookieParser); app.use(express.static(path.join(__dirname, 'public'))); app.use("/video/", express.static(path.join(__dirname, 'data', 'video'))); -const sessionStore = new SQLiteStore({ - dir: "./data", - db: "sessions.db" - -}); - app.use(expressSession({ key: 'express.sid', secret: config.sessionKey, - store: sessionStore, + store: BetterExpressStore({ dbPath: "./data/sessions.db" }), resave: true, saveUninitialized: true, cookie: { diff --git a/build-nexe.js b/build-nexe.js new file mode 100644 index 0000000..a2a9002 --- /dev/null +++ b/build-nexe.js @@ -0,0 +1,171 @@ +import fs from "fs-extra"; +import { execSync } from "child_process"; +import path from "path"; +import { fileURLToPath } from 'url'; + +const __filename = fileURLToPath(import.meta.url); +const __dirname = path.dirname(__filename); + +const platforms = [ + { target: "windows-x64-20.18.1", platform: "win32", arch: "x64", ext: ".exe" }, + { target: "linux-x64-20.18.1", platform: "linux", arch: "x64", ext: "" } +]; + +const toCopy = ["data", "locales", "templates", "tmp", "trash"]; + +console.log("๐Ÿš€ Starting nexe cross-platform build process...\n"); + +// Clean dist directory +console.log("๐Ÿงน Cleaning dist directory..."); +if (fs.existsSync("./dist")) { + fs.rmSync("./dist", { recursive: true }); +} +fs.mkdirSync("./dist", { recursive: true }); + +// Build webpack bundle +console.log("๐Ÿ“ฆ Building webpack bundle..."); +try { + execSync("npx webpack", { stdio: "inherit" }); +} catch (error) { + console.error("โŒ Webpack build failed:", error.message); + process.exit(1); +} + +// Copy common files +console.log("\n๐Ÿ“‹ Copying common files..."); +for (const dir of toCopy) { + if (fs.existsSync(`./${dir}`)) { + console.log(` โœ“ Copying ${dir}...`); + fs.cpSync(`./${dir}`, `./dist/${dir}`, { recursive: true }); + } +} + +if (fs.existsSync("./.env.example")) { + console.log(" โœ“ Copying .env example..."); + fs.cpSync("./.env.example", "./dist/.env"); +} + +// Build for each platform +for (const { target, platform, arch, ext } of platforms) { + console.log(`\n๐Ÿ”จ Building for ${target}...`); + + const platformDir = `./dist/${platform}-${arch}`; + fs.mkdirSync(platformDir, { recursive: true }); + + const outputFile = path.join(platformDir, `infoscreen3${ext}`); + + // Prepare sqlite3 native bindings for the target platform + console.log(` โš™๏ธ Preparing native modules for ${platform}...`); + + const isCurrentPlatform = + (platform === "win32" && process.platform === "win32") || + (platform === "linux" && process.platform === "linux"); + + if (!isCurrentPlatform) { + console.log(` โš ๏ธ Warning: Cross-compiling from ${process.platform} to ${platform}`); + console.log(` Native bindings will need to be rebuilt on target platform or provided manually`); + } else { + // Rebuild native modules for Node.js 20.18.0 specifically + console.log(` โš™๏ธ Rebuilding native modules for Node.js 20.18.1...`); + try { + const nodeVersion = "20.18.1"; + const rebuildCmd = `npm rebuild better-sqlite3 --build-from-source --target=${nodeVersion} --target_arch=x64 --dist-url=https://nodejs.org/download/release`; + execSync(rebuildCmd, { stdio: "inherit" }); + + // Verify and create versioned binding path for better-sqlite3 + const bindingPath = path.join("node_modules", "better-sqlite3", "build", "Release", "better_sqlite3.node"); + if (fs.existsSync(bindingPath)) { + const versionedDir = path.join("node_modules", "better-sqlite3", "lib", "binding", "node-v115-win32-x64"); + fs.mkdirSync(versionedDir, { recursive: true }); + fs.copyFileSync(bindingPath, path.join(versionedDir, "better_sqlite3.node")); + console.log(` โœ… better-sqlite3 rebuilt and versioned binding created`); + } + } catch (error) { + console.warn(` โš ๏ธ Could not rebuild better-sqlite3: ${error.message}`); + } + } + + // Build with nexe + console.log(` ๐Ÿ“ฆ Running nexe for ${target}...`); + console.log(` โš ๏ธ Note: Using --build will compile Node.js from source (this may take 10-30 minutes)...`); + try { + const nexeCmd = `nexe ./webpack/bundle.cjs -t ${target} -o "${outputFile}" --build --verbose`; + console.log(` Executing: ${nexeCmd}`); + execSync(nexeCmd, { stdio: "inherit" }); + console.log(` โœ… Successfully built ${target}`); + } catch (error) { + console.error(` โŒ Failed to build ${target}:`, error.message); + continue; + } + + // Copy runtime files to platform directory + console.log(` ๐Ÿ“‚ Copying runtime files to ${platformDir}...`); + for (const dir of toCopy) { + if (fs.existsSync(`./${dir}`)) { + fs.cpSync(`./${dir}`, `${platformDir}/${dir}`, { recursive: true }); + } + } + + if (fs.existsSync("./.env.example")) { + fs.cpSync("./.env.example", `${platformDir}/.env`); + } + + // Copy native modules directory structure + const nativeModules = [ + "node_modules/better-sqlite3", + "node_modules/bufferutil", + "node_modules/utf-8-validate" + ]; + + for (const modulePath of nativeModules) { + if (fs.existsSync(modulePath)) { + const targetPath = path.join(platformDir, modulePath); + fs.mkdirSync(path.dirname(targetPath), { recursive: true }); + fs.cpSync(modulePath, targetPath, { recursive: true }); + console.log(` โœ“ Copied ${modulePath}`); + } + } + + // Create platform-specific README + const readmeContent = `# Infoscreen3 - ${platform} ${arch} + +## Installation + +1. Extract this archive to your desired location +2. Edit the .env file with your configuration +3. Run the executable: + ${platform === "win32" ? " .\\infoscreen3.exe" : " ./infoscreen3"} + +## Notes + +- All data will be stored in the 'data' directory +- Logs and temporary files are in 'tmp' and 'trash' directories +- Translations are in the 'locales' directory +- Templates are in the 'templates' directory +- Native modules (better-sqlite3, etc.) are included in node_modules/ + +## Native Modules + +This build includes native modules. If you encounter issues: +1. The native modules were compiled for ${platform}-${arch} +2. You may need to rebuild them on the target system if cross-compiled +3. Run: npm rebuild better-sqlite3 bufferutil utf-8-validate --build-from-source + +For more information, visit: https://github.com/reaby/infoscreen3 +`; + + fs.writeFileSync(`${platformDir}/README.txt`, readmeContent); + + console.log(` โœ… Platform package complete: ${platformDir}`); +} + +console.log("\n๐ŸŽ‰ Nexe cross-platform build completed successfully!"); +console.log("\n๐Ÿ“ฆ Build outputs:"); +platforms.forEach(({ platform, arch }) => { + const dir = `./dist/${platform}-${arch}`; + if (fs.existsSync(dir)) { + const files = fs.readdirSync(dir); + const exe = files.find(f => f.startsWith("infoscreen3")); + console.log(` โœ“ ${dir}${exe ? ` (${exe})` : ""}`); + } +}); diff --git a/build.json b/build.json deleted file mode 100644 index 4350455..0000000 --- a/build.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "name": "infoscreen3", - "version": "1.6.4", - "private": true, - "bin": "./webpack/bundle.js", - "module": "false", - "pkg": { - "scripts": ["./webpack/*.bundle.js", "./node_modules/socket.io/"], - "assets": ["./node_modules/socket.io/"], - "targets": [ "node18-windows-x64", "node18-linux-x64"], - "outputPath": "dist" - } -} \ No newline at end of file diff --git a/infoscreen3.js b/infoscreen3.js index 861f190..0bfc6a6 100644 --- a/infoscreen3.js +++ b/infoscreen3.js @@ -1,89 +1,88 @@ -#!/usr/bin/env node - -/** - * Module dependencies. - */ -import chalk from 'chalk'; -import config from './config.js'; -import { app, server } from "./app.js"; - - -/** - * Get port from environment and store in Express. - */ - -let port = normalizePort(config.serverListenPort || '8000'); -app.set('port', port); - -/** - * Create HTTP server. - */ - -/** - * Listen on provided port, on all network interfaces. - */ - -server.listen(port); -server.on('error', onError); -server.on('listening', onListening); - -/** - * Normalize a port into a number, string, or false. - */ - -function normalizePort(val) { - let port = parseInt(val, 10); - - if (isNaN(port)) { - // named pipe - return val; - } - - if (port >= 0) { - // port number - return port; - } - - return false; -} - -/** - * Event listener for HTTP server "error" event. - */ - -function onError(error) { - if (error.syscall !== 'listen') { - throw error; - } - - let bind = typeof port === 'string' - ? 'Pipe ' + port - : 'Port ' + port; - - // handle specific listen errors with friendly messages - switch (error.code) { - case 'EACCES': - console.error(bind + ' requires elevated privileges'); - process.exit(1); - break; - case 'EADDRINUSE': - console.error(bind + ' is already in use'); - process.exit(1); - break; - default: - throw error; - } -} - -/** - * Event listener for HTTP server "listening" event. - */ - -function onListening() { - let addr = server.address(); - let bind = typeof addr === 'string' - ? 'pipe ' + addr - : 'port ' + addr.port; - console.log('Infoscreen is now accessible at ' + chalk.bold.white(config.serverUrl)); - console.log(chalk.green(">>") + chalk.white("Start complete.") + chalk.green("<<")); -} +#!/usr/bin/env node + +/** + * Module dependencies. + */ +import config from './config.js'; +import { app, server } from "./app.js"; + + +/** + * Get port from environment and store in Express. + */ + +let port = normalizePort(config.serverListenPort || '8000'); +app.set('port', port); + +/** + * Create HTTP server. + */ + +/** + * Listen on provided port, on all network interfaces. + */ + +server.listen(port); +server.on('error', onError); +server.on('listening', onListening); + +/** + * Normalize a port into a number, string, or false. + */ + +function normalizePort(val) { + let port = parseInt(val, 10); + + if (isNaN(port)) { + // named pipe + return val; + } + + if (port >= 0) { + // port number + return port; + } + + return false; +} + +/** + * Event listener for HTTP server "error" event. + */ + +function onError(error) { + if (error.syscall !== 'listen') { + throw error; + } + + let bind = typeof port === 'string' + ? 'Pipe ' + port + : 'Port ' + port; + + // handle specific listen errors with friendly messages + switch (error.code) { + case 'EACCES': + console.error(bind + ' requires elevated privileges'); + process.exit(1); + break; + case 'EADDRINUSE': + console.error(bind + ' is already in use'); + process.exit(1); + break; + default: + throw error; + } +} + +/** + * Event listener for HTTP server "listening" event. + */ + +function onListening() { + let addr = server.address(); + let bind = typeof addr === 'string' + ? 'pipe ' + addr + : 'port ' + addr.port; + console.log('Infoscreen is now accessible at ' + config.serverUrl); + console.log('>> Start complete. <<'); +} diff --git a/modules/cli.js b/modules/cli.js index 72d77a3..e2aaced 100644 --- a/modules/cli.js +++ b/modules/cli.js @@ -1,63 +1,62 @@ -import 'dotenv/config' -import chalk from 'chalk'; -let lastStamp = ""; - -export default { - error: function (error, title) { - if (title == null) { - title = ""; - } - this.log(chalk.bold.red("[Error]" + title) + " " + error); - }, - - info: function (string, category) { - - this.log(chalk.cyan("[" + (category || "Info") + "] ") + string); - }, - - debug: function (string) { - console.log(chalk.bold.black("[Debug] " + string)); - }, - - success: function (string) { - this.log(string + chalk.green(" [Success]")); - }, - - log: function (string) { - if (process.env.DEBUG != "true") return; - let now = getDateTime(); - if (lastStamp != now) { - lastStamp = now; - now = "\n" + now + "\n" - } else { - now = ""; - } - - console.log(now + string); - } -}; - -function getDateTime() { - - var date = new Date(); - - var hour = date.getHours(); - hour = (hour < 10 ? "0" : "") + hour; - - var min = date.getMinutes(); - min = (min < 10 ? "0" : "") + min; - - var sec = date.getSeconds(); - sec = (sec < 10 ? "0" : "") + sec; - - var year = date.getFullYear(); - - var month = date.getMonth() + 1; - month = (month < 10 ? "0" : "") + month; - - var day = date.getDate(); - day = (day < 10 ? "0" : "") + day; - - return year + "-" + month + "-" + day + " " + hour + ":" + min + ":" + sec; - +import 'dotenv/config' +let lastStamp = ""; + +export default { + error: function (error, title) { + if (title == null) { + title = ""; + } + this.log("[Error]" + title + " " + error); + }, + + info: function (string, category) { + + this.log("[" + (category || "Info") + "] " + string); + }, + + debug: function (string) { + console.log("[Debug] " + string); + }, + + success: function (string) { + this.log(string + " [Success]"); + }, + + log: function (string) { + if (process.env.DEBUG != "true") return; + let now = getDateTime(); + if (lastStamp != now) { + lastStamp = now; + now = "\n" + now + "\n" + } else { + now = ""; + } + + console.log(now + string); + } +}; + +function getDateTime() { + + var date = new Date(); + + var hour = date.getHours(); + hour = (hour < 10 ? "0" : "") + hour; + + var min = date.getMinutes(); + min = (min < 10 ? "0" : "") + min; + + var sec = date.getSeconds(); + sec = (sec < 10 ? "0" : "") + sec; + + var year = date.getFullYear(); + + var month = date.getMonth() + 1; + month = (month < 10 ? "0" : "") + month; + + var day = date.getDate(); + day = (day < 10 ? "0" : "") + day; + + return year + "-" + month + "-" + day + " " + hour + ":" + min + ":" + sec; + } \ No newline at end of file diff --git a/modules/websocket.js b/modules/websocket.js index fd66507..e67f328 100644 --- a/modules/websocket.js +++ b/modules/websocket.js @@ -5,7 +5,6 @@ import admin from './admin.js'; import adminLobby from './adminLobby.js'; import cli from './cli.js'; import _bundleManager from './bundleManager.js'; -import chalk from 'chalk'; import fs from 'fs'; /** @@ -24,7 +23,7 @@ export default function (pluginManager, io, dispatcher) { /** @type {admin[]} */ let adminView = []; - console.log(chalk.green(">> ") + "InfoScreen3" + chalk.green("<<")); + console.log(">> InfoScreen3 <<"); cli.log("Checking for write permissions..."); try { diff --git a/package-lock.json b/package-lock.json index 541415d..42b887e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,11 +9,11 @@ "version": "1.7.0", "dependencies": { "basic-auth": "^2.0.1", + "better-express-store": "^1.0.5", + "better-sqlite3": "^12.5.0", "bufferutil": "4.0.7", - "chalk": "4.1.2", "connect-busboy": "^1.0.0", "connect-ensure-login": "^0.1.1", - "connect-sqlite3": "^0.9.16", "cookie-parser": "^1.4.7", "cors": "^2.8.5", "daemon": "1.1.0", @@ -37,13 +37,12 @@ "rate-limiter-flexible": "2.4.1", "sanitize-filename": "^1.6.3", "socket.io": "^4.8.1", - "sqlite3": "^5.1.7", "twig": "^1.17.1", "utf-8-validate": "5.0.10", "xmlhttprequest-ssl": "^4.0.0" }, "bin": { - "infoscreen3": "webpack/bundle.js" + "infoscreen3": "webpack/bundle.cjs" }, "devDependencies": { "@babel/plugin-transform-modules-commonjs": "^7.27.1", @@ -1704,12 +1703,6 @@ "node": ">=14.17.0" } }, - "node_modules/@gar/promisify": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/@gar/promisify/-/promisify-1.1.3.tgz", - "integrity": "sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw==", - "optional": true - }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.13", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", @@ -1759,56 +1752,11 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, - "node_modules/@npmcli/fs": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/@npmcli/fs/-/fs-1.1.1.tgz", - "integrity": "sha512-8KG5RD0GVP4ydEzRn/I4BNDuxDtqVbOdm8675T49OIG/NGhaK0pjPX7ZcDlvKYbA+ulvVK3ztfcF4uBdOxuJbQ==", - "optional": true, - "dependencies": { - "@gar/promisify": "^1.0.1", - "semver": "^7.3.5" - } - }, - "node_modules/@npmcli/move-file": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@npmcli/move-file/-/move-file-1.1.2.tgz", - "integrity": "sha512-1SUf/Cg2GzGDyaf15aR9St9TWlb+XvbZXWpDx8YKs7MLzMH/BCeopv+y9vzrzgkfykCGuWOlSu3mZhj2+FQcrg==", - "deprecated": "This functionality has been moved to @npmcli/fs", - "optional": true, - "dependencies": { - "mkdirp": "^1.0.4", - "rimraf": "^3.0.2" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/@npmcli/move-file/node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "optional": true, - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/@socket.io/component-emitter": { "version": "3.1.2", "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.2.tgz", "integrity": "sha512-9BCxFwvbGg/RsZK9tjXd8s4UcwR0MWeFQ1XEKIQVVvAGJyINdrqKMcTRyLoK8Rse1GjzLV9cwjWV1olXRWEXVA==" }, - "node_modules/@tootallnate/once": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz", - "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==", - "optional": true, - "engines": { - "node": ">= 6" - } - }, "node_modules/@types/cookie": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/@types/cookie/-/cookie-0.4.1.tgz", @@ -2085,12 +2033,6 @@ "dev": true, "license": "Apache-2.0" }, - "node_modules/abbrev": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", - "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", - "optional": true - }, "node_modules/accepts": { "version": "1.3.8", "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.8.tgz", @@ -2129,54 +2071,6 @@ "acorn": "^8.14.0" } }, - "node_modules/agent-base": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", - "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", - "optional": true, - "dependencies": { - "debug": "4" - }, - "engines": { - "node": ">= 6.0.0" - } - }, - "node_modules/agentkeepalive": { - "version": "4.2.1", - "resolved": "https://registry.npmjs.org/agentkeepalive/-/agentkeepalive-4.2.1.tgz", - "integrity": "sha512-Zn4cw2NEqd+9fiSVWMscnjyQ1a8Yfoc5oBajLeo5w+YBHgDUcEBY2hS4YpTz6iN5f/2zQiktcuM6tS8x1p9dpA==", - "optional": true, - "dependencies": { - "debug": "^4.1.0", - "depd": "^1.1.2", - "humanize-ms": "^1.2.1" - }, - "engines": { - "node": ">= 8.0.0" - } - }, - "node_modules/agentkeepalive/node_modules/depd": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", - "integrity": "sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==", - "optional": true, - "engines": { - "node": ">= 0.6" - } - }, - "node_modules/aggregate-error": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/aggregate-error/-/aggregate-error-3.1.0.tgz", - "integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==", - "optional": true, - "dependencies": { - "clean-stack": "^2.0.0", - "indent-string": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/ajv": { "version": "8.17.1", "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.17.1.tgz", @@ -2225,19 +2119,11 @@ "ajv": "^8.8.2" } }, - "node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "optional": true, - "engines": { - "node": ">=8" - } - }, "node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "license": "MIT", "dependencies": { "color-convert": "^2.0.1" }, @@ -2248,12 +2134,6 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, - "node_modules/aproba": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/aproba/-/aproba-2.0.0.tgz", - "integrity": "sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ==", - "optional": true - }, "node_modules/array-flatten": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", @@ -3616,6 +3496,26 @@ "tsscmp": "^1.0.6" } }, + "node_modules/better-express-store": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/better-express-store/-/better-express-store-1.0.5.tgz", + "integrity": "sha512-IV2zaQ1zvj2+k2FvNSYTYHDYNYi6DBE1FyEiK7IpXJ+BJSmG7/xF5jxtZ5HOgsmA99Nzlno/EBiGPEh4tGdvkA==", + "license": "MIT" + }, + "node_modules/better-sqlite3": { + "version": "12.5.0", + "resolved": "https://registry.npmjs.org/better-sqlite3/-/better-sqlite3-12.5.0.tgz", + "integrity": "sha512-WwCZ/5Diz7rsF29o27o0Gcc1Du+l7Zsv7SYtVPG0X3G/uUI1LqdxrQI7c9Hs2FWpqXXERjW9hp6g3/tH7DlVKg==", + "hasInstallScript": true, + "license": "MIT", + "dependencies": { + "bindings": "^1.5.0", + "prebuild-install": "^7.1.1" + }, + "engines": { + "node": "20.x || 22.x || 23.x || 24.x || 25.x" + } + }, "node_modules/big.js": { "version": "5.2.2", "resolved": "https://registry.npmjs.org/big.js/-/big.js-5.2.2.tgz", @@ -3775,47 +3675,6 @@ "node": ">= 0.8" } }, - "node_modules/cacache": { - "version": "15.3.0", - "resolved": "https://registry.npmjs.org/cacache/-/cacache-15.3.0.tgz", - "integrity": "sha512-VVdYzXEn+cnbXpFgWs5hTT7OScegHVmLhJIR8Ufqk3iFD6A6j5iSX1KuBTfNEv4tdJWE2PzA6IVFtcLC7fN9wQ==", - "optional": true, - "dependencies": { - "@npmcli/fs": "^1.0.0", - "@npmcli/move-file": "^1.0.1", - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "glob": "^7.1.4", - "infer-owner": "^1.0.4", - "lru-cache": "^6.0.0", - "minipass": "^3.1.1", - "minipass-collect": "^1.0.2", - "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.2", - "mkdirp": "^1.0.3", - "p-map": "^4.0.0", - "promise-inflight": "^1.0.1", - "rimraf": "^3.0.2", - "ssri": "^8.0.1", - "tar": "^6.0.2", - "unique-filename": "^1.1.1" - }, - "engines": { - "node": ">= 10" - } - }, - "node_modules/cacache/node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "optional": true, - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/call-bind-apply-helpers": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", @@ -3866,29 +3725,6 @@ ], "license": "CC-BY-4.0" }, - "node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, - "node_modules/chownr": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/chownr/-/chownr-2.0.0.tgz", - "integrity": "sha512-bIomtDF5KGpdogkLd9VspvFzk9KfpyyGlS8YFVZl7TGPBHL5snIOnxeshwVgPteQ9b4Eydl+pVbIyE1DcvCWgQ==", - "engines": { - "node": ">=10" - } - }, "node_modules/chrome-trace-event": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/chrome-trace-event/-/chrome-trace-event-1.0.3.tgz", @@ -3898,15 +3734,6 @@ "node": ">=6.0" } }, - "node_modules/clean-stack": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/clean-stack/-/clean-stack-2.2.0.tgz", - "integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==", - "optional": true, - "engines": { - "node": ">=6" - } - }, "node_modules/clone-deep": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz", @@ -3926,6 +3753,7 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "license": "MIT", "dependencies": { "color-name": "~1.1.4" }, @@ -3936,16 +3764,8 @@ "node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" - }, - "node_modules/color-support": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/color-support/-/color-support-1.1.3.tgz", - "integrity": "sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg==", - "optional": true, - "bin": { - "color-support": "bin.js" - } + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "license": "MIT" }, "node_modules/colorette": { "version": "2.0.20", @@ -3984,23 +3804,6 @@ "node": ">= 0.4.0" } }, - "node_modules/connect-sqlite3": { - "version": "0.9.16", - "resolved": "https://registry.npmjs.org/connect-sqlite3/-/connect-sqlite3-0.9.16.tgz", - "integrity": "sha512-2gqo0QmcBBL8p8+eqpBETn7RgM/PaoKvpQGl8PfjEgwlr0VuMYNMxRJRrRCo3KR3fxMYeSsCw2tGNG0JKN9Nvg==", - "dependencies": { - "sqlite3": "^5.0.2" - }, - "engines": { - "node": ">=0.4.x" - } - }, - "node_modules/console-control-strings": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz", - "integrity": "sha512-ty/fTekppD2fIwRvnZAVdeOiGd1c7YXEixbgJTNzqcxJWKQnjJ/V1bNEEE6hygpM3WjwHFUVK6HTjWSzV4a8sQ==", - "optional": true - }, "node_modules/content-disposition": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-1.0.1.tgz", @@ -4163,12 +3966,6 @@ "node": ">=4.0.0" } }, - "node_modules/delegates": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz", - "integrity": "sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ==", - "optional": true - }, "node_modules/depd": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", @@ -4234,12 +4031,6 @@ "dev": true, "license": "ISC" }, - "node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "optional": true - }, "node_modules/emojis-list": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/emojis-list/-/emojis-list-3.0.0.tgz", @@ -4258,27 +4049,6 @@ "node": ">= 0.8" } }, - "node_modules/encoding": { - "version": "0.1.13", - "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.13.tgz", - "integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==", - "optional": true, - "dependencies": { - "iconv-lite": "^0.6.2" - } - }, - "node_modules/encoding/node_modules/iconv-lite": { - "version": "0.6.3", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", - "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", - "optional": true, - "dependencies": { - "safer-buffer": ">= 2.1.2 < 3.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/end-of-stream": { "version": "1.4.5", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz", @@ -4347,15 +4117,6 @@ "node": ">=10.13.0" } }, - "node_modules/env-paths": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz", - "integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==", - "optional": true, - "engines": { - "node": ">=6" - } - }, "node_modules/envinfo": { "version": "7.21.0", "resolved": "https://registry.npmjs.org/envinfo/-/envinfo-7.21.0.tgz", @@ -4369,12 +4130,6 @@ "node": ">=4" } }, - "node_modules/err-code": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/err-code/-/err-code-2.0.3.tgz", - "integrity": "sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==", - "optional": true - }, "node_modules/es-define-property": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", @@ -4796,23 +4551,6 @@ "node": ">=14.14" } }, - "node_modules/fs-minipass": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", - "integrity": "sha512-V/JgOLFCS+R6Vcq0slCuaeWEdNC3ouDlJMNIsacH2VtALiu9mV4LPrHc5cDl8k5aw6J8jwgWWpiTo5RYhmIzvg==", - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/fs.realpath": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", - "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", - "optional": true - }, "node_modules/function-bind": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", @@ -4874,26 +4612,6 @@ "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==", "license": "MIT" }, - "node_modules/glob": { - "version": "7.2.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", - "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", - "optional": true, - "dependencies": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.1.1", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - }, - "engines": { - "node": "*" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/glob-to-regexp": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.4.1.tgz", @@ -4948,12 +4666,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/has-unicode": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz", - "integrity": "sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ==", - "optional": true - }, "node_modules/hasown": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.2.tgz", @@ -4966,12 +4678,6 @@ "node": ">= 0.4" } }, - "node_modules/http-cache-semantics": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz", - "integrity": "sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ==", - "optional": true - }, "node_modules/http-errors": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", @@ -5001,20 +4707,6 @@ "node": ">= 0.8" } }, - "node_modules/http-proxy-agent": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz", - "integrity": "sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==", - "optional": true, - "dependencies": { - "@tootallnate/once": "1", - "agent-base": "6", - "debug": "4" - }, - "engines": { - "node": ">= 6" - } - }, "node_modules/http2-express": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/http2-express/-/http2-express-1.1.0.tgz", @@ -5024,28 +4716,6 @@ "node": ">= 20.0.0" } }, - "node_modules/https-proxy-agent": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", - "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", - "optional": true, - "dependencies": { - "agent-base": "6", - "debug": "4" - }, - "engines": { - "node": ">= 6" - } - }, - "node_modules/humanize-ms": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/humanize-ms/-/humanize-ms-1.2.1.tgz", - "integrity": "sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ==", - "optional": true, - "dependencies": { - "ms": "^2.0.0" - } - }, "node_modules/i18next": { "version": "25.7.1", "resolved": "https://registry.npmjs.org/i18next/-/i18next-25.7.1.tgz", @@ -5144,40 +4814,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", - "optional": true, - "engines": { - "node": ">=0.8.19" - } - }, - "node_modules/indent-string": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", - "integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==", - "optional": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/infer-owner": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/infer-owner/-/infer-owner-1.0.4.tgz", - "integrity": "sha512-IClj+Xz94+d7irH5qRyfJonOdfTzuDaifE6ZPWfx0N0+/ATZCbuTPq2prFl526urkQd90WyUKIh1DfBQ2hMz9A==", - "optional": true - }, - "node_modules/inflight": { - "version": "1.0.6", - "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", - "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", - "optional": true, - "dependencies": { - "once": "^1.3.0", - "wrappy": "1" - } - }, "node_modules/inherits": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", @@ -5207,16 +4843,6 @@ "loose-envify": "^1.0.0" } }, - "node_modules/ip-address": { - "version": "10.1.0", - "resolved": "https://registry.npmjs.org/ip-address/-/ip-address-10.1.0.tgz", - "integrity": "sha512-XXADHxXmvT9+CRxhXg56LJovE+bmWnEWB78LB83VZTprKTmaC5QfruXocxzTZ2Kl0DNwKuBdlIhjL8LeY8Sf8Q==", - "license": "MIT", - "optional": true, - "engines": { - "node": ">= 12" - } - }, "node_modules/ipaddr.js": { "version": "1.9.1", "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", @@ -5249,21 +4875,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "optional": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/is-lambda": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/is-lambda/-/is-lambda-1.0.1.tgz", - "integrity": "sha512-z7CMFGNrENq5iFB9Bqo64Xk6Y9sg+epq1myIcdHaGnbMTYOxvzsEtdYqQUylB7LxfkvgrrjP32T6Ywciio9UIQ==", - "optional": true - }, "node_modules/is-plain-object": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", @@ -5287,7 +4898,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", - "devOptional": true + "dev": true }, "node_modules/isobject": { "version": "3.0.1", @@ -5485,33 +5096,6 @@ "node": ">=10" } }, - "node_modules/make-fetch-happen": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/make-fetch-happen/-/make-fetch-happen-9.1.0.tgz", - "integrity": "sha512-+zopwDy7DNknmwPQplem5lAZX/eCOzSvSNNcSKm5eVwTkOBzoktEfXsa9L23J/GIRhxRsaxzkPEhrJEpE2F4Gg==", - "optional": true, - "dependencies": { - "agentkeepalive": "^4.1.3", - "cacache": "^15.2.0", - "http-cache-semantics": "^4.1.0", - "http-proxy-agent": "^4.0.1", - "https-proxy-agent": "^5.0.0", - "is-lambda": "^1.0.1", - "lru-cache": "^6.0.0", - "minipass": "^3.1.3", - "minipass-collect": "^1.0.2", - "minipass-fetch": "^1.3.2", - "minipass-flush": "^1.0.5", - "minipass-pipeline": "^1.2.4", - "negotiator": "^0.6.2", - "promise-retry": "^2.0.1", - "socks-proxy-agent": "^6.0.0", - "ssri": "^8.0.0" - }, - "engines": { - "node": ">= 10" - } - }, "node_modules/math-intrinsics": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", @@ -5601,18 +5185,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/minimatch": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", - "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", - "optional": true, - "dependencies": { - "brace-expansion": "^1.1.7" - }, - "engines": { - "node": "*" - } - }, "node_modules/minimist": { "version": "1.2.8", "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", @@ -5622,94 +5194,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/minipass": { - "version": "3.3.4", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.3.4.tgz", - "integrity": "sha512-I9WPbWHCGu8W+6k1ZiGpPu0GkoKBeorkfKNuAFBNS1HNFJvke82sxvI5bzcCNpWPorkOO5QQ+zomzzwRxejXiw==", - "dependencies": { - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/minipass-collect": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/minipass-collect/-/minipass-collect-1.0.2.tgz", - "integrity": "sha512-6T6lH0H8OG9kITm/Jm6tdooIbogG9e0tLgpY6mphXSm/A9u8Nq1ryBG+Qspiub9LjWlBPsPS3tWQ/Botq4FdxA==", - "optional": true, - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/minipass-fetch": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/minipass-fetch/-/minipass-fetch-1.4.1.tgz", - "integrity": "sha512-CGH1eblLq26Y15+Azk7ey4xh0J/XfJfrCox5LDJiKqI2Q2iwOLOKrlmIaODiSQS8d18jalF6y2K2ePUm0CmShw==", - "optional": true, - "dependencies": { - "minipass": "^3.1.0", - "minipass-sized": "^1.0.3", - "minizlib": "^2.0.0" - }, - "engines": { - "node": ">=8" - }, - "optionalDependencies": { - "encoding": "^0.1.12" - } - }, - "node_modules/minipass-flush": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/minipass-flush/-/minipass-flush-1.0.5.tgz", - "integrity": "sha512-JmQSYYpPUqX5Jyn1mXaRwOda1uQ8HP5KAT/oDSLCzt1BYRhQU0/hDtsB1ufZfEEzMZ9aAVmsBw8+FWsIXlClWw==", - "optional": true, - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">= 8" - } - }, - "node_modules/minipass-pipeline": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/minipass-pipeline/-/minipass-pipeline-1.2.4.tgz", - "integrity": "sha512-xuIq7cIOt09RPRJ19gdi4b+RiNvDFYe5JH+ggNvBqGqpQXcru3PcRmOZuHBKWK1Txf9+cQ+HMVN4d6z46LZP7A==", - "optional": true, - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/minipass-sized": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/minipass-sized/-/minipass-sized-1.0.3.tgz", - "integrity": "sha512-MbkQQ2CTiBMlA2Dm/5cY+9SWFEN8pzzOXi6rlM5Xxq0Yqbda5ZQy9sU75a673FE9ZK0Zsbr6Y5iP6u9nktfg2g==", - "optional": true, - "dependencies": { - "minipass": "^3.0.0" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/minizlib": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/minizlib/-/minizlib-2.1.2.tgz", - "integrity": "sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg==", - "dependencies": { - "minipass": "^3.0.0", - "yallist": "^4.0.0" - }, - "engines": { - "node": ">= 8" - } - }, "node_modules/mkdirp": { "version": "2.1.6", "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-2.1.6.tgz", @@ -5808,36 +5292,6 @@ "node": ">=10" } }, - "node_modules/node-addon-api": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-7.1.1.tgz", - "integrity": "sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==", - "license": "MIT" - }, - "node_modules/node-gyp": { - "version": "8.4.1", - "resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-8.4.1.tgz", - "integrity": "sha512-olTJRgUtAb/hOXG0E93wZDs5YiJlgbXxTwQAFHyNlRsXQnYzUaF2aGgujZbw+hR8aF4ZG/rST57bWMWD16jr9w==", - "optional": true, - "dependencies": { - "env-paths": "^2.2.0", - "glob": "^7.1.4", - "graceful-fs": "^4.2.6", - "make-fetch-happen": "^9.1.0", - "nopt": "^5.0.0", - "npmlog": "^6.0.0", - "rimraf": "^3.0.2", - "semver": "^7.3.5", - "tar": "^6.1.2", - "which": "^2.0.2" - }, - "bin": { - "node-gyp": "bin/node-gyp.js" - }, - "engines": { - "node": ">= 10.12.0" - } - }, "node_modules/node-gyp-build": { "version": "4.5.0", "resolved": "https://registry.npmjs.org/node-gyp-build/-/node-gyp-build-4.5.0.tgz", @@ -5848,53 +5302,6 @@ "node-gyp-build-test": "build-test.js" } }, - "node_modules/node-gyp/node_modules/are-we-there-yet": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-3.0.1.tgz", - "integrity": "sha512-QZW4EDmGwlYur0Yyf/b2uGucHQMa8aFUP7eu9ddR73vvhFyt4V0Vl3QHPcTNJ8l6qYOBdxgXdnBXQrHilfRQBg==", - "optional": true, - "dependencies": { - "delegates": "^1.0.0", - "readable-stream": "^3.6.0" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16.0.0" - } - }, - "node_modules/node-gyp/node_modules/gauge": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/gauge/-/gauge-4.0.4.tgz", - "integrity": "sha512-f9m+BEN5jkg6a0fZjleidjN51VE1X+mPFQ2DJ0uv1V39oCLCbsGe6yjbBnp7eK7z/+GAon99a3nHuqbuuthyPg==", - "optional": true, - "dependencies": { - "aproba": "^1.0.3 || ^2.0.0", - "color-support": "^1.1.3", - "console-control-strings": "^1.1.0", - "has-unicode": "^2.0.1", - "signal-exit": "^3.0.7", - "string-width": "^4.2.3", - "strip-ansi": "^6.0.1", - "wide-align": "^1.1.5" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16.0.0" - } - }, - "node_modules/node-gyp/node_modules/npmlog": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/npmlog/-/npmlog-6.0.2.tgz", - "integrity": "sha512-/vBvz5Jfr9dT/aFWd0FIRf+T/Q2WBsLENygUaFUqstqsycmZAP/t5BvFJTK0viFmSUxiUKTUplWy5vt+rvKIxg==", - "optional": true, - "dependencies": { - "are-we-there-yet": "^3.0.0", - "console-control-strings": "^1.1.0", - "gauge": "^4.0.3", - "set-blocking": "^2.0.0" - }, - "engines": { - "node": "^12.13.0 || ^14.15.0 || >=16.0.0" - } - }, "node_modules/node-loader": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/node-loader/-/node-loader-2.1.0.tgz", @@ -5962,6 +5369,22 @@ "npm": "1.2.8000 || >= 1.4.16" } }, + "node_modules/node-media-server/node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, "node_modules/node-media-server/node_modules/content-disposition": { "version": "0.5.4", "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.4.tgz", @@ -6300,21 +5723,6 @@ "node": ">=0.4.0" } }, - "node_modules/nopt": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/nopt/-/nopt-5.0.0.tgz", - "integrity": "sha512-Tbj67rffqceeLpcRXrT7vKAN8CwfPeIBgM7E6iBkmKLV7bEMwpGgYLGv0jACUsECaa/vuxP0IjEont6umdMgtQ==", - "optional": true, - "dependencies": { - "abbrev": "1" - }, - "bin": { - "nopt": "bin/nopt.js" - }, - "engines": { - "node": ">=6" - } - }, "node_modules/object-assign": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", @@ -6390,21 +5798,6 @@ "node": ">=8" } }, - "node_modules/p-map": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-4.0.0.tgz", - "integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==", - "optional": true, - "dependencies": { - "aggregate-error": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/p-try": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", @@ -6476,15 +5869,6 @@ "node": ">=8" } }, - "node_modules/path-is-absolute": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", - "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", - "optional": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/path-key": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", @@ -6570,25 +5954,6 @@ "node": ">= 0.6" } }, - "node_modules/promise-inflight": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/promise-inflight/-/promise-inflight-1.0.1.tgz", - "integrity": "sha512-6zWPyEOFaQBJYcGMHBKTKJ3u6TBsnMFOIZSa6ce1e/ZrrsOlnHRHbabMjLiBYKp+n44X9eUI6VUPaukCXHuG4g==", - "optional": true - }, - "node_modules/promise-retry": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", - "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", - "optional": true, - "dependencies": { - "err-code": "^2.0.2", - "retry": "^0.12.0" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/proxy-addr": { "version": "2.0.7", "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", @@ -6867,30 +6232,6 @@ "node": ">=8" } }, - "node_modules/retry": { - "version": "0.12.0", - "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", - "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", - "optional": true, - "engines": { - "node": ">= 4" - } - }, - "node_modules/rimraf": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", - "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", - "optional": true, - "dependencies": { - "glob": "^7.1.3" - }, - "bin": { - "rimraf": "bin.js" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/router": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/router/-/router-2.2.0.tgz", @@ -7032,12 +6373,6 @@ "node": ">= 18" } }, - "node_modules/set-blocking": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", - "optional": true - }, "node_modules/setprototypeof": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", @@ -7149,12 +6484,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/signal-exit": { - "version": "3.0.7", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", - "optional": true - }, "node_modules/simple-concat": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", @@ -7200,16 +6529,6 @@ "simple-concat": "^1.0.0" } }, - "node_modules/smart-buffer": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/smart-buffer/-/smart-buffer-4.2.0.tgz", - "integrity": "sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==", - "optional": true, - "engines": { - "node": ">= 6.0.0", - "npm": ">= 3.0.0" - } - }, "node_modules/socket.io": { "version": "4.8.1", "resolved": "https://registry.npmjs.org/socket.io/-/socket.io-4.8.1.tgz", @@ -7301,35 +6620,6 @@ } } }, - "node_modules/socks": { - "version": "2.8.7", - "resolved": "https://registry.npmjs.org/socks/-/socks-2.8.7.tgz", - "integrity": "sha512-HLpt+uLy/pxB+bum/9DzAgiKS8CX1EvbWxI4zlmgGCExImLdiad2iCwXT5Z4c9c3Eq8rP2318mPW2c+QbtjK8A==", - "license": "MIT", - "optional": true, - "dependencies": { - "ip-address": "^10.0.1", - "smart-buffer": "^4.2.0" - }, - "engines": { - "node": ">= 10.0.0", - "npm": ">= 3.0.0" - } - }, - "node_modules/socks-proxy-agent": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/socks-proxy-agent/-/socks-proxy-agent-6.2.1.tgz", - "integrity": "sha512-a6KW9G+6B3nWZ1yB8G7pJwL3ggLy1uTzKAgCb7ttblwqdz9fMGJUuTy3uFzEP48FAs9FLILlmzDlE2JJhVQaXQ==", - "optional": true, - "dependencies": { - "agent-base": "^6.0.2", - "debug": "^4.3.3", - "socks": "^2.6.2" - }, - "engines": { - "node": ">= 10" - } - }, "node_modules/source-map": { "version": "0.6.1", "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", @@ -7351,42 +6641,6 @@ "source-map": "^0.6.0" } }, - "node_modules/sqlite3": { - "version": "5.1.7", - "resolved": "https://registry.npmjs.org/sqlite3/-/sqlite3-5.1.7.tgz", - "integrity": "sha512-GGIyOiFaG+TUra3JIfkI/zGP8yZYLPQ0pl1bH+ODjiX57sPhrLU5sQJn1y9bDKZUFYkX1crlrPfSYt0BKKdkog==", - "hasInstallScript": true, - "license": "BSD-3-Clause", - "dependencies": { - "bindings": "^1.5.0", - "node-addon-api": "^7.0.0", - "prebuild-install": "^7.1.1", - "tar": "^6.1.11" - }, - "optionalDependencies": { - "node-gyp": "8.x" - }, - "peerDependencies": { - "node-gyp": "8.x" - }, - "peerDependenciesMeta": { - "node-gyp": { - "optional": true - } - } - }, - "node_modules/ssri": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/ssri/-/ssri-8.0.1.tgz", - "integrity": "sha512-97qShzy1AiyxvPNIkLWoGua7xoQzzPjQ0HAH4B0rWKo7SZ6USuPcrUiAFrws0UH8RrbWmgq3LMTObhPIHbbBeQ==", - "optional": true, - "dependencies": { - "minipass": "^3.1.1" - }, - "engines": { - "node": ">= 8" - } - }, "node_modules/statuses": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.1.tgz", @@ -7430,32 +6684,6 @@ } ] }, - "node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "optional": true, - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "optional": true, - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/strip-json-comments": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", @@ -7469,6 +6697,7 @@ "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "license": "MIT", "dependencies": { "has-flag": "^4.0.0" }, @@ -7502,22 +6731,6 @@ "url": "https://opencollective.com/webpack" } }, - "node_modules/tar": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/tar/-/tar-6.2.1.tgz", - "integrity": "sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==", - "dependencies": { - "chownr": "^2.0.0", - "fs-minipass": "^2.0.0", - "minipass": "^5.0.0", - "minizlib": "^2.1.1", - "mkdirp": "^1.0.3", - "yallist": "^4.0.0" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/tar-fs": { "version": "2.1.4", "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.4.tgz", @@ -7552,25 +6765,6 @@ "node": ">=6" } }, - "node_modules/tar/node_modules/minipass": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-5.0.0.tgz", - "integrity": "sha512-3FnjYuehv9k6ovOEbyOswadCDPX1piCfhV8ncmYtHOjuPwylVWsghTLo7rabjC3Rx5xD4HDx8Wm1xnMF7S5qFQ==", - "engines": { - "node": ">=8" - } - }, - "node_modules/tar/node_modules/mkdirp": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", - "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", - "bin": { - "mkdirp": "bin/cmd.js" - }, - "engines": { - "node": ">=10" - } - }, "node_modules/terser": { "version": "5.44.1", "resolved": "https://registry.npmjs.org/terser/-/terser-5.44.1.tgz", @@ -7795,24 +6989,6 @@ "node": ">=4" } }, - "node_modules/unique-filename": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/unique-filename/-/unique-filename-1.1.1.tgz", - "integrity": "sha512-Vmp0jIp2ln35UTXuryvjzkjGdRyf9b2lTXuSYUiPmzRcl3FDtYqAwOnTJkAngD9SWhnoJzDbTKwaOrZ+STtxNQ==", - "optional": true, - "dependencies": { - "unique-slug": "^2.0.0" - } - }, - "node_modules/unique-slug": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/unique-slug/-/unique-slug-2.0.2.tgz", - "integrity": "sha512-zoWr9ObaxALD3DOPfjPSqxt4fnZiWblxHIgeWqW8x7UqDzEtHEQLzji2cuJYQFCU6KmoJikOYAZlrTHHebjx2w==", - "optional": true, - "dependencies": { - "imurmurhash": "^0.1.4" - } - }, "node_modules/universalify": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.0.tgz", @@ -8063,7 +7239,7 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", - "devOptional": true, + "dev": true, "dependencies": { "isexe": "^2.0.0" }, @@ -8074,15 +7250,6 @@ "node": ">= 8" } }, - "node_modules/wide-align": { - "version": "1.1.5", - "resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.5.tgz", - "integrity": "sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg==", - "optional": true, - "dependencies": { - "string-width": "^1.0.2 || 2 || 3 || 4" - } - }, "node_modules/wildcard": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/wildcard/-/wildcard-2.0.1.tgz", diff --git a/package.json b/package.json index 7ccf9a0..a0b2ca5 100644 --- a/package.json +++ b/package.json @@ -1,33 +1,25 @@ { "name": "infoscreen3", - "version": "1.7.0", + "version": "1.7.1", "private": true, "type": "module", "main": "./infoscreen3.js", "scripts": { - "compile": "pkg package.json --compress GZip", - "build": "webpack && node compile.js && pkg package.json --compress GZip", + "build:nexe": "node build-nexe.js", + "build:nexe:windows": "webpack && nexe ./webpack/bundle.cjs -t windows-x64-20.18.1 -o dist/win32-x64/infoscreen3.exe --build", + "build:nexe:linux": "webpack && nexe ./webpack/bundle.cjs -t linux-x64-20.18.1 -o dist/linux-x64/infoscreen3 --build", + "rebuild:node20": "node rebuild-native-node20.js", "start": "node --expose-gc ./infoscreen3.js", "daemon": "node --expose-gc ./daemon.js" }, - "bin": "./webpack/bundle.js", - "pkg": { - "scripts": [ - "./webpack/*.bundle.js" - ], - "targets": [ - "node18-windows-x64", - "node18-linux-x64" - ], - "outputPath": "dist" - }, + "bin": "./webpack/bundle.cjs", "dependencies": { "basic-auth": "^2.0.1", + "better-express-store": "^1.0.5", + "better-sqlite3": "^12.5.0", "bufferutil": "4.0.7", - "chalk": "4.1.2", "connect-busboy": "^1.0.0", "connect-ensure-login": "^0.1.1", - "connect-sqlite3": "^0.9.16", "cookie-parser": "^1.4.7", "cors": "^2.8.5", "daemon": "1.1.0", @@ -51,7 +43,6 @@ "rate-limiter-flexible": "2.4.1", "sanitize-filename": "^1.6.3", "socket.io": "^4.8.1", - "sqlite3": "^5.1.7", "twig": "^1.17.1", "utf-8-validate": "5.0.10", "xmlhttprequest-ssl": "^4.0.0" @@ -69,4 +60,4 @@ "webpack-cli": "^6.0.1", "webpack-node-externals": "^3.0.0" } -} \ No newline at end of file +} diff --git a/plugins/profiler/plugin.js b/plugins/profiler/plugin.js index b91c6d9..5e88460 100644 --- a/plugins/profiler/plugin.js +++ b/plugins/profiler/plugin.js @@ -1,29 +1,28 @@ -import plugin from "../../modules/plugin.js"; -import cli from "../../modules/cli.js"; -import chalk from 'chalk'; - -let prevValue = 0; -let startValue = (process.memoryUsage().rss / 1048576).toFixed(1); - -function tickHeapDump() { - setImmediate(function () { - let memMB = (process.memoryUsage().rss / 1048576).toFixed(1); - if (prevValue != memMB) { - let prefix = chalk.bold.red("โ–ฒ"); - if (memMB < prevValue) { - prefix = chalk.bold.green("โ–ผ"); - } - cli.info("Memory: " + prefix + " " + (memMB - prevValue).toFixed(1) + 'Mb' + " start: " + startValue + "Mb now: " + memMB + "Mb (" + (memMB - startValue).toFixed(1) + "Mb)"); - prevValue = memMB; - } - }); -} - -export default class profilerPlugin extends plugin { - onInit() { - tickHeapDump(); - setInterval(() => { - tickHeapDump(); - }, 5000); - } -} +import plugin from "../../modules/plugin.js"; +import cli from "../../modules/cli.js"; + +let prevValue = 0; +let startValue = (process.memoryUsage().rss / 1048576).toFixed(1); + +function tickHeapDump() { + setImmediate(function () { + let memMB = (process.memoryUsage().rss / 1048576).toFixed(1); + if (prevValue != memMB) { + let prefix = "โ–ฒ"; + if (memMB < prevValue) { + prefix = "โ–ผ"; + } + cli.info("Memory: " + prefix + " " + (memMB - prevValue).toFixed(1) + 'Mb' + " start: " + startValue + "Mb now: " + memMB + "Mb (" + (memMB - startValue).toFixed(1) + "Mb)"); + prevValue = memMB; + } + }); +} + +export default class profilerPlugin extends plugin { + onInit() { + tickHeapDump(); + setInterval(() => { + tickHeapDump(); + }, 5000); + } +} diff --git a/rebuild-native-node20.js b/rebuild-native-node20.js new file mode 100644 index 0000000..c49a2b3 --- /dev/null +++ b/rebuild-native-node20.js @@ -0,0 +1,75 @@ +import { execSync } from "child_process"; +import fs from "fs-extra"; + +console.log("๐Ÿ”ง Rebuilding native modules for Node.js 20.18.1 (ABI v115)...\n"); + +const nodeVersion = "20.18.1"; +const nodeAbi = "115"; +const arch = process.arch; // x64, arm64, etc. + +console.log(`Target: Node.js ${nodeVersion} (ABI ${nodeAbi})`); +console.log(`Architecture: ${arch}`); +console.log(`Platform: ${process.platform}\n`); + +try { + console.log("๐Ÿ“ฆ Rebuilding sqlite3..."); + execSync(`npm rebuild sqlite3 --build-from-source --target=${nodeVersion} --target_arch=${arch}`, { + stdio: "inherit", + env: { + ...process.env, + npm_config_target: nodeVersion, + npm_config_arch: arch, + npm_config_target_arch: arch, + npm_config_runtime: "node", + npm_config_disturl: "https://nodejs.org/dist" + } + }); + + console.log("\nโœ… Successfully rebuilt sqlite3"); +} catch (error) { + console.error("\nโŒ Failed to rebuild sqlite3:", error.message); + console.log("\n๐Ÿ’ก Trying alternative method with node-gyp directly..."); + + try { + process.chdir("./node_modules/sqlite3"); + execSync(`node-gyp rebuild --target=${nodeVersion} --arch=${arch}`, { + stdio: "inherit" + }); + process.chdir("../.."); + console.log("\nโœ… Successfully rebuilt sqlite3 using node-gyp"); + } catch (nodeGypError) { + console.error("\nโŒ node-gyp rebuild also failed:", nodeGypError.message); + console.log("\n๐Ÿ“ Manual steps to fix:"); + console.log("1. Install node-gyp globally: npm install -g node-gyp"); + console.log("2. Install Python and Visual Studio Build Tools (Windows)"); + console.log("3. Run: cd node_modules/sqlite3 && node-gyp rebuild --target=20.18.0"); + process.exit(1); + } +} + +// Verify the build +console.log("\n๐Ÿ” Verifying native binding..."); +const bindingPaths = [ + "./node_modules/sqlite3/build/Release/node_sqlite3.node", + "./node_modules/sqlite3/lib/binding/node-v115-win32-x64/node_sqlite3.node", + "./node_modules/sqlite3/lib/binding/node-v115-linux-x64/node_sqlite3.node" +]; + +let found = false; +for (const bindingPath of bindingPaths) { + if (fs.existsSync(bindingPath)) { + console.log(`โœ“ Found binding: ${bindingPath}`); + const stats = fs.statSync(bindingPath); + console.log(` Size: ${(stats.size / 1024).toFixed(2)} KB`); + console.log(` Modified: ${stats.mtime.toLocaleString()}`); + found = true; + } +} + +if (!found) { + console.error("\nโŒ Warning: No native binding found!"); + console.log("Expected locations:"); + bindingPaths.forEach(p => console.log(` - ${p}`)); +} else { + console.log("\n๐ŸŽ‰ Native modules are ready for Node.js 20.18.1!"); +} diff --git a/test-exe.js b/test-exe.js new file mode 100644 index 0000000..5982ca0 --- /dev/null +++ b/test-exe.js @@ -0,0 +1,23 @@ +const { spawn } = require('child_process'); +const path = require('path'); + +console.log('Starting infoscreen3...'); +console.log('CWD:', process.cwd()); +console.log('Executable path:', path.resolve('./infoscreen3.exe')); + +const child = spawn('./infoscreen3.exe', [], { + stdio: 'inherit', + shell: true +}); + +child.on('error', (error) => { + console.error('Failed to start:', error); +}); + +child.on('exit', (code, signal) => { + console.log(`Process exited with code ${code} and signal ${signal}`); +}); + +process.on('SIGINT', () => { + child.kill('SIGINT'); +}); diff --git a/webpack.config.cjs b/webpack.config.cjs index 3e18d6a..a226e07 100644 --- a/webpack.config.cjs +++ b/webpack.config.cjs @@ -1,57 +1,57 @@ -var path = require("path"); -var fs = require("fs"); - -var nodeModules = { }; -fs.readdirSync("./node_modules") - .filter(function (x) { - return [".bin"].indexOf(x) === -1; - }) - .forEach(function (mod) { - nodeModules[mod] = "commonjs " + mod; - }); - -if (fs.existsSync("./data/sessions.db")) { - fs.rmSync("./data/sessions.db"); -} - -module.exports = [ - { - name: "infoscreen3", - context: __dirname, - mode: 'production', - entry: "./infoscreen3.js", - target: "node", - output: { - path: __dirname + '/webpack', - filename: "bundle.js", - library: 'commonjs' - }, - externals: nodeModules, - module: { - noParse: [/socket.io-client/], - rules: [ - { - test: /\.js$/, - use: { - loader: 'babel-loader', - options: { - exclude: /node_modules/, - } - } - }, - { test: /\.node$/, use: { loader: "node-loader" } } - ] - }, - resolve: { - alias: { - 'socket.io-client': path.join(__dirname, 'node_modules', 'socket.io-client', 'socket.io.js') - }, - extensions: ["", ".js", ".node"] - }, - node: { - __dirname: true, - __filename: true - }, - profile: true - } +var path = require("path"); +var fs = require("fs"); + +var nodeModules = { }; +fs.readdirSync("./node_modules") + .filter(function (x) { + return [".bin"].indexOf(x) === -1; + }) + .forEach(function (mod) { + nodeModules[mod] = "commonjs " + mod; + }); + +if (fs.existsSync("./data/sessions.db")) { + fs.rmSync("./data/sessions.db"); +} + +module.exports = [ + { + name: "infoscreen3", + context: __dirname, + mode: 'production', + entry: "./infoscreen3.js", + target: "node", + output: { + path: __dirname + '/webpack', + filename: "bundle.cjs", + libraryTarget: 'commonjs2' + }, + externals: nodeModules, + module: { + noParse: [/socket.io-client/], + rules: [ + { + test: /\.js$/, + use: { + loader: 'babel-loader', + options: { + exclude: /node_modules/, + } + } + }, + { test: /\.node$/, use: { loader: "node-loader" } } + ] + }, + resolve: { + alias: { + 'socket.io-client': path.join(__dirname, 'node_modules', 'socket.io-client', 'socket.io.js') + }, + extensions: ["", ".js", ".node"] + }, + node: { + __dirname: true, + __filename: true + }, + profile: true + } ]; \ No newline at end of file