Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.
Go aialertsdashboarddockerdocker-monitoringgohomelabinfrastructure-monitoringkubernetesmonitoringmspproxmoxproxmox-backup-serverproxmox-mail-gatewayproxmox-veself-hostedtruenastypescriptvspherewebhooks
Test issue metadata on proposed source before publication
pulse-triage[bot]1740bccd6188
diff --git a/.github/workflows/build-and-test.yml b/.github/workflows/build-and-test.ymlindex 0e58a57457..95955a0c82 100644--- a/.github/workflows/build-and-test.yml+++ b/.github/workflows/build-and-test.yml@@ -74,6 +74,7 @@ jobs:code: ${{ steps.filter.outputs.code }}frontend_deps: ${{ steps.filter.outputs.frontend_deps }}go_compile: ${{ steps.filter.outputs.go_compile }}+ triage_helper: ${{ steps.filter.outputs.triage_helper }}steps:- name: Checkout repositoryuses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1@@ -103,6 +104,7 @@ jobs:echo "code=true" >> "$GITHUB_OUTPUT"echo "frontend_deps=true" >> "$GITHUB_OUTPUT"echo "go_compile=true" >> "$GITHUB_OUTPUT"+ echo "triage_helper=true" >> "$GITHUB_OUTPUT"exit 0fi# Receipts change evidence, not the application. Keep the per-push@@ -114,10 +116,20 @@ jobs:echo "code=false" >> "$GITHUB_OUTPUT"echo "frontend_deps=false" >> "$GITHUB_OUTPUT"echo "go_compile=false" >> "$GITHUB_OUTPUT"+ echo "triage_helper=false" >> "$GITHUB_OUTPUT"exit 0fichanged=$(git diff --name-only "$base" "${{ github.sha }}")printf 'Changed files:\n%s\n' "$changed"+ # The issue-event job tests before minting its App token, but that+ # happens after publication. Test its parser and silent-mutation+ # policy on the proposed source too, including documentation-only+ # guidance and every workflow consumed by the policy tests.+ triage_helper=false+ if printf '%s\n' "$changed" | grep -E '^\.github/scripts/(issue-version-triage(\.test)?\.cjs|triage-comment-policy\.test\.cjs|package(-lock)?\.json)$|^\.github/ISSUE_TEMPLATE/|^\.github/workflows/|^docs/ISSUE_TRIAGE\.md$|^scripts/tests/test_ci_browser_proof_only\.py$' >/dev/null; then+ triage_helper=true+ fi+ echo "triage_helper=$triage_helper" >> "$GITHUB_OUTPUT"# Note: -q must not be combined with -v here — BSD grep exits 1 for# that combination even when inverted matches exist.if printf '%s\n' "$changed" | grep -vE '^docs/|\.md$' >/dev/null; then@@ -151,6 +163,32 @@ jobs:fiecho "frontend_deps=$frontend_deps" >> "$GITHUB_OUTPUT"+ triage-helper:+ name: Issue metadata and silent triage policy+ needs: changes+ if: needs.changes.outputs.triage_helper == 'true'+ runs-on: ubuntu-24.04+ timeout-minutes: 5+ permissions:+ contents: read+ steps:+ - name: Check out proposed triage source+ uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1+ with:+ persist-credentials: false++ - name: Set up Node.js+ uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0+ with:+ node-version: '24'+ package-manager-cache: false++ - name: Install locked parser without lifecycle scripts+ run: npm ci --ignore-scripts --no-audit --no-fund --prefix .github/scripts++ - name: Test proposed issue metadata and silent policy+ run: npm run test:triage --prefix .github/scripts+provider-pair-docker:name: Provider pair Docker acceptanceneeds: changesdiff --git a/docs/release-control/v6/internal/subsystems/deployment-installability.md b/docs/release-control/v6/internal/subsystems/deployment-installability.mdindex c59dedcfed..7c4c4cb2b9 100644--- a/docs/release-control/v6/internal/subsystems/deployment-installability.md+++ b/docs/release-control/v6/internal/subsystems/deployment-installability.md@@ -16,6 +16,28 @@## Purpose+### Issue metadata checks before publication (14 October 2026)++Build and Test runs the locked issue parser and silent-triage policy tests on+proposed source, not only after publication when an issue event obtains its+write credential. Parser/test/manifest changes, issue templates, triage guidance+and every workflow read by the policy tests admit the check. Missing bases admit+it too; complete receipt-only ranges and unrelated inputs do not. Guidance-only+changes still run it even when application runtime checks are inapplicable.+Mixed source or dependency ranges retain every existing runtime/audit check.++The bounded hosted job uses Node 24, read-only repository permission, checkout+without persisted credentials, no dependency cache and a locked install without+lifecycle scripts. Both install and test failures propagate; no App token,+issue mutation, tolerant exit or production operation belongs to this job.+The separate issue-event pre-token test remains mandatory and unchanged.++`TestCIIssueMetadataUsesSourceOnlyTriageChecks` executes the actual workflow's+classification and recipes through `test_ci_browser_proof_only.py`, including+real Git whole-range/lookalike controls and install/test failure exits. Actual+locked parser tests remain independently required. These source controls do not+establish a hosted pass, live issue classification or reporter resolution.+### Unraid/QNAP removal retires exact boot entries and confirms watchdog quiescenceThe Unix uninstall caller selects these platforms from their vendor/installeddiff --git a/scripts/installtests/build_release_assets_test.go b/scripts/installtests/build_release_assets_test.goindex ce1647cc83..fab15d342b 100644--- a/scripts/installtests/build_release_assets_test.go+++ b/scripts/installtests/build_release_assets_test.go@@ -4338,6 +4338,19 @@ func TestFrontendCIRequiresSameCheckoutRealEmbedBackend(t *testing.T) {}}+// The issue-event check runs after publication. Its real parser tests and+// silent-mutation policy also need credential-free PR/main admission, without+// relaxing product runtime, dependency audit or receipt-only boundaries.+func TestCIIssueMetadataUsesSourceOnlyTriageChecks(t *testing.T) {+ ctx, cancel := context.WithTimeout(context.Background(), 60*time.Second)+ defer cancel()+ cmd := exec.CommandContext(ctx, "python3", repoFile("scripts", "tests", "test_ci_browser_proof_only.py"), "-v")+ out, err := cmd.CombinedOutput()+ if err != nil {+ t.Fatalf("issue metadata CI admission and failure controls: %v\n%s", err, out)+ }+}+// The post-build root transaction receives only an exact-source identity and// synthetic binaries; native failure cannot hide or skip the existing audit.func TestFrontendCINativeUpdaterKeepsSecretFreeRequiredVerification(t *testing.T) {diff --git a/scripts/tests/test_ci_browser_proof_only.py b/scripts/tests/test_ci_browser_proof_only.pyindex 15dc8e812d..6aa8448a93 100644--- a/scripts/tests/test_ci_browser_proof_only.py+++ b/scripts/tests/test_ci_browser_proof_only.py@@ -173,23 +173,133 @@ class GitTreeScopeTest(unittest.TestCase):proof = self.commit()self.assertEqual(self.classify(self.base, proof), {"code": "false", "frontend_deps": "false", "go_compile": "false",+ "triage_helper": "false",})self.write("frontend-modern/package-lock.json", "{}\n")graph = self.commit()self.assertEqual(self.classify(self.base, graph), {"code": "true", "frontend_deps": "true", "go_compile": "false",+ "triage_helper": "false",})self.assertEqual(self.classify("0" * 40, graph), {"code": "true", "frontend_deps": "true", "go_compile": "true",+ "triage_helper": "true",})self.write("internal/api/fixture.go", "package fixture\nvar Updated = true\n")source = self.commit()self.assertEqual(self.classify(graph, source), {"code": "true", "frontend_deps": "false", "go_compile": "true",+ "triage_helper": "false",})+ def test_actual_classifier_selects_every_triage_input_and_policy_consumer(self):+ for path in (+ ".github/scripts/issue-version-triage.cjs",+ ".github/scripts/issue-version-triage.test.cjs",+ ".github/scripts/triage-comment-policy.test.cjs",+ ".github/scripts/package.json", ".github/scripts/package-lock.json",+ ".github/ISSUE_TEMPLATE/bug_report.yml", ".github/ISSUE_TEMPLATE/config.yml",+ ".github/workflows/issue-version-label-sync.yml",+ ".github/workflows/build-and-test.yml", ".github/workflows/policy-consumer.yaml",+ "docs/ISSUE_TRIAGE.md", "scripts/tests/test_ci_browser_proof_only.py",+ ):+ with self.subTest(path=path):+ before = self.git("rev-parse", "HEAD")+ self.write(path, "triage input fixture\n")+ head = self.commit()+ self.assertEqual(self.classify(before, head)["triage_helper"], "true")++ def test_triage_admission_uses_complete_range_and_does_not_expand_runtime_skip(self):+ self.write("docs/ISSUE_TRIAGE.md", "Changed operator guidance\n")+ guidance = self.commit()+ self.assertEqual(self.classify(self.base, guidance), {+ "code": "false", "frontend_deps": "false", "go_compile": "false",+ "triage_helper": "true",+ })+ self.write(RECEIPT, "{}\n")+ proof = self.commit()+ self.assertEqual(self.classify(guidance, proof)["triage_helper"], "false")+ self.assertEqual(self.classify(self.base, proof)["triage_helper"], "true")+ self.write(".github/scripts/issue-version-triage.cjs", "// changed parser\n")+ parser = self.commit()+ self.assertEqual(self.classify(proof, parser), {+ "code": "true", "frontend_deps": "false", "go_compile": "false",+ "triage_helper": "true",+ })+ self.write("frontend-modern/package-lock.json", "{}\n")+ graph = self.commit()+ combined = self.classify(proof, graph)+ self.assertEqual(combined["frontend_deps"], "true")+ self.assertEqual(combined["code"], "true")+ self.assertEqual(combined["triage_helper"], "true")++ def test_triage_path_lookalikes_and_unrelated_code_do_not_select_it(self):+ for path in (+ ".github/scripts/issue-version-triage.cjs.extra",+ "other/.github/scripts/package-lock.json", "docs/ISSUE_TRIAGE.md.extra",+ ".github/scripts/select-go-package-shard.py", "internal/api/other.go",+ ".github/scripts/issue-version-triage.cjs\nother.txt",+ ):+ with self.subTest(path=path):+ before = self.git("rev-parse", "HEAD")+ self.write(path, "unrelated fixture\n")+ head = self.commit()+ self.assertEqual(self.classify(before, head)["triage_helper"], "false")+class WorkflowScopeTest(unittest.TestCase):+ def test_triage_check_runs_locked_real_tests_without_mutation_or_tolerant_exit(self):+ workflow = BUILD.read_text()+ self.assertIn("triage_helper: ${{ steps.filter.outputs.triage_helper }}",+ job_block(workflow, "changes"))+ job = job_block(workflow, "triage-helper")+ for required in (+ "needs: changes", "if: needs.changes.outputs.triage_helper == 'true'",+ "runs-on: ubuntu-24.04", "timeout-minutes: 5", "contents: read",+ "actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1",+ "persist-credentials: false",+ "actions/setup-node@820762786026740c76f36085b0efc47a31fe5020",+ "node-version: '24'", "package-manager-cache: false",+ "npm ci --ignore-scripts --no-audit --no-fund --prefix .github/scripts",+ "npm run test:triage --prefix .github/scripts",+ ):+ self.assertIn(required, job)+ for forbidden in ("secrets.", "write", "create-github-app-token", "github-script@",+ "continue-on-error", "|| true", "issue-version-triage.cjs",+ "workflow_call", "self-hosted"):+ self.assertNotIn(forbidden, job)+ self.assertLess(job.index("npm ci "), job.index("npm run test:triage"))+ # Hosted test admission adds coverage; it never replaces the separate+ # issue-event tests that must still precede credential acquisition.+ live = (ROOT / ".github/workflows/issue-version-label-sync.yml").read_text()+ self.assertLess(live.index("npm run test:triage"), live.index("Mint triage bot token"))++ def test_actual_triage_recipes_preserve_install_and_test_failures(self):+ job = job_block(BUILD.read_text(), "triage-helper")+ recipes = [part.split(" run: ", 1)[1].strip()+ for part in re.split(r"(?m)^ - name: ", job)[1:]+ if " run: " in part]+ self.assertEqual(len(recipes), 2)+ with tempfile.TemporaryDirectory() as temporary:+ root = Path(temporary)+ npm = root / "npm"+ npm.write_text('#!/bin/sh\nprintf "%s\\n" "$*" > "$CALLS"\nexit "$RESULT"\n')+ npm.chmod(0o700)+ calls = root / "calls"+ env = {**os.environ, "PATH": str(root) + ":" + os.environ["PATH"],+ "CALLS": str(calls)}+ for recipe, expected in zip(recipes, (+ "ci --ignore-scripts --no-audit --no-fund --prefix .github/scripts",+ "run test:triage --prefix .github/scripts",+ )):+ for status in (0, 42, 127):+ with self.subTest(recipe=recipe, exit=status):+ result = subprocess.run(["bash", "-c", recipe], cwd=root,+ capture_output=True, text=True, timeout=5,+ env={**env, "RESULT": str(status)})+ self.assertEqual(result.returncode, status, result.stdout + result.stderr)+ self.assertEqual(calls.read_text().strip(), expected)+def test_scope_is_checked_before_runtime_and_preserves_required_governance(self):e2e = E2E.read_text()scope = job_block(e2e, "scope")