Repository navigation
Triage run: turn a Report into triaged issues - #1715
Merged
Merged
Conversation
Add recommendation-only Triage runs for Reports
File triaged issues by default
A read-only mount still lets the session connect to a host service, which can then write outside the worktree. The sandbox now loads a seccomp filter that returns EAFNOSUPPORT for AF_UNIX and io_uring_setup, on both the startup probe and the session. TCP stays available.
Combine factory-owned Triage filing and readiness with opt-in machine reads through the read-only sandbox. Regenerate prompt documentation and the user manual, and exercise sandboxed filing in the real Bubblewrap regression.
Write questionnaires for Triage issues that need a person
Preserve opt-in read-only machine access alongside forwardable Triage questionnaires. Keep questionnaire publication and notification in the shared investigation path, regenerate the manual and prompt site, and cover sandboxed filing with a questionnaire in the real Bubblewrap regression. Validation so far: cargo check --all-targets, cargo fmt --check, 13 prompt-generation tests, 17 Triage tests, 2 retained-home regressions and all 61 site checks pass. The required scripts/affected-tests origin/issue-1323 run is continuing through the full Rust suite.
Let Triage read the machine through an opt-in read-only sandbox
Preserve existing-issue comments from #1709 alongside the forwardable questionnaires from #1710. Regenerate the manual and prompt reference from their merged sources, and cover comments alongside mixed questionnaire outcomes. Validation: cargo check --locked, cargo fmt --check, prompt generation/verification, 61 site checks, 18 Triage integration tests, 47 notification tests and 16 skill tests passed. The unit suite passed 1619 tests in 268.69s with three unchanged stalled Harness/session fixtures excluded. The required affected-tests run passed its site checks but was stopped at those three fixtures without an assertion failure.
Preserve comments on covering issues alongside opt-in machine-reading confinement and forwardable questionnaires. Regenerate the manual and prompt reference from their merged sources, and extend the real Bubblewrap regression to verify comment publication, unchanged labels and notification links. Validation: cargo check --all-targets, cargo fmt --check, 13 prompt-generation tests, 21 Triage integration tests and 2 retained-home tests passed. The required affected-tests run follows this commit.
Comment on open issues covering a Triage Report
…ed for possible cybersecurity risk. If this seems wrong, try rephrasing your request. If you’re doing authorized security work that requires more cyber permissive safeguards, apply for Daybreak access via https://platform.openai.com/settings/organization/status-and-access before retrying.) 2026-11-04T04:32:10Z, host stephens. Uncommitted work at the time of failure is included in this commit.
--recommend-only now makes filing's GitHub checks, so it fails wherever filing would: a closed or foreign comment target, or a category that is not a repository label or is a factory label. Filing closes a wontfix issue, as the Day shift's triage does. The User config's triage.read_machine names repositories whose Triage runs read the whole machine, as --read-machine does. The host-socket seccomp filter refuses x32 syscall numbers, which share x86_64's arch value and slipped past its exact matches. The read-machine launch is tested at the sandbox seam, with bwrap, the Harness program and the user's home passed in. The private home's XDG layout is one table the sandbox and the OpenCode and Muse readers share, and the seccomp memfd closes by ownership. A Report is its own type, the run's flags one Options struct, and each proposed issue's state is resolved once.
The guide's Triage section moves beside the other workflows, and the architecture page gives it a section of its own instead of opening The Passes. The glossary's Activity log and Run notification entries, README's Workflows table and docs/code-navigation.md name it. The pages, ADR 0013 and the thirdshift-triage skill describe triage.read_machine, closing wontfix issues and the checks --recommend-only makes.
JacobStephens2
marked this pull request as ready for review
November 4, 2026 06:28
Merged
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.
thirdshift triageturns a Report (an email, chat message, call transcript or machine alert) into triaged issues with nobody in the loop. It reads the Report from standard input or--file, investigates it read-only in a throwaway worktree, and files shaped issues with one category and one state label each, or with--recommend-onlyreports what it would file and writes nothing to GitHub. This PR gathers the five Tickets of Spec #1323 (#1707 to #1711) and the fixes from its Spec review.Closes #1323
Summary
thirdshift, not the session, applies every label.
ready-for-agentbecomesneeds-triagewith a note unless--allow-ready-for-agentortriage.allow_ready_for_agent = trueallows it, and a problem that needs credentials or production access to confirm isready-for-humanwith the reason.What the Spec review changed:
Seams under test:
thirdshift triage, the real binary, against the fakeghand a fake Harness session:tests/triage_run.rs,tests/issue_1711_retained_home.rssandbox::triage: the read-machine launch throughprepare_around, and the host-socket filter in a child test process:src/sandbox/triage.rsUserConfig::parsefortriage.read_machine:src/config.rsEvidence
Before:
mainhas no Triage run. On 9c73bb8, the review's tests failed as its findings said:host_socket_filter_refuses_x32_socket_calls:x32 socket(AF_UNIX) passed the filter: fd -1, errno Some(38)recommend_only_and_filing_agree_on_what_can_be_published:filing succeeded=false but --recommend-only succeeded=truefor a closed comment targeta_wontfix_recommendation_does_not_leave_an_open_issue:a Triage run left wontfix issue #8 openAfter: on 34b00d1 all three pass, as do the new
reading_the_whole_machine_follows_the_flag_or_a_per_repository_user_config_setting,the_read_machine_launch_reads_the_host_and_writes_only_its_worktreeandtriage_read_machine_opts_in_named_repositories_whatever_their_case.scripts/affected-tests mainpassed:npm test --prefix sitein 65.95s, andcargo testin 2029.96s with compilation (3,668 passed, 0 failed, 77 ignored across 85 targets).cargo clippy --all-targets -- -D warnings,cargo fmt --check,cargo test --bin thirdshift prompts_pageandnpm run docs:check --prefix sitepass. CI passed on 9c73bb8, before the review fixes.Merge Danger
Door: two-way, with one catch.
Reverting removes the Command, but a User config that sets
[triage]would then fail to parse, since unknown keys are errors. A revert after someone adoptsallow_ready_for_agentorread_machinebreaks their config until they delete the section. Issues a Triage run filed stay filed; closing them undoes them.Blast Radius: small.
Shared code that changed:
GitHub::ensure_labelslists labels through the newrepository_labels;labels::UNREADYnames its labels by constant;Launchgained a seccomp program that only the Triage launch sets;write_seccomp_fdcloses its memfd throughOwnedFd; the Muse and OpenCode completion readers can read a private home;thirdshift helplost one blank line to stay compact with the Triage line. The--read-machinesandbox needsbwrapand Linux user namespaces, and fails the Command rather than running unsandboxed.Review coverage
The Standards and Spec reviewers each read all 50 files changed at 9c73bb8, with no generated-output exclusions. The fixes also change
src/harness.rsandREADME.md, which no reviewer read. The reviews raised 13 Standards findings and 8 Spec findings.Unaddressed findings
Standards
src/sandbox.rs:836-838); the Triage launch copies the ordinary login into a writable private home (src/sandbox/triage.rs:135). A failed Trial probe becomesUnavailable(src/sandbox.rs:518-527) and voids the Trial assandbox_unavailable(src/trial.rs:317-318), while ADR 0013's Let a Triage run read the whole machine in a read-only sandbox #1711 exception makes a failed Triage probe fail the Command (src/sandbox/triage.rs:92-97). A shared table and probe would need a mode for each.quoted_reportrepeatsprompts_page::fence.prompts_pagecompiles only for tests (src/main.rs:83-85), so production code can't call itsfence, and the third copy counts line-leading backticks, a different rule (src/github/advisories/description.rs:93-100).publishkeeps itspublishedout-parameter. A failure partway still has to name the writes that landed, whichrunadds to the failure (src/triage.rs:440-454); returning them would take an error type that carries them. TheReporttype and theOptionsstruct from this finding are in.src/triage.rs. Each factory label is defined by its owner, and each owner importscrate::labels(src/claim.rs:31,37,src/base_fix.rs:27,src/security/fixing.rs:22,src/architect.rs:65,src/github/advisories.rs:24), so alabels::is_factory_ownedwould makelabelsimport its own importers. The comma check stays incheck_publication, so--recommend-onlyrefuses a comma too (Spec finding 4).Account. Every arm ofrun_ending::readnames all 18 fields, a pattern older than this Spec (the Scoring arm,src/run_ending.rs:36-58), so a new field is a compile error in each arm rather than a silent default. Changing that is its own refactor.FailedRuncarries only the error:runattaches it asTriage analysis retained(src/triage.rs:421), whichnotification::bodynever sees.for_triagerepeatsat_commit.at_commitrecovers a worktree left at its fixed path and prints a progress step (src/worktree.rs:496-500), which a uniquely named Triage checkout never needs, leaving only the lock andacquisition::addin common. Thewrite_seccomp_fdhalf is fixed.Spec
ready-for-agentitself. The review's test fails as written on 9c73bb8:ready-for-agent kept without permission on #8: ["bug", "ready-for-agent"]; exit Some(0). Neither the Spec's model, where the session files and reports, nor this branch's, where thirdshift files, catches a session that writes to GitHub without reporting it. Closing the gap means amending the Spec or ADR 0013's trust in the session, which is the Day shift's call: Triage run: a session can label its own issue ready-for-agent with the user's gh login #1725.Source: standard inputorSource: file: <path>(src/triage.rs:62). Who reported it travels in the Report itself; a--sourceflag would be new surface the Spec doesn't name.Security review outcome
No unaddressed introduced findings.
Tickets
thirdshift triage --recommend-only#1707 doneBuilt with claude 2.1.316 · claude-opus-5-5 · max