Compare commits

...

3 Commits

Author SHA1 Message Date
Osman Karagöz
6dfa574e36 Fix: monitor(tailscale): Check exit code before failing on stderr output (#6309) 2025-11-04 18:20:39 +01:00
Louis Lam
08d77e6fce Fix build issue on Node.js 25 (#6295) 2025-11-04 06:55:00 +08:00
Dorian Grasset
5207ba6d97 fix: child monitors disappear after group deletion (#6287)
Co-authored-by: Louis Lam <louislam@users.noreply.github.com>
2025-11-03 21:21:36 +01:00
6 changed files with 30 additions and 1358 deletions

View File

@@ -22,8 +22,12 @@ jobs:
strategy:
matrix:
os: [macos-latest, ubuntu-22.04, windows-latest, ARM64]
node: [ 20, 24 ]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
node: [ 20, 24 ]
# Also test non-LTS, but only on Ubuntu.
include:
- os: ubuntu-22.04
node: 25
steps:
- run: git config --global core.autocrlf false # Mainly for Windows

View File

@@ -2,7 +2,6 @@ import vue from "@vitejs/plugin-vue";
import { defineConfig } from "vite";
import visualizer from "rollup-plugin-visualizer";
import viteCompression from "vite-plugin-compression";
import VueDevTools from "vite-plugin-vue-devtools";
const postCssScss = require("postcss-scss");
const postcssRTLCSS = require("postcss-rtlcss");
@@ -31,7 +30,6 @@ export default defineConfig({
algorithm: "brotliCompress",
filter: viteCompressionFilter,
}),
VueDevTools(),
],
css: {
postcss: {

1356
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -199,7 +199,6 @@
"v-pagination-3": "~0.1.7",
"vite": "~5.4.15",
"vite-plugin-compression": "^0.5.1",
"vite-plugin-vue-devtools": "^7.0.15",
"vue": "~3.4.2",
"vue-chartjs": "~5.2.0",
"vue-confirm-dialog": "~1.0.2",

View File

@@ -31,7 +31,7 @@ class TailscalePing extends MonitorType {
timeout: timeout,
encoding: "utf8",
});
if (res.stderr && res.stderr.toString()) {
if (res.stderr && res.stderr.toString() && res.code !== 0) {
throw new Error(`Error in output: ${res.stderr.toString()}`);
}
if (res.stdout && res.stdout.toString()) {

View File

@@ -1060,6 +1060,27 @@ let needSetup = false;
const startTime = Date.now();
// Check if this is a group monitor and unlink children before deletion
const monitor = await R.findOne("monitor", " id = ? AND user_id = ? ", [
monitorID,
socket.userID,
]);
if (monitor && monitor.type === "group") {
// Get all children before unlinking them
const children = await Monitor.getChildren(monitorID);
// Unlink all children from the group
await Monitor.unlinkAllChildren(monitorID);
// Notify frontend to update each child monitor's parent to null
if (children && children.length > 0) {
for (const child of children) {
await server.sendUpdateMonitorIntoList(socket, child.id);
}
}
}
await R.exec("DELETE FROM monitor WHERE id = ? AND user_id = ? ", [
monitorID,
socket.userID,