Repository navigation
Conversation
Probes (project files run from main's blob, credentials from the encrypted store into their environment, CLIs checked logged in, output capped, redacted and scrubbed), streams spooled by a collector wait keeps running, the scrubber, monitor test/show/discover/scrub, exception, log-error, platform-error, spike and deploy observations, probe rollups, the exception feed, and the monitor-failing, monitor-stale, probe-drift, probe-costly and monitor-discovery-due findings. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T5z3hZtpGaQUGsTaAMQrAg
Linear scrubber rules and a 16 KB cap per string; probes and collectors in their own process group, resolved on exit; collector liveness from its heartbeat, signal handling, spools removed only after the poll saved; spikes judged on the kit's own counts; fingerprints pruned; prototype-safe validation that never echoes event text; the worker credential rule on logWriter; wake-up lines without production text; nonce frames; atomic state; kind from monitor_defaults; probes run from a private copy; provider links in the observation drawer. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T5z3hZtpGaQUGsTaAMQrAg
Basic and Digest values shape-checked, Bearer always scrubbed; invalid lines redacted before they are cut; a long string cut at a space; emails up to 254 characters; a stale collector stopped before another starts, and one that was replaced stops itself; the collector waits for its probe's output and escalates to SIGKILL; non-object monitors and URL checks without a url are refused; probe status JSON is marked untrusted; probes are documented as one self-contained file. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T5z3hZtpGaQUGsTaAMQrAg
A stale stream.pid can name a reused pid, so wait checks the command line (and that the pid file is from this boot) before stopping it, and a collector removes its pid file on any exit. A replaced collector escalates like any other. Auth schemes match in any case and Digest's nonce and response are scrubbed. Probe stderr in a finding is cut and marked. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T5z3hZtpGaQUGsTaAMQrAg
isCollector compares the last three arguments, so errs2's collector isn't errs's, and a /proc read that fails falls back to ps. Digest's nonce, response, opaque and username are scrubbed inside a Digest header only, so a log's response="…" stays. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01T5z3hZtpGaQUGsTaAMQrAg
…s to turn on - monitorEntries uses #106's monitorProblems, name last; probe, stream, credentials, uses and params checked; no re-seed while unknown - a probe or stream's kind, file, credentials and uses, and any file under project/monitors/, are governance-edit (owner_only, never chat); thresholds and URL checks stay monitor-change - monitor test gives credentials only to main's probe under main's entry, for the supervisor too - the owner's monitor_scrub patterns run between the built-in rules, capped at 200 characters - discovered and event URLs shown without userinfo or query - the monitor probe runner is runMonitorProbe (main's runProbe is the link prober) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Member
Author
Upstream loop: merged #106's update, adversarial review of this PR's diffI merged Findings in this PR's diff
Needs the owner's decision
Tests: the full |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Builds on #106 (merge that first). Monitoring, part 2 of 5: the kit reads what production already shows, with the access the project already has, and turns it into observations.
What
kind: probe). A project file,project/monitors/<name>.mjs, that the supervisor writes per project and a reviewer reads. The kit runs main's committed blob, never a working tree, with:probe_timeout_s, 60) and output caps (2 MB, 5,000 events a run)DEVTEAM_PARAMS,DEVTEAM_SINCE(its last cursor) and each credential as an environment variable, read from the encrypted store with the secret sinks' grammar (rails-credentials:,sops:,file:)useschecked installed and logged in first (heroku auth:whoamiand friends), so a lapsed login fails the monitor instead of blinding itkind: stream), for sources with only a live tail (heroku logs --tail).waitkeeps a collector (monitor stream <name>) running alongside the supervisor and restarts it, at most three times in ten minutes; it stops itself 30 minutes afterwaitlast ran. Poll drains its spool. The rollup says how much of the day it listened.monitor_scrub(an owner setting,monitor-change);monitor scrub < linestries them. Classes, paths, line numbers, timestamps, versions, ids and shas stay.monitor:<name>:exception,log-errorandplatform-error: the first time a fingerprint qualifies for triage (the monitor'striagelevel, count and users). Fatal is 4, error is 3. Each carries the class, the scrubbed message, in-app frames mapped to repo paths, the release, counts, users and the provider link.spike: a fingerprint with a day of history running atspike.factortimes its 7-day hourly median, and at leastspike.min. Once per spell.deploy: each release, with its commit.run/monitors/<name>/): hourly counts (14 days), the latest event per fingerprint (cache_days), and metrics.waitalso returns once on a severity-4 event. Its poll budget is the slowest probe's timeout plus a minute.monitor test <name>runs this checkout's probe and settings once, validates every line, and prints a redacted sample framed as untrusted. A worker testing an edited probe gets no credentials.monitor show <fingerprint>shows the cached event, framed.monitor discover [--record]finds where the app runs, error trackers, CLIs and whether they can see the app, production URLs and health routes. It proposes what isn't watched and lists gaps.monitor stream.monitor scrub.monitor-failing: 3 runs in a row.monitor-stale: not polled in 3× its interval while the supervisor runs.probe-drift: invalid lines after a clean run.probe-costly: timed out, over the caps, over budget, or quota low.monitor-discovery-due: weekly.No new kit files, and no probes ship in the kit.
Why
The owner asked for production signals (errors, logs, deploys) to flow into the OODA loop with as much kept as possible, scrubbed of personal data. They also asked that the kit use access the project already has and ask only for gaps. Discovery is the step that finds that access.
Not in this PR
incident-fixand fix tickets come in PR 3.Tests
monitor testfrom the checkoutrun/--recordSuite: everything passes except the tmux session test, which fails on main in this environment too.
Generated by Claude Code