mirror of
https://github.com/norandom/OpenUltraSAST.git
synced 2026-12-03 02:08:18 +00:00
e3f2f608d563b28dbf6fe5717ae8acbfc1bf7adc
1364
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
e3f2f608d5 |
spec(dspy-driver): the driver gets its own spec, measured by example
The open work of hunter-learning-loop (4.1, 6 and the group 7 of the same day) moves to dspy-driver as D1 to D10. The brief maps the driving in seven stages and orders the experiments E0 to E6. The abstract interpretation is wired in before anything is measured: the prover's trace and Joern's results are not inputs of the driver today. HarnessX is gone from the tree, and the four plane modules the ledger suspected are still imported. Co-Authored-By: Claude Fable 5.2 <[email protected]> |
||
|
|
1a9865496b |
spec: nine specs superseded, their needed tasks carried to the three lines
hunter-learning-loop gets group 7 (the driver on the trace), search-with-proof group 7 (proof on the driver's suspects, shown to the developer), pre-push-safety-net task 18, and engine-change-scoped-analysis the carried engine work. Superseded specs keep their directory with a notice. The breadth ledger follows. Co-Authored-By: Claude Fable 5.2 <[email protected]> |
||
|
|
0c5e06bb14 |
docs(steering): the roadmap returns to bug finding: the driver, then proof
The maintainer's decision of 2026-11-30 after the project review. Three lines of work: the driver finds the bugs, proof shows them, the developer sees them. The ladder of 2026-11-20 is superseded and kept as history. The benchmark and the core contract are frozen as built. Admission populations never train; the training pool teaches, and the driver may be compiled on it. Co-Authored-By: Claude Fable 5.2 <[email protected]> |
||
|
|
7ecd60ec4e |
ci(release): the retention prunes image versions too
The maintainer's request, on 2026-11-29: "packages haven't beeen updated in github. do we delete them?". The two image packages were updated (2.2.0-alpha.1, three hours before); what is old is the tag latest, which release.yml gives only to a release tag without a hyphen. Asked by menu what to do with the image versions, the maintainer chose "Prune image versions (Recommended)": keep the versions of the kept release tags, keep main with its sha tags, delete the other sha-tagged and the untagged versions of openultrasast and openultrasast-runner; the first run only lists, and the deletion waits for the maintainer's word. What changed .github/workflows/release-retention.yml, 150 to 262 lines (the python of the step: 105 to 215). The rule for tags and releases is as before. For image versions, after the versions that go with a deleted release tag: a version that carries no tag of a kept release and not main is pruned when it is untagged or tagged with a sha only. Two safeguards, found while the rule was written and in its review. First, an untagged version can be the image manifest or the attestation manifest of an image that stays: the four release images read on 2026-11-29 are OCI indexes with an amd64 manifest and an attestation manifest (s10_pkg_indexes.out), and the packages hold more untagged versions than tagged ones. So the step logs in to the registry, reads the index of each image that stays once, whatever tag keeps it, with docker buildx imagetools inspect, and keeps every version whose digest is one of the manifests that index lists. The index is read one level deep: an index inside it is not followed, and build-push-action makes none. Second, that fails closed: an index none of whose manifests is a version of the package, an index entry without a digest, or output that is not an index stops the job before anything is pruned or deleted. A version with a tag the rule does not name, or untagged without a digest, stays and is listed. The limit for image versions is 100 in one run (the limit of 20 stays for tags and releases). The summary lists every version to prune with the start of its digest and its tags before anything is deleted. A failed docker call stops the job and names the call and the reason, as a failed gh call does. Checks The harness /tmp/opencode/s10_rr2_harness.py runs the python of the step on fixtures with stand-ins for git, gh and docker (/tmp/opencode/s10_rr2_bin), ten cases. Against the workflow at HEAD ( |
||
|
|
d98334a44b |
chore(release): the citation names the concept DOI
CITATION.cff named 10.5281/zenodo.24012765, which Zenodo's record shows is the version DOI of v2.1.0-alpha.1. The citation of v2.2.0-alpha.1 now names 10.5281/zenodo.24012764, the concept DOI for all versions, which the README badge already names. The maintainer chose the concept DOI in the menu of 2026-11-29, before the tag. What changed - CITATION.cff: one line, the doi. Checks - s10_rel3_citation.out: the file parses as YAML and holds version 2.2.0-alpha.1, date-released 2026-11-29 and the concept DOI; the README badge names the same DOI. The Zenodo record names it as the conceptdoi of both records (s10_rel1_zenodo.out). - s10_rel3_exits.txt: the gates with label rel3, ten zeros. One file, +1 -1; git diff --check exits 0. - The s10 files are under /tmp/opencode, outside the repository. Not verified - Zenodo: whether its GitHub integration issues a version DOI for the new release, and how it treats a concept DOI in the file. Review. Tree approved, and the message with it, on the maintainer's word for the menu answer. Against HEAD the diff is one line, CITATION.cff:10; PyYAML parses the file and the doi is its only changed value. No other tracked file names 24012765, and README.md:3 already names 24012764. CFF 1.2.0 takes any DOI in that field (from memory; no validator ran here). Not verifiable offline: what Zenodo does with the file at the release.v2.2.0-alpha.1 |
||
|
|
9b346ea3cc |
build(image): the base pin follows the version bump
The version bump of |
||
|
|
8efad0d448 |
chore(release): v2.2.0-alpha.1, the version and the release notes
The maintainer's request, in their words: "I want to tag a new minor release for
the image and packages". The menu of 2026-11-28: the release is v2.2.0-alpha.1
(pyproject and the lockfile say 2.2.0a1; the notes say that no pre-push
capability is admitted yet); the notes and the tag name are shown first. The
maintainer approved the entry as drafted (/tmp/opencode/s10_rel1_notes_draft.md).
After that approval the date moved to the expected day of the tag, one sentence
in the last bullet and a closing paragraph were added, and a reviewer's three
findings on wording were applied: the gate of task 11.4 against the final gate
of the benchmark, the frozen population v4, and the reason of the deselected
assertion. The maintainer sees the final entry again before the tag.
What changed
- pyproject.toml, uv.lock and src/openultrasast/__init__.py: the version is
2.2.0a1.
- CITATION.cff: version 2.2.0-alpha.1 and date-released 2026-11-29. Its doi line
is unchanged: it names 10.5281/zenodo.24012765, the version DOI of
v2.1.0-alpha.1. The concept DOI is 10.5281/zenodo.24012764 (s10_rel1_zenodo.out).
The choice is left to the maintainer before the tag.
- RELEASE_NOTES.md: the entry of v2.2.0-alpha.1 at the top, 49 lines, in the
form of the earlier entries. Beyond the approved draft it says that CI on
main is green again, that the final gate of the benchmark waits for the
governed run, that population v4 is frozen for M4, and that the release job
of an alpha tag still deselects one assertion, for a reason that is resolved.
Checks
- s10_rel1_version.out: uv lock --check exits 0; the three version strings are
2.2.0a1; the package reports 2.2.0a1.
- s10_rel1_exits.txt: the gates with label rel1, ten zeros. s10_rel1_diffcheck.out:
five files, +54 -5; git diff --check exits 0; no non-ASCII character added; the
widest added line of the entry is 108 columns.
- s10_rel1_claims.out: CI on
|
||
|
|
f756099c9d |
fix(search-with-proof): a chromium failure names the first line of its output, where its cause is
The CI run on |
||
|
|
1721b58f93 |
test(search-with-proof): the probe test prints its whole record when the status is not ok
The CI run on |
||
|
|
734ab6ab58 |
fix(tests): the reviewed digest of tests/test_unseen_calibrate.py follows its import path
CI on main after the push of |
||
|
|
d68280bf2d |
ci(release): keep the three newest releases, tags and versioned images
The maintainer's request, in their words: "add a retention of 3 releases and
tags, and delete the old". The menu of 2026-11-28, four answers, each the option
recommended: the three newest version tags with their releases, by the date of
the tag, pre-releases included (the archive/* tags stay); one workflow that runs
after each release and on demand and logs what it deletes; the old ones are
listed first and deleted on the maintainer's word; older version tags of the
images are deleted too.
What changed
- One new file, .github/workflows/release-retention.yml (150 lines).
- Triggers: a manual run, with dry run on by default, and the end of the Tagged
Release workflow. The run after a release only lists. A manual run with dry
run off deletes.
- The rule: version tags (vX.Y.Z with an optional pre-release) by the date of
the tag. The newest RELEASES_TO_KEEP (3) stay, and so does the latest stable
release. The others go with their releases.
- Images: for openultrasast and openultrasast-runner, a version goes only when
every one of its tags came from a deleted release tag (the version, and the
major.minor of a stable one). A version that carries latest, main, a sha or
a tag of a kept release stays and is named in the summary.
- Guards: a non-version tag is never touched; more than 20 deletions in one run
stop the job; the plan is written to the job summary before the images are
read and before anything is deleted; one read gives the releases and the
latest stable release, and a failed read stops the job; a failed call fails
the job, and the log names the call and the reason gh printed.
Checks
- s10_rr1_harness_evidence.out: the python of the workflow, taken out of the
file and run on the local tags of this repository with a stand-in for gh.
Five runs. A dry run that keeps 3 exits 0 and deletes nothing. A deleting
run that keeps 3 makes nine deleting calls: five image versions, then four
releases. A deleting run that keeps 1 leaves the latest stable release
v2.0.1 in place and deletes the tag v2.0.0, which has no release, by the
API: eleven calls. A deleting run where the read of the releases fails exits
1 with no deleting call. A deleting run where the read of the first image
fails exits 1 with the plan in its summary and no deleting call.
- s10_rr1_file.out: the file is ASCII; its longest line is 120 columns; the
step passes bash -n and its python compiles.
- s10_rr1_exits.txt: the gates with label rr1, ten zeros (they do not read the
workflow; they show that the tree is otherwise unchanged).
Not verified
- The run on GitHub itself. The path for user-owned packages with GITHUB_TOKEN
(/user/packages/container/{name}/versions) is proven only by the first run.
The documentation of GitHub says a workflow deletes package versions through
the REST API only with admin permission on the package, which a repository
that publishes the package has by default (public preview).
- No test in tests/ reads the new workflow.
Review.
Two rounds, read-only, on the workflow, release.yml, engine-image.yml, the harness,
its stand-in and the evidence; the step's own shell script ran under bash with my own
stand-ins for git and gh. Round one blocked the file: the read of the latest release
was swallowed, so with three pre-releases above the latest stable a failed read let a
deleting run exit 0, print nothing and delete the release and the tag v2.0.1; a failed
call named the command but not the reason. Round two: one read of the releases with
isLatest must succeed, gh() exits with the call, its code and the stderr, and the plan
precedes the images and the limit check. The attack repeated: exit 1, the call and its
502 named, no deleting call. Measured too: a failed delete names call and reason; a
failed image read leaves the plan in the summary; 27 planned deletions stop the same
way. The harness reproduces its five runs (exit 0, 0, 0, 1, 1; deleting calls 0, 9, 11,
0, 0); jq confirms the tab-separated rows. Left for GitHub: isLatest and the package path.
|
||
|
|
2bf92717aa |
docs: a humanizer pass over the README and the docs pages
The maintainer's request, in their words: "run /humanizer across the readme and docs and push them to main". The menu of 2026-11-28, three answers, each the option recommended: prose only (headings, code blocks, commands, paths, link targets and quoted strings stay); README.md and the 21 pages under docs/ (the three ops pages that the site includes stay as they are); the push follows the full gate. What changed - The pass read the 22 files with the humanizer skill, in its register for reference text: plain and neutral, no personality added. Apart from the two corrections below, a file was edited only where a pattern of the skill required it. - Six files changed, +14 -12 (s10_rd3_diffcheck.out). The other 16 pages are byte-identical to HEAD. - README.md: one tailing negation became a sentence of its own. A missing engine is recorded as a degradation; it does not count as a clean result. - README.md, docs/architecture.md, docs/memory-and-detection.md and docs/scanning.md: four sentences lost a diff-anchored "now" (one word each). - docs/pre-push-for-developers.md: two "not just" contrasts, a tailing negation and a run of three subjectless "No ..." fragments became plain clauses. The bold label keeps its strength: "It can prove as well as warn." - Two old faults that the README rewrite of |
||
|
|
c10dc11a43 |
docs(readme): a system map above the documentation index; open parts link docs to the roadmap
The maintainer's request of 2026-11-28, in chat, after |
||
|
|
6ef8381396 |
docs(readme): an adopter's front door; roadmap and engine-trace runbook move to docs
The maintainer's request of 2026-11-28, in chat: update the README for an adopter
with /cobesy; move the parts on the roadmap and on technical internals to docs;
index docs/ from the README; add a roadmap visualization with the present state
and the past milestones; then give the choices for the open items through the
menu. The menu had eleven questions, each answered with the option recommended.
Two answers govern this commit. "README first": the README work is committed with
the per-commit gate and a fresh reviewer, before the record commit for 5b and
item 5c. "Fix in this commit": the faults found while moving text are fixed here,
the wording shown first.
The wording of the two fixes was shown in chat and answered "Write it as shown
(Recommended)" and "Say why, in a comment (Recommended)". A third fault offered in
that menu, "five docs pages link README anchors that do not exist", was the
session's error: they are seven links, in four pages, to five anchors of
ops/ax/README.md and ops/README.md, and all five headings exist. Nothing was
repointed. The learning is in the handover, which is not tracked, with the
maintainer's approval.
What changed. Measured in /tmp/opencode/s10_rd1_diffcheck.out: five tracked files
changed (144 insertions, 328 deletions) and three files are new.
- README.md, 488 lines at HEAD and 296 now. It keeps the install of Tier 1 and
Tier 2, the scan modes, the run artifacts and the maintainer commands. It adds
"What you can run today", "Status and roadmap" (a Mermaid ladder of R0 to R6, a
table with each step's state on 2026-11-28, a table of past milestones) and
"Documentation", a table with one row for each of the 21 pages under docs/.
- docs/roadmap.md, new, 123 lines: the destination, the ladder with what must be
true to move on, the release milestones M1a to M5, the past milestones, the
status of 2026-11-06 as the README carried it, what changed after that day, and
the rules that bind every step.
- ops/ax/engine-traces.md, new, 80 lines: the README's section "Engine traces on
kube-ax" as it stood, with "s3://..." written "s3://<bucket>" and the link to
ops/ax/README.md written as a path and a section name. docs/ops/ax/engine-traces.md,
new, includes it from its line 3, as docs/ops/ax/README.md includes
ops/ax/README.md.
- mkdocs.yml: two entries in the nav, Roadmap and Engine traces on kube-ax.
- docs/evaluation.md: one paragraph with the gate's committed baseline
(benchmarks/measurements/2026-09-06-gate-baseline.txt: recall 93.62%, 44 of 47;
false positives 0.0%), the day the README quoted it (2026-10-02,
|
||
|
|
3e134f4e0d |
docs(steering): a dated note on 4.4: its text stays, three points are open (item 5b)
The maintainer's decision. Question 10 of the ninth session's menu, answered on 2026-11-27 (.kiro/handover.md:1344-1347, which is not tracked): "Roadmap note now": the next session drafts a dated note for .kiro/steering/roadmap.md beside its note on 5.4 and shows the wording to the maintainer before anything is written. Not chosen: "Wait for the re-plan"; "Open the three points now" (the menu's own label of that option is "Decide now what 4.4 is on kube-ax", handover 1462). The option as offered (handover 1460-1461): "A dated note in the roadmap": beside its note of 2026-11-26 on 5.4, saying that the task's text stays as written and that the three points are open; steering is the maintainer's, so give the words. The wording was shown to the maintainer in chat on 2026-11-28, after the checkpoint of 09:33:04Z, and put as one question with the question tool: "Is this the wording of the dated note for .kiro/steering/roadmap.md (answer 10, "Roadmap note now")? Nothing is written before your answer." The maintainer answered "Write it as shown (Recommended)", whose description, as stored, is: "The six lines are added after roadmap.md:322, as a second sub-bullet; no other line changes; one commit; your answer of 2026-11-27 is quoted in the record commit." The label is on record since |
||
|
|
e2163a4fea |
feat(scan): an unwritable tree keeps a scan's learnings under the runs directory (item 5b)
The decision of the maintainer on the ninth session's menu, answer 9 (.kiro/handover.md,
untracked, 1340-1343 as it stood on 2026-11-27; the option as offered, 1451-1452):
> 9. The ledger in the image. Answer: "Decide the key now": a digest of the tree's files
> (the `fingerprint` of the `provenance` stage is no digest), one ledger per digest under
> the runs directory; a design note is shown to the maintainer before any code.
The design note (/tmp/opencode/s10_c10_design_note.md, 299 lines) was reviewed in five
rounds before it was shown, and shown to the maintainer whole on 2026-11-27 with its three
questions. The maintainer's answers came on 2026-11-28, through the question tool, each the
recommended option as offered: "Stand as written (Recommended)" on the note's rule of reading
and writing (its section 3.3), "With the runs, by last use (Recommended)" on how long a ledger
stays (section 3.5), and "Build it now (Recommended)". The dated note on task 3.1 of
.kiro/specs/contributor-scan/tasks.md (lines 459-502) carries the rule as approved.
The fault: the image mounts the target read-only, so the ledger a scan writes into the tree
(<target>/.openultrasast/calibration/false_positive_learnings.json) cannot be written there,
the scan records ledger_not_written, and the next scan in the image starts without the
learnings of the one before.
What changed
- src/openultrasast/tree_digest.py: tree_digest(target, runs_directory) (line 48), a sha256
over one entry per file in path order (the length of the path, a colon, the path, a tab,
the sha256 of the bytes), after a version line. Left out: links, the directories a scan
ignores (IGNORED_DIRS, so that the tree's ledger does not change its own key) and the runs
directory, whichever way it is reached (by device and inode). A file that cannot be read
and a directory that cannot be listed are named "unreadable"; a directory that can be
listed but not searched raises, as the scan's own reading of the tree does.
- src/openultrasast/digest_ledger.py: the ledger of a digest, calibration/<digest>.json under
the runs directory, in the JSON of the tree's ledger. read_digest_ledger (line 47) reads it
and marks it as used; settle_digest_ledger (line 65) applies the rule.
The tree took the write: the ledger is removed. The tree refused: the ledger is written
with its own entries and this scan's new ones, never one whose finding id the tree's
ledger has, only when that differs from its content, and removed when that would leave it
empty. No write: a ledger whose every entry the tree's ledger also has is removed. One that
could not be read (a file that is not a ledger, whatever its top level or its depth) is
taken for empty and goes, unless the tree refused and this scan wrote it. It is written
through a temporary file of the writer's own and a rename (line 112).
- src/openultrasast/cli.py: the stage tree_digest, before any stage reads the tree
(cli.py:603-605); _read_ledgers (cli.py:1085-1099), the tree's ledger and then the
digest's, the tree's entry winning by finding id; _persist_calibration_feedback
(cli.py:1101-1136), which writes the tree's ledger when its content would differ from what
it held, also when only the digest's entries are new to it; the manifest's ledger block
(cli.py:731-735); a notice when the digest's ledger could not be written or removed
(cli.py:755).
- src/openultrasast/run.py: prune_expired_ledgers (run.py:112), called by prune_scan_runs
(run.py:71-99). Under calibration/ of the same two locations as the runs, a ledger, or the
temporary file it was written through, last used OPENULTRASAST_RUNS_RETENTION_DAYS days
ago is removed; 0 keeps all. Files called something else, links and directories stay. A
removal that fails is said once and costs the scan nothing.
- src/openultrasast/reports.py: write_manifest takes ledger (reports.py:212, 254-255). The
ledger_not_written sentence names the digest's ledger when it holds the learnings
(reports.py:461-467, chosen at 479-483).
- README.md, docs/examples.md, docs/architecture.md and
.agents/skills/openultrasast-scan/SKILL.md say where the learnings of a read-only tree go,
and what removes them.
Two departures from recorded decisions, both put to the maintainer in the note and accepted
with it:
- The tree's ledger is written when a scan learns nothing new, because the digest's entries
are new to it. The decision of 2026-11-24 says it "is written only when a scan learns
something" (spec.json:68).
- A ledger of a digest is removed when it expires, and its time is changed when a scan reads
it. The decision of 2026-11-24 says "the scan's own run and anything not named like a run
are never touched" (spec.json:73), and dates a run by its id, where a ledger is dated by
its use.
Measured
- The built function gives the note's prototype's digest for the four-file subject
(915506a8...) and for libpng's copy (1dcd664f...): s10_c10_port.out.
- In the image, on the final code. A probe image of openultrasast:dev (3f959b31f2f2) with
the tree's package copied over it, built at 09:06:36Z and holding the tree's 297 .py files
(s10_c10_image_probe/03_probe_sources.out, s10_c10_sources_still_equal4.out). Standard
mode, no key, network none. The four C files of contrib/examples of libpng and their
README, copied fresh and mounted read-only at /target; a scratch runs directory mounted at
/reports with the wrapper's OPENULTRASAST_RUNS_DIR=/reports (s10_c10_image_probe.sh,
stamps 09:06:36Z to 09:09:14Z, 2026-11-28).
- The first scan learns four entries and keeps them in /reports/calibration/<digest>.json:
calibrations_applied=0, project_score 26, the manifest's ledger {digest_ledger: written,
learnings_read: {digest: 0, tree: 0}} (10_, 11_). The report names the file.
- The second scan of the same bytes reads them: calibrations_applied=2 on two files,
project_score 59, penalty_total 32.0, learnings_read 4 from the digest's ledger,
digest_ledger "left as it was" (20_, 21_). The file's time is that of the second scan's
read, 09:07:19Z (22_).
- The digest the scan took in the image equals the one taken on the host for the same
files (s10_c10_image_digest_host4.out). The target is unchanged
(s10_c10_image_target_same4.out).
- Three earlier runs of this probe and of the native run below, each on the code as it
stood before a later correction of the same rule (the value for a ledger that could not
be read; a ledger whose top level is not an object; one nested too deep), gave the same
numbers. Their stamps: 08:12:50Z to 08:17:31Z, 08:23:38Z to 08:27:42Z and 08:50:15Z to
08:54:17Z. They are kept as s10_c10_image_probe_run1, _run2, s10_c10_native_run1,
_run2 and _run3; of the third image run s10_c10_image_probe_run3.out and the host,
target and sources checks numbered 3 remain, since s10_c10_image_probe_run3 is empty.
Its files were read by the reviewer in round two.
- The shipped image, the control, on the same files: calibrations_applied=0 and
project_score 26 on both scans, no ledger block and no ledger (30_ to 42_).
- Natively, on a fresh copy of the same five files, the network off (s10_c10_native.sh,
09:09:14Z to 09:10:38Z): the first scan writes the tree's ledger (calibrations_applied=0,
project_score 26, digest_ledger none), the second reads it (calibrations_applied=2,
project_score 59, learnings_read 4 from the tree's ledger), and no ledger of a digest is
made (s10_c10_native/10_ to 22_).
- The probe left no container (2 before, 2 after: 00_, 91_) and its image is removed (90_,
92_).
Tests
- tests/test_tree_digest.py (7) and tests/test_digest_ledger.py (11, one over nine contents
a file may hold); seven tests in tests/test_scan_output_location.py, six through the scan
(three over two cases) and one on _read_ledgers; six in tests/test_run_pruning.py; one
sentence in tests/test_reports.py. The scan test of a refused write selects its run by
name now, since the runs directory holds calibration/ as well.
- RED on an archive of
|
||
|
|
e231b78e04 |
docs(readme): the AX coordinator commands build with docker compose only (item 5b)
Decision (the ninth session's menu of 2026-11-27, question 8, "README.md's copy of the base pin"; .kiro/handover.md, not tracked, lines 1338-1339 and 1439-1445). The maintainer's answer: "Drop the two lines". As offered: "README.md says `docker compose build` only; one docs commit." Not chosen: "Guard it with a test" (the session's recommendation); "Leave it". The fault: the two build commands of the section "Engine traces on kube-ax", one docker buildx build and one docker build, carried the base tag and digest by hand in two --build-arg pairs, and no test read them. When plane/task-base.digest changes, both builds still succeed on the old base until that base is deleted from GHCR. The copy in docker-compose.yml is guarded (tests/test_task_images.py:51-59, test_compose_builds_from_the_pinned_base). What changed (README.md:440-458, which are lines 440-463 on efa311a; one file, 12 insertions, 17 deletions): - The two build commands are gone, with the lines that served them alone: TASK_TAG, the metadata file that gave TASK_IMAGE its digest, and the printf of it. - The block builds with `OUSAST_VERSION=engine-ax docker compose build` and sets TASK_IMAGE to the reference the Engine image workflow printed. - The lead-in and the paragraph after the block say what the block does now. The sentence "The Engine image workflow also builds/pushes both images and prints each digest; CI needs the changes published before dispatch" stands as it was. The session's readings of the decision, open to correction: 1. OUSAST_VERSION=engine-ax stands before the command so that the image keeps the tag the two trace commands below name (--docker-image openultrasast:engine-ax, README.md:469 and :479) and does not overwrite openultrasast:dev, the image the wrapper uses (ops/shell/ousast.sh:64) and the default of --docker-image (benchmarks/learn/engine_trace.py:890). The block still says docker compose build alone. 2. TASK_IMAGE now comes from the Engine image workflow. The dropped buildx command was the README's only local build of the task image. The workflow's engine job builds plane/Dockerfile.engine-task, target engine, pushes ghcr.io/<owner>/ousast-engine-task at sha-<7> and main, and writes image@digest to its log and to its step summary (.github/workflows/engine-image.yml:104-151). AX takes --image by digest only (engine_trace.py:915-916). 3. The README no longer documents a build of the task image from uncommitted code. The last sentence of the paragraph says what a reader now gets: the Docker lane runs the local image, committed or not; the AX lanes run the task image of the revision the workflow built. 4. The paragraph that opens the section (README.md:412-413, "Rebuild it after code changes and pass its digest with --image") is left as it is: the rebuild is the workflow's, and the sentence does not say who builds. 5. When the workflow runs is not restated here; the sentence points at the rebuild policy (ops/ax/README.md:296-319). Measured (files under /tmp/opencode; all but the gate files start with their command; the gates were run as `bash /tmp/opencode/s10_gates.sh c9`): - The image compose names: `OUSAST_VERSION=engine-ax docker compose config --images` prints openultrasast:engine-ax; without the variable, openultrasast:dev (s10_c9_compose_images.out). Only the lines that start with openultrasast: were printed. No image was built. - The block parses: `sed -n '444,449p' README.md | bash -n` exits 0 (s10_c9_block.out). - Before and after: a grep for six markers (build-arg, TASK_BASE_TAG, TASK_BASE_DIGEST, docker build, TASK_TAG, metadata-file) over README.md gives 10 lines on |
||
|
|
efa311a112 |
fix(shell): the wrapper passes the retention days into the image (item 5b)
The maintainer's second decision on answer 7, taken on 2026-11-27 while the scan path change ( |
||
|
|
312c09bdbf |
fix(scan): a scan in the image prunes the wrapper's runs directory too (item 5b)
The maintainer's answer 7 of 2026-11-27 (the ninth session's menu). The label is in .kiro/specs/contributor-scan/spec.json ( |
||
|
|
d9205fd267 |
docs(ops): say where ousast pairs and ousast repos find their defaults (item 5b)
The maintainer's answer 6 of 2026-11-27, "Document: run from checkout"
(.kiro/handover.md:1333-1334): "one sentence in ops/README.md; no code changes." In
the handover's options for that question (:1422-1430): "run them from the checkout
root, as every page shows."
What changed
- ops/README.md, at the end of "Use it as a command", after the paragraph on the
native route (lines 40-42): "With their defaults, `ousast pairs` and `ousast repos`
need the root of the checkout as the working directory, which under the wrapper means
a native run: `benchmarks/pairs/catalog.toml` and `benchmarks/repos` are read from
the current directory."
- No code change, no test change.
The session's reading of the answer
- The sentence names the native run, which the answer's sentence does not. Measured
below, the checkout root does not help through the wrapper's container path: the
container's working directory is /work (docker-compose.yml:37), never the checkout.
The image holds a copy of both defaults in /app, so the need is the wrapper's, not
Docker's; the sentence says so.
- The sentence does not repeat "as every page shows". The pages show the two commands
(docs/examples.md:66-70, README.md:331, benchmarks/pairs/README.md:126-128,
benchmarks/repos/README.md:16-18); by reading, none of these four places says in
which directory they are run. So the sentence gives the reason instead.
Measured (/tmp/opencode/s10_c6_probe.sh, output s10_c6_probe.out, 17:32:07Z to
17:32:13Z; each run file starts with its command, the wrapper files with a one-line
description of the call)
- From an empty directory, the CLI directly and natively: `pairs` ends with "pair
catalog is not a file: benchmarks/pairs/catalog.toml", exit 1
(s10_c6_native_elsewhere_pairs.out); `repos` with "no repository recipe matches
'all' in benchmarks/repos", exit 1 (s10_c6_native_elsewhere_repos.out).
- The same two through the wrapper's native path, with stubs of joern and joern-parse
ahead on PATH, never called (s10_c6_wrapper_native_elsewhere_pairs.out,
s10_c6_wrapper_native_elsewhere_repos.out).
- From the checkout root, natively: `repos` lists seven recipes, exit 0
(s10_c6_native_root_repos.out). `pairs --slice sast --json` ends with exit 0 and
18,013 bytes of JSON, with per_slice.sast.pairs 11 and achievable.sast.pairs 10
(one known limit, src/openultrasast/pairs.py:467), and without the lookup's message
(s10_c6_native_root_pairs.out for the exit and the message;
s10_c6_native_root_pairs_full.out for the bytes and the two counts). joern was not
on PATH for that run; what scored the pairs was not examined.
- From the checkout root, through the wrapper's container path (OUSAST_PREFER_NATIVE=0;
the image openultrasast:dev 3f959b31f2f2): both end with the same two messages, exit
1 (s10_c6_wrapper_container_root_pairs.out,
s10_c6_wrapper_container_root_repos.out). No container remains
(s10_c6_wrapper_container_index.out).
- A separate run at 17:40:30Z, not from the probe: in the image's own working directory
/app (Dockerfile:38), a plain `docker run` with no mount and no network, `repos`
lists the seven recipes, each absent in the container, exit 0
(s10_c6_image_app_repos.out). `pairs` was not run there.
By reading, not measured
- Where the defaults come from: src/openultrasast/pairs.py:47-53 and
src/openultrasast/repos.py:34 hold relative paths. The two stops are at
src/openultrasast/cli.py:1156-1157 and :1178-1180.
- The image's copy: Dockerfile:44 copies benchmarks, and .dockerignore excludes
nothing of benchmarks/pairs or benchmarks/repos.
Checks, on the final text
- `mkdocs build --strict` into scratch: exit 0 (s10_c6b_mkdocs.out); the built page
holds a phrase from each of the sentence's three lines once, and the first wording
zero times (s10_c6c_site_sentence.out).
- tests/test_docs_site.py and tests/test_removed_plane_references.py: 8 passed
(s10_c6b_docs_tests.out).
- Gates (s10_c6b_exits.txt): ten zeros; the three gate outputs equal the baseline's.
Found and not fixed, for the maintainer
- `ousast model candidates` has the same default for its catalog
(src/openultrasast/cli.py:262), and `ousast plane harvest` for its own (:324). The
sentence names the two commands of the answer. Neither was run.
- The pages that show the two commands do not say where they are run from (above). The
answer puts one sentence in ops/README.md.
- Through the wrapper's container path the two commands cannot reach their defaults,
by reading from any directory. A reader with Docker alone is told that they need a
native run, not what to do instead.
Not checked
- ops/shell/ousast.ps1 was not read for this change.
- `ousast pairs` with --catalog, and `ousast repos` with --dir, through either path.
- `ousast pairs` in the image's /app.
- The whole test suite.
Review
- Review: three rounds against
|
||
|
|
d8b4cac023 |
fix(shell): the wrapper says so when it cannot make its runs directory (item 5b)
The maintainer's answer 4 of 2026-11-27, "Guard it" (.kiro/handover.md:1409-1413), as
offered: "a clear message when HOME is unset, and a failed mkdir stops the wrapper
with exit 1; a test first." The fault it answers, in the same words: "With HOME unset
the wrapper now fails ($HOME/.cache becomes /.cache), where it wrote ./.ousast
before; a failed mkdir is not checked, as before."
What changed
- ops/shell/ousast.sh, the container path: the wrapper returns 1 with "ousast: HOME is
not set, so there is no ~/.cache/openultrasast/runs to write the runs to" when HOME
is unset or empty, and with "ousast: cannot create <runs>, where the runs are
written" when mkdir -p fails (mkdir's own line comes first).
- The two lines that set `runs` and ran mkdir -p moved up to that place, from after the
build. The placement is the session's reading of "stops the wrapper": a cold build
pulls ~2 GB, and a run that cannot write its runs should say so before it waits.
- The native path names no HOME and is not touched.
Tests (tests/test_shell_wrapper.py)
- test_the_container_path_stops_when_home_is_not_set: exit 1, that one line on
stderr, nothing on stdout, so neither the build nor the container is started.
- test_a_runs_directory_that_cannot_be_made_stops_the_wrapper: a file where
$HOME/.cache should be; exit 1, the wrapper's line last on stderr, nothing on stdout.
- The helper `ousast` takes `without_home`. The docker stub answers `image inspect`
with exit 1, so the wrapper takes its build branch in each test that reaches the
build (the second and the third); before that, "nothing on stdout" said nothing
about the build.
- RED, on an archive of HEAD with the final test file (s10_c4_red5.out): 2 failed, 3
passed, each `assert 0 == 1`. For the reason of the fault: the wrapper builds, mkdir
is refused ("/.cache: Permission denied", run as uid 1000) or fails ("Not a
directory"), the wrapper goes on to the container (with reports=/.cache/... when
HOME is unset), and the exit status is 0.
- GREEN, on the working tree (s10_c4_green5.out): 5 passed.
- A mutant with the guard behind the build fails both new tests on the build's line
(/tmp/opencode/s10_c4_mutant.py, output s10_c4_mut.out), so the tests pin the
placement; with another shebang in STUB it fails the same way (s10_c4_nopin.out).
- Gates (s10_c4e_exits.txt): ten zeros; the three gate outputs equal the baseline's.
Measured outside the stubs (/tmp/opencode/s10_c4_probe.sh, output s10_c4_probe.out):
real bash on this machine, the native path switched off so that no probe can scan.
HOME unset, HOME empty, and bash under set -u with HOME unset each print the one line
and exit 1; a file at $HOME/.cache prints mkdir's line, then the wrapper's, exit 1.
By reading, not measured
- zsh can source the wrapper as well. The block uses `[ -z "${HOME:-}" ]`, `local`,
`if ! mkdir -p`, `echo ... >&2` and `return 1`; zsh is not installed here, so no
probe ran.
- A run as root with HOME unset had another shape on HEAD: mkdir -p /.cache succeeds
there, so the runs went to the filesystem root with no error. The guard closes it
the same way. This session's runs are as uid 1000.
Found and not fixed, for the maintainer
- The helper's second parameter is `executables`. The third test passes "scan" there
(tests/test_shell_wrapper.py:65, HEAD:63), which makes four stubs named s, c, a and
n beside docker's. Nothing calls them. The new tests pass an empty tuple.
- A runs directory that exists but cannot be written to passes the guard: mkdir -p
exits 0 on it (s10_c4_readonly_runs.out), and the wrapper goes on to docker. The
decision says "a failed mkdir".
- The container path reads $HOME/.cache alone and ignores XDG_CACHE_HOME, which the
native path honours (src/openultrasast/config.py:198-203); README.md:189-190 and
docs/examples.md:3-5 state the rule for every run. From before this commit.
- ops/shell/ousast.ps1:44-45 has the same shape, a New-Item whose result is not
checked, after the build. Read, not run: pwsh is not installed.
- The wrapper's message for an unset HOME (ops/shell/ousast.sh:53) describes the
container path, which reads $HOME alone. Without HOME, Python's Path.home() and
bash's `~` still give /home/mc on this machine (s10_c4_pathhome.out), and a native
scan's default runs directory comes from the former unless XDG_CACHE_HOME is set to
an absolute path (src/openultrasast/config.py:198-203 and :216-226). As decided.
Review
- Review: four rounds against
|
||
|
|
739688730f |
fix(push): the background child is started with -P, as the wrapper is (item 5b)
The maintainer's answer of 2026-11-27 to question 3 of the ninth session's menu, "Add -P there too", as offered: one line, a test first, a reviewer. src/openultrasast/push/background.py starts the detached replay of `ousast pre-push --engine background` with the interpreter, -m and openultrasast.cli, from the pushed repository. With -m alone the working directory is first on the interpreter's path, so a file of the pushed repository could stand in for a module the CLI imports. The wrapper's native path had the same fault and was fixed with -P in a6e8e26; the reviewer of that commit found this one and it was left alone. The child is now started with -P, which keeps that directory off the path. The flag needs Python 3.11, the project's floor (pyproject.toml). Measured by the new test, with a real child process: tests/test_push_background.py puts a json.py that exits into the pushed repository and starts the child. On a git archive of HEAD the child's log is "SHADOW-EXECUTED" and its artifact is never written (s10_c3_red2.out). With the change the artifact is written and the log does not hold that line, on this host's default PATH, where Joern is not found (the child ends in about 1 s), and with Joern 4.0.625 and its JavaScript frontend on PATH, where the child uses its whole deadline (s10_c3_green2.out, s10_c3_green3.out). The five push test files give 106 passed. ruff, mypy, the three gates and compileall pass, and the gates print what they printed before (s10_c3b_exits.txt). `git diff --check` exits 0. No whole-suite run: that is step 9. An independent reviewer blocked the first round on the test: its wait equalled the child's deadline, so it was red on a host where the engine can build a JavaScript graph (1 failed, 4 passed). The child's deadline is now 5 s. The second round approved the final diff. Found and not fixed, for the maintainer: - The container path has the fault too, by one probe. docker-compose.yml:37 sets the working directory to /work, and the wrapper's own comment (ops/shell/ousast.sh:13-16 and :34-35) says the container runs in the caller's directory. On the local openultrasast:dev image 3f959b31f2f2, network none, a tree that holds such a json.py mounted at /work: the image's own entrypoint (Dockerfile:46, python -m openultrasast.cli) prints SHADOW-EXECUTED for --help and exits 1; the same tree with -P prints the usage (s10_c3_container_probe.out). The wrapper and compose were not run, and the published image was not probed. - ops/ax/smoke-run.sh:9 and :12, ops/ax/up.sh:14 and ops/ax/probe-placement.sh:16 run this checkout's code with -m and without -P, in the caller's directory (by reading): the CLI at smoke-run.sh:12, openultrasast.plane.profile at the other three. - src/openultrasast/plane/runner.py:678 starts a task's module with -m from the task's first workspace (by reading). Whether a file of that workspace can stand in for a module the task imports was not measured. - The two launches in src/openultrasast/search/demo.py use -I, which keeps the directory off the path. |
||
|
|
f6b1406541 |
fix(model): a failed judge call is recorded and ends the asking (item 5b)
The maintainer's answer of 2026-11-27 to question 2 of the ninth session's menu, "Record and stop
asking", as offered: "a failed judge call adds a degradation to the manifest, with the count; the
report says those questions went unasked; after one transport failure the remaining questions are
not asked." Measured by the ninth session: with a key in the environment and no network, 16 judge
calls failed in one scan of a four-file subject, three attempts each, and each dropped its claim
as a "no" would (model/pipeline.py); the manifest counted model_calls 16 and recorded no failure,
and the report said less than that of a run without an endpoint.
What changed:
- model/scan.py, `_CountingClient`: a call that raises is counted in `failed` and ends the asking.
The calls left in the question being put are refused without reaching the client (`refused`),
and the driver withholds the judge from every question after it, as it does when the budget runs
out. An answer with no decision in it (empty, not JSON, no boolean `vulnerable`) is counted in
`failed` as well and does not end the asking. The graph still arbitrates every region.
- Two degradations, each with a sentence under "What could not be analysed" (reports.py) and a
line in the scan skill's list:
- `judge_calls_failed`, `count`: the judge calls that gave no decision.
- `judge_withheld`, `questions`: the judge calls refused after the failure in the question
being put. Of the questions after it the report says that none was put to the judge; they are
not counted, because some of them would have put nothing to the judge.
- model/pipeline.py: the parsing half of `_ask` is moved as it was into `judge_decision`, so the
driver reads a decision the way `_ask` does. `_ask` returns what it returned.
- The claim of every such question is still dropped, as before: "Keep the claim" was not chosen.
The session's two readings of the decision, open to correction:
- A transport failure is read as a judge call that raised, whatever the exception. The transport
has already made its three attempts for what is transient (provider/openrouter.py), so one
raised call ends the asking for the whole scan. That holds for a connection failure and for a
timeout, and also for a request the endpoint refuses with an error status, where the transport
makes one attempt: there the scan withholds every later question, where before it dropped that
claim alone and went on. The judge_withheld line says so in the report.
- A failed judge call is read as a call that raised or a call whose answer gave no decision. Both
are counted.
Measured on fresh copies of the four C files the ninth session used, with a placeholder key and
the network off (the scratch is /tmp/opencode/s10_c2_* and is not kept):
- Native, in a network namespace without routes: one "judge call failed" line, file_targets=4,
findings=15, exit 0, 45 s (s10_c2_native_key3.out). The ninth session's run of the same bytes:
16 lines, 68 s.
- In a probe image built from openultrasast:dev 3f959b31f2f2 with src copied over, network none:
one line, file_targets=4, findings=15, exit 0, 43 s (s10_c2_image_key3.out). The ninth
session's run: 16 lines, 65 s. The probe image is removed.
- Both manifests: model_calls 1, judge_calls_failed with count 1, judge_withheld with questions
7; report.md carries the two sentences (s10_c2_native_inspect3.out, s10_c2_image_inspect3.out).
The findings are the 15 the ninth session recorded with a key and without one.
Tests, one at a time, each red before its code:
- test_a_judge_that_cannot_be_reached_is_recorded_and_asked_no_further: on a git archive of
HEAD, assert 120 == 1; after, one call, model_calls 1, ten regions arbitrated, the two
degradations with count 1 and questions 5.
- test_a_judge_answer_with_no_decision_in_it_is_counted_and_the_rest_are_still_asked: red with
no degradation; after, count 120 and no judge_withheld.
- test_a_failed_judge_call_is_reported_as_unasked_and_not_as_a_no: red with the two bare
reasons; after, the two sentences. The three red runs, with the package imported from the
archive, are in s10_c2_red8.out: 3 failed, 1 passed.
- GREEN: 657 passed over the 39 test files that name degradations, scan_repository, model_calls
or write_markdown_report (s10_c2_green9.out); 214 passed over ten model, report and skill files
(s10_c2_green8.out). ruff, mypy, the three gates and compileall pass, and the gates print what
they printed before (s10_c2c_exits.txt). `git diff --check` exits 0. No whole-suite run: that is
step 9.
- The review took three rounds on one reviewer. Round one approved a first shape that counted the
withheld regions, and remarked that a region with several families was counted as withheld while
its first family had been put to the judge; its other remarks changed the second sentence,
`__all__` and a docstring. Round two blocked the sum that replaced that count: it added judge
calls to region-and-family questions under one name. The count is of judge calls now. Round
three approved this diff, on the condition that this message carry the measured numbers.
By reading, not measured: a pre-push run makes no judge call (push/runner.py and push/policy.py
pass no client and an execution budget), so the two reasons cannot arise there.
Found and not fixed, for the maintainer:
- .agents/skills/openultrasast-scan/SKILL.md:68-70 and docs/where-we-stand.md:349-350 say that
`learning_endpoint_unavailable` has no line in report.md. It has had one since
|
||
|
|
55583b34c3 |
fix(images): the replay entry leaves benchmarks/unseen, so the replay stage builds (item 5b)
The maintainer's answer of 2026-11-27 to question 1 of the ninth session's menu, "Move the file, fix now": the script leaves benchmarks/unseen for a path the build context keeps, and the four references follow. .dockerignore:32 has excluded benchmarks/unseen since |
||
|
|
80abac5fd1 |
spec(contributor-scan): record the thirteen answers of 2026-11-27 (item 5b)
A record of maintainer decisions, in the form of
|
||
|
|
23c5383701 |
spec(contributor-scan): record item 5a under 3.2, and what is left open (item 5a)
The record of the ninth session (2026-11-26 and 2026-11-27), in the form of |
||
|
|
9a8e0038b0 |
spec(plane-on-kubernetes): 4.4 is on kube-ax, a dated note (item 5a)
The maintainer's decision of 2026-11-26 on the eighth session's menu (item 13), as it
was offered: "plane-on-kubernetes tasks.md:191 says '4.4 Kind proof and record' while
roadmap.md:318 places 4.4 on kube-ax: a dated note or a reworded line." Answer: "4.4
line to kube-ax". The form was offered both ways and left to this session, which says
before this commit that it takes a dated note. A reworded line is not taken: the header
of the spec keeps the text of groups 3 to 8 as written, and this file records change by
dated text (the header note and the last section, both of 2026-11-24).
Two files. In .kiro/specs/plane-on-kubernetes/tasks.md, nine lines are the last
sub-bullet of task 4.4; the line of 4.4 and its bullets are untouched and the checkbox
stays open. In .kiro/specs/plane-on-kubernetes/spec.json, updated_at moves from
2026-11-24T13:58:17Z to 2026-11-27T10:39:48Z:
|
||
|
|
7e26f5fabc |
spec(contributor-scan): the ledger in the image is an open task on 3.1 (item 5a)
A dated note on task 3.1 of .kiro/specs/contributor-scan/tasks.md (ninth session,
2026-11-27). No code changes, and nothing is decided: the maintainer chose "Open task"
on 2026-11-26 for item 3 of the eighth session's menu ("Record it as an open task:
nothing changes now. A dated note on task 3.1 holds the measurements and the design
question (a ledger under the runs directory must be keyed by target, because its
entries name relative paths)."), and the checkbox of 3.1 stays open.
The note holds:
- what a scan does with the false-positive ledger, by reading
src/openultrasast/cli.py and reports.py: the path under the target, the read before
the ranking is calibrated, the write when its content would change, the degradation
ledger_not_written on a read-only target, the report's sentence under "What could
not be analysed", and that through the image a scan applies learnings only from a
ledger already in the tree and can never add one (by the code, not run);
- the measurements of 2026-11-26, read again on 2026-11-27 from the run artifacts, not
from new runs. Standard mode on contrib/examples of libpng at cf53e54, 15 findings on
both sides, no key on either side. In the image (run 20261126T125414Z-facce3bb):
calibrations_applied=0, project_score 26, penalty_total 80.0. Natively, a second scan
of a copy that held the ledger an earlier native scan had written:
calibrations_applied=2, project_score 59, penalty_total 32.0. calibrations_applied
counts files: the native second scan applied all four learnings of that ledger, to
two files;
- the design question, with the options not chosen.
The design question names no key for a ledger under the runs directory. The note
records two candidates that cannot serve: the path as the image shows it (every target
is /target there) and the fingerprint of the provenance stage, which classes a tree as
human, agent or mixed and hashes nothing.
The decision and its options are recorded in .kiro/handover.md, which is not tracked;
the note says so. The measurements rest on the eighth and ninth sessions' scratch under
/tmp/opencode, which is not kept; the note names the files.
tests/test_obligation_siblings.py passes (4 tests), ruff, mypy, the three gates and
compileall pass, and the gates print what they printed before. An independent reviewer
approved the change in three rounds. Its remarks are applied: the handover is named as
the record of the decision; the image figures come from the run without a key, as the
native run is; calibrations_applied is said to count files; and a clause that pointed
the design at a function that is not a key is gone. That clause came from the
reviewer's own first-round remark and was written in after checking only the call
site; the reviewer caught it in the second round.
|
||
|
|
6e4a62edd4 |
docs(contributor-scan): the citations in detection-techniques.md name the instruction (item 5a)
docs/detection-techniques.md pointed into Dockerfile and docker-compose.yml by line number, and every one of those citations was off. Its three doc regions were written on 2026-10-02. Then |
||
|
|
dbcbbd7f27 |
docs(contributor-scan): the documented build commands carry the base pin (item 5a)
Three documented build commands would have failed. README.md told the reader to build
plane/Dockerfile.engine-task with docker buildx and Dockerfile with docker build,
without TASK_BASE_TAG and TASK_BASE_DIGEST. Both Dockerfiles default the tag to
base-unpublished and give the digest no default. Measured on 2026-11-27 from a clean
copy of the tree, with the push and the published tags taken out so nothing could be
published: each failed in one to two seconds with `failed to parse stage name
"ghcr.io/norandom/ousast-task-base:base-unpublished@": invalid reference format`.
Both lines now pass the tag and the digest of `base` in plane/task-base.digest, and a
sentence after the block names the file. With those arguments the main Dockerfile
builds (exit 0 in two seconds; the image was removed afterwards). docs/scanning.md
says `docker compose build`, which pins the base and tags openultrasast:dev (the
defaults are guarded by tests/test_task_images.py), and says to run it in a checkout
of this repository.
Found while measuring, and not fixed:
- README.md's buildx line still does not run to the end on this tree. It builds the
last stage, `replay`, and plane/Dockerfile.engine-task:47 copies
benchmarks/unseen/replay_entry.py, which .dockerignore:32 has excluded since
|
||
|
|
53a6937c31 |
docs(contributor-scan): the comment on the first-use build says what the wrapper does (item 5a)
A comment in ops/shell/ousast.sh said the first-use build is silent. It is not: the
wrapper prints one line to say why the run waits, and the build's own output then
shows (the eighth session counted 74 lines of it from a warm cache).
The maintainer chose to keep that output ("Keep output, fix comment", the menu of
2026-11-26): on a cold build it is the only sign that a long download is running. Only
the comment changes, to say what the code does. No behaviour changed.
The clause about a cold build is the decision's wording; no cold build was measured
here. The only first-use capture is the eighth session's warm one, in which the build
shows its running steps, not a byte count.
`bash -n` passes, tests/test_shell_wrapper.py passes (3 tests), ruff, mypy, the three
gates and compileall pass, and the gates print what they printed before. An independent
reviewer approved the change in one round.
|
||
|
|
d1f61fbe6f |
fix(contributor-scan): the wrapper writes its runs to the user cache (item 5a)
The shell wrapper wrote the runs of the image to ./.ousast, inside the repository it was scanning (the eighth session: three runs under it). It now creates ~/.cache/openultrasast/runs, mounts it at /reports, the one writable mount, and passes -e OPENULTRASAST_RUNS_DIR=/reports to its compose run, so nothing is written to the scanned directory. The override is the maintainer's choice of 2026-11-27, on a measurement. Answer 4 of the menu of 2026-11-26 was worded as the mount alone. Measured that day: compose sets OPENULTRASAST_RUNS_DIR=/reports/runs in the service, so the mount alone put the run on the host at ~/.cache/openultrasast/runs/runs/<run>, one level below a native run, and nothing prunes it there (prune_old_runs removes only run directories directly under the root whose names match the run id). With the override the run lands beside native runs. Two things the choice does not change: a scan in the image never prunes, so the wrapper's runs are removed by a later native scan on the default location; and the wrapper writes to ~/.cache/openultrasast/runs whether or not XDG_CACHE_HOME or OPENULTRASAST_RUNS_DIR moves a native run elsewhere. ops/shell/ousast.ps1 gets the same change, the maintainer's second choice: it writes %USERPROFILE%\.cache\openultrasast\runs and passes the same override. That file was edited by reading and WAS NOT RUN: there is no PowerShell on this machine. Tests: tests/test_shell_wrapper.py has a third test. It failed before the change (no runs directory under HOME) and again until the override was passed. After: 3 passed. Measured on 2026-11-27 through the shell wrapper with the real Docker, from a directory without .env, both API keys unset: `ousast scan examples --mode quick` on a copy of libpng's contrib/examples prints run_dir=/reports/<run>, the container prefix, with file_targets=4, findings=4, exit 0; the run is on the host directly under ~/.cache/openultrasast/runs, owned by the user; the scanned directory stays empty. The eight tests of tests/test_docs_site.py and tests/test_removed_plane_references.py pass, `mkdocs build --strict` exits 0, ruff format, ruff check, mypy, the three gates and compileall pass, and the gates print what they printed before the change. An independent reviewer approved the change in one round; its remarks on the README clause, on the test, on the evidence and on the width of one line are applied. Left as it is, for the maintainer: with HOME unset the shell wrapper now fails, where it wrote ./.ousast before ($HOME is empty, so the path is /.cache/openultrasast/runs, and a failed mkdir is not checked, as it was not before). |
||
|
|
5ad9e7781d |
fix(contributor-scan): compose refuses a target that does not exist (item 5a)
A mistyped TARGET read as a clean scan. The `/target` mount was in the short syntax, so
Docker created a path that does not exist as an empty directory owned by 0:0, and the
scan ended with exit 0 and no findings (the eighth session, 2026-11-26: file_targets=0,
findings=0, exit=0).
The mount is now in the long syntax with `create_host_path: false`, as `/reports` is
since
|
||
|
|
a6e8e2615a |
fix(contributor-scan): the wrapper's native path runs in the caller's directory (item 5a)
`ousast scan .` through ops/shell/ousast.sh with a native install scanned the wrong tree. The native path changed into the checkout before it passed the arguments on, so `.` was the OpenUltraSAST checkout and a relative file name was looked up there. The eighth session showed it with a stub interpreter in place of `.venv/bin/python` (`cwd=/tmp/opencode/s8_fakehome args=-m openultrasast.cli scan .`). The check also looked for `joern-parse` only, while the batch queries run `joern`: with `joern-parse` alone on PATH every batch query failed and a standard scan still exited 0 (2026-11-26, 14 findings where the working launcher gives 15). The native path now runs the checkout's interpreter by its absolute path, in the caller's directory, as the container path does, and it is taken only when `joern` is on PATH as well. So `.`, relative names and relative options mean the caller's files. The reviewer found, and a run confirmed, what dropping the `cd` brings: `-m` alone puts the working directory first on the interpreter's path, so a file of the scanned tree could stand in for a module the CLI imports (a `json.py` in the caller's directory: `ousast --help` printed SHADOW-EXECUTED and exited 3). The interpreter is started with `-P`, which keeps that directory off the path; the flag needs Python 3.11, the project's floor (pyproject.toml). Changes a caller sees, beyond the one the decision named: - The checkout's .env is no longer read on the native path; the CLI reads .env from the working directory, which is now the caller's. ops/README.md says so. - `ousast pairs` and `ousast repos` no longer find their defaults outside the checkout, because `benchmarks/` is read relative to the working directory. Measured for `pairs`: through the wrapper natively, and on the container path, `pairs --slice vibe-py` ends with "pair catalog is not a file: benchmarks/pairs/catalog.toml", exit 1, so the container path already behaved this way. `repos` by reading. Run from the checkout root they find their defaults again (by reading; not run). The header's `ousast pairs --slice vibe-py` example is removed. This is a reading the maintainer may correct. - The message for a machine without Docker names both executables. Tests: the new tests/test_shell_wrapper.py runs the wrapper by bash with a stub of the interpreter, `joern`, `joern-parse` and `docker` ahead of /usr/bin and /bin on PATH. Its two tests failed before the change (2 failed: the interpreter ran in the fake checkout, and the native path was taken without `joern`), and the first failed again until `-P` was passed (1 failed). With the real venv and Joern 4.0.625 on PATH, from a directory without .env: `ousast scan examples --mode quick` on a fresh copy of libpng's contrib/examples gives file_targets=4, findings=4, exit 0, before and after the flag, the figures of the eighth session. The eight tests of tests/test_docs_site.py and tests/test_removed_plane_references.py pass, `mkdocs build --strict` exits 0, ruff format, ruff check, mypy, the three gates and compileall pass, and the gates print what they printed before the change. An independent reviewer approved the change in the second round; its two findings of the first round led to the `-P` flag and to the removal of the header example. Found by the reviewer and left alone, outside this decision: the background child of `ousast pre-push` (src/openultrasast/push/background.py) starts the CLI with `-m` and without `-P`, from the pushed repository. |
||
|
|
ea8d3d2e6e |
spec(contributor-scan): record part 2 of the image under 3.2, and what is left open
Started on the maintainer's "proceed" of 2026-11-26, read as step 5 only. The note on task 3.2 records part 2, done in `9d53c32` and `88ea171`, with its evidence: the image built from `88ea171`, the documented command before and after `9d53c32`, the read-only target, the network off, the reserved populations absent, the parity of a first scan natively and in the image on libpng's `contrib/examples` (4 and 4 findings, then 15 and 15) and on libpng whole (167 and 167), the wrapper, the release pins read with `gh`, and what the entailment at `contrib/examples/iccfrompng.c:124` does at `88ea171`: it is still reported, so the roadmap's second criterion does not hold on libpng. The box of 3.2 is ticked; the task's observable is met. A second note lists eleven items left for the maintainer, none of them changed. The first is a fault: the native path of `ops/shell/ousast.sh` changes into the checkout before any path is rewritten, so `ousast scan .` from a user's directory would scan the OpenUltraSAST checkout. Decisions are quoted and everything else is labelled as evidence. No test reads this file; `tests/test_obligation_siblings.py`, which the handover names as the one that reads the specs, passes (4 tests). ruff format, ruff check, mypy, the three gates and compileall pass, and the gates print what they printed before. An independent reviewer approved the note in the third round. Its first verdict corrected the open list: one number was wrong (the first run printed 84 lines, 74 of them build output) and one count could not be verified because its output had not been kept, so it was dropped; five measurements were then re-run with complete captures kept. |
||
|
|
88ea171dbe |
fix(contributor-scan): the release builds the scan image from the pinned base (3.2, part 2)
The `images` job of `.github/workflows/release.yml` built `Dockerfile` with no build arguments, so the file's own defaults applied: `TASK_BASE_TAG=base-unpublished` and an empty digest. The first `FROM` could not be resolved. The log of the `v2.1.0-alpha.1` tag's run (42229293910, job `images (openultrasast, Dockerfile)`, 2026-11-06T13:54:46Z) reads `ERROR: failed to build: failed to solve: failed to parse stage name "ghcr.io/norandom/ousast-task-base:base-unpublished@": invalid reference format`. Compose had the same defect, closed in |
||
|
|
9d53c320a5 |
fix(contributor-scan): compose leaves the reports directory to the user (3.2, part 2)
On a fresh checkout the documented command, `TARGET=/path/to/repo docker compose run
--rm ousast scan /target`, died before scanning. The `/reports` mount was in the short
syntax, so Docker created a missing `./reports` as root, and the image runs as uid 1000.
On 2026-11-26, from a copy of the compose file at
|
||
|
|
8daca3df76 |
docs(plane-on-kubernetes): the pages that placed the plane in the kind cluster say it is stopped
By the maintainer's decisions of 2026-11-25 and 2026-11-26, recorded in the handover. The
question: "The local kind cluster is stopped since 2026-11-24, and three pages still say in
the present tense that the plane runs in it ... Fix them?" Answer: "One docs commit now", as
offered: "The statement step 3 made in the other pages: the cluster is stopped and its code
stays. The docs tests and a reviewer, as for step 3." Four smaller leftovers chosen in the
same menu are done here too: "Reword three link sentences", "Drop Today's in
deployment.md", "Note the proof on kind" and "Note the probe on kind".
The three pages: `docs/ops/ax/README.md` and `docs/where-we-stand.md` take the sentence of
`3a34929` ("That cluster is stopped since 2026-11-24: the code stays, `ops/ax/up.sh`
recreates the cluster, and whether the executor code is deleted is decided at the plane
re-plan"). `ops/ax/README.md` lines 3-4 are one sentence now, as the second menu decided,
and still two lines, because `docs/ops/ax/README.md` includes that page from its line 5.
For that reason the clause "`ousast plane run` submits, resumes, starts and collects" left
those two lines; it stays in the docs page's own paragraph.
The link sentences in `README.md`, `ops/README.md` and `docs/index.md` say what
`docs/deployment.md` holds, in the page's own words: how the plane was deployed on the
maintainer's host, and what moving it to a separate cluster would take. In
`docs/deployment.md`, "Today's EndpointSlice" is an undated statement about the kind
profile. Two dated notes say what waits for the cluster: the replay proof of 5.4 on kind,
and the kind half of the probe of task 3.2 in the parked search-with-proof spec.
Left alone, as decided: `ops/ax/README.md:20`; the rewrite of `ops/ax/README.md` and
`docs/ops/ax/README.md`, and k3s against kube-ax, wait for the plane re-plan.
Tests: the seven test files that read these pages (`test_docs_site.py`,
`test_removed_plane_references.py`, `test_plane_literals.py`, `test_plane_profile.py`,
`test_obligation_siblings.py`, `test_learn_experiments.py`, `test_config.py`): 113 passed
before and after the change. `git diff --check` is clean, and `mkdocs build --strict`
builds the site into a scratch directory. An independent reviewer approved the change in
one round; its remarks on the probe's kind half and on the style of the two notes are
applied.
Outside this commit, from the reviewer: `.kiro/specs/plane-on-kubernetes/tasks.md` has
"4.4 Kind proof and record 04", while `roadmap.md` places 4.4 on kube-ax.
|
||
|
|
a706a7d811 |
build(image): the app layers name the runtime user, so the chown layer is gone
By the maintainer's decision of 2026-11-25, recorded in the handover. The option as offered: "Drop the duplicate chown layer", as offered: "`COPY --chown` on the app file layers instead of a final `chown -R`. Every file under `/app` stays owned by uid 1000, compared file by file in the rebuilt image." `RUN chown -R ousast /app` ran after the last COPY, so it copied every file of `/app` into a second layer: 194 MB beside the 189 MB `benchmarks` layer in the local image, and the build of 2026-11-25 spent 311 of its 470 seconds in it. The line is removed, and the copies it covered take `--chown=1000` as `benchmarks` already did: `pyproject.toml`, `README.md` and `LICENSE` in one, `src` in the other. Nothing after the last COPY writes under `/app`: the pip install runs with the uv_build backend and left nothing there in the image built on 2026-11-25. Two things are expected to change besides the layer. `/app` itself, which `WORKDIR` creates, is owned by root, where `chown -R` made it uid 1000. And the files that were gid 0 take gid 1000. No tracked use writes into `/app` as the runtime user: compose runs in `/work` and writes under `/reports`, the wrapper `ops/ousast-docker` works in the mounted repository, and the workflows build and push. Tests: the new `tests/test_task_images.py::test_app_layers_carry_their_owner` fails on a `RUN chown` in the final stage and on a `COPY` into it that does not start with `COPY --chown=1000 `. It failed before the change (1 failed, 15 passed) and passes after; with `tests/test_search_image.py`, 17 passed. On scratch copies it fails when the chown line is put back and when the flag is dropped from `COPY src ./src`. `test_digest_required_and_code_last` found its code line by `COPY src `; it accepts the new prefix, and its ordering check is unchanged. ruff, mypy, the three gates and compileall pass, and the gates print what they printed before the change. An independent reviewer approved the change in one round. Not claimed here: the rebuilt image. It follows in this step's next part, with the proof that every file under `/app` is owned by uid 1000 and that `/app` holds the tracked files only. |
||
|
|
005bffb677 |
build(image): the image leaves the search pilot's git-ignored working files out
By the maintainer's decision of 2026-11-25, recorded in the handover. The option as offered: "One line in `.dockerignore` names `benchmarks/search/private/`, with a test that pins it. The local image then holds what a checkout holds." `.gitignore` ignores `benchmarks/search/private/`, where the feasibility pilot keeps its local identities and working files. `.dockerignore` did not, so `COPY --chown=1000 benchmarks` baked the directory of a local tree, 49,961 files, into the local image `openultrasast:dev`; nothing under it is tracked. A checkout has none of these files, so an image built from one never held them. Nothing under `src/` names the directory: the pilot scripts, `benchmarks/search/pilot_run.py` and `pilot_select.py`, run on the host and take the image under test as an argument. Tests: `tests/test_task_images.py::test_search_pilot_files_stay_out_of_the_image` pins the pattern, and that no `!` line with its exact prefix, with or without the trailing slash, lets it back in. It failed before the change (1 failed, 14 deselected) and passes after; with `tests/test_search_image.py`, 16 passed. On scratch copies the test fails when the line is removed, and when `!benchmarks/search/private` or `!benchmarks/search/private/` is appended. ruff, mypy, the three gates and compileall pass, and the gates print what they printed before the change. An independent reviewer approved the change in one round; its remark on the re-include check is applied. Not claimed here: the rebuilt image. It follows in this step's next part, with the check that the directory is absent from it. |
||
|
|
3a34929c55 |
docs(plane-on-kubernetes): the docs say the local kind cluster is stopped and its code stays
The maintainer decided on 2026-11-24: "The local kind cluster is stopped and the code stays. Whether the executor code is deleted is decided at the plane re-plan." |
||
|
|
91d305cd3c |
ci: keep the local .env out of the dagger upload
By the maintainer's decision of 2026-11-25, recorded in the handover: "dagger/ci.py syncs the
git-ignored .env into the local container when run locally, and step 9 runs that script locally
for the first time. I have not read how CI supplies what .env holds; that is checked first, so
CI keeps what it needs."
`.env` is the first entry of the exclude list of the one upload in dagger/ci.py,
`client.host().directory(".", exclude=[...])`. The script is CI's dagger job and the same
script run locally; the entry matches nothing in CI and removes the root `.env` of the tree
when the script runs on a machine that has one.
CI keeps what it needs, read before the change: `.github/workflows/ci.yml` (97 lines) sets two
literal variables (`UV_NO_SYNC`, `DAGGER_VERSION`), uses no `secrets.*` and no `vars.*`, and
has no step that creates or copies a `.env`; the container gets one variable, `UV_NO_SYNC=1`.
The names `.env.example` lists, the two API keys, the `VALID_BENCHMARK_*` S3 settings and the
two Discord values, are supplied by no workflow. A checkout has no `.env`, because the file is
git-ignored; `.env.example` is not matched and stays in the upload. No test reads a `.env` from
the tree.
That the pattern removes the root `.env` rests on reading, not on a run: the SDK passes the
list unchanged to the engine, whose filter matches a pattern without wildcards against the
whole relative path (the independent reviewer traced it at v0.21.7, the version CI pins, and
ran that filter over a scratch tree; no engine and no container was started).
Tests: the new tests/test_dagger_ci_upload.py parses dagger/ci.py as text, so it needs no
dagger engine, and asserts that the one exclude list holds `.env`. It failed before the change
(the list without the entry, 1 failed) and passes after; with the two test files that read the
workflow files, 16 passed. ruff, mypy, the three gates and compileall pass, and the gates print
what they printed before the change. An independent reviewer approved the change in one round;
its remarks on the wording of the comment and of the test, and on the failure message of the
test, are applied.
Left for the maintainer's menu, not decided: excluding `.env.*` files as well (a bare pattern
would also drop `.env.example`, which a test reads), an in-container check that fails the
pipeline if the file ever got in, and `__pycache__` directories, which a local run uploads.
|
||
|
|
8998697b4e |
fix(contributor-scan): the MCP server answers a tool that stops the CLI and stays up (3.1, follow-up)
By the maintainer's decision of 2026-11-25, recorded in the handover: "McpServer.handle catches Exception only, so a missing scan path raises SystemExit through it and ends the stdio loop; openultrasast.scan and openultrasast.benchmark both take that path. One bad call would become an error result for that call and the server would stay up." `McpServer.handle` in src/openultrasast/mcp.py catches `SystemExit` beside `Exception` and answers with the error it already builds for any exception a tool raises: `-32603` with `SystemExit: scan path is not a directory: <path>`. The stdio loop reads on, answers the next request and exits 0 at EOF; before, the process exited 1 with that message on stderr and nothing on stdout. `openultrasast.benchmark` takes the same clause when the manifest names a source path that does not exist. No other path changes: the notification return comes before the `try`, a line that does not parse is answered in `serve`, and `cli.py:588` is the only `SystemExit` a tool handler can reach (the independent reviewer's trace), raised before the configuration is loaded and before a run directory is created. "Error result" is read as that JSON-RPC error: the decision names `handle`, and the handover keeps this channel apart from `isError: true`, which `_call_tool` builds for `McpToolError`. A missing path therefore travels a different channel from a missing `path` argument or an unsupported mode; that is left for the maintainer's menu, with one pre-existing gap the reviewer found: a line that is valid JSON but not an object still ends the loop. Tests: through `serve`, a tools/call for `openultrasast.scan` with a missing path followed by a ping gives the error object and then the ping result, and `serve` returns 0; through `handle`, the same call gives that error object. Both failed on the code as it was, each with the `SystemExit` raised through the function it calls (the first in my run, the second in the reviewer's, on a copy of the code before the change); the second pins that the catch sits in `handle`, the public dispatch, where a catch in `serve` alone passes the first. The 23 test files around the scan path and the MCP server pass (242 passed before the second test was added, and `tests/test_mcp.py` 18 passed after); ruff, mypy, the three gates and compileall pass, and the gates print what they printed before the change. The real `ousast mcp` process, fed the same two lines, answered both and exited 0 with an empty stderr. An independent reviewer approved the change in one round and proposed the second test. |
||
|
|
09a9fcea96 |
docs(contributor-scan): the user docs name the skipped runs directory and its notice (3.1, follow-up)
By the maintainer's decision of 2026-11-25, as the handover records it: "One sentence in README.md and docs/examples.md, in its own docs commit: a scan does not read the files under its runs directory when it lies inside the scanned path. A notice chosen above would be documented in the same place." The sentence, the same in both files: "A scan does not read the files under its runs directory when that directory lies inside the scanned path; when this leaves source files out of the scan, `ousast` prints one `notice:` line naming the directory and how many." It closes the run-location paragraph of README.md and sits in the first paragraph of docs/examples.md, before the benchmark sentence. "when this leaves source files out of the scan" is the exact promise of `52c9afb`: the notice counts what the skip took out of the scan, so a source file that the target's root `.gitignore` or an ignored directory already keeps out brings none. "`ousast` prints" matches the retention sentence two lines up; `ousast scan` and `ousast benchmark` print the line, and the `openultrasast.scan` and `openultrasast.benchmark` tools return the same text among their notices instead (the independent reviewer's probes). The first clause keeps the maintainer's words: nothing under the runs directory becomes a file target, while the other readers of a scanned tree stay as they are by the decision "No, leave them"; a route manifest under the runs directory is still read. No code changes. The two documentation test files pass (8 passed). An independent reviewer approved the change in two rounds; its first round found that the first wording, "when source files are left out there", promised a notice for files the scan was not going to read anyway, which this wording closes. |
||
|
|
52c9afb85f |
feat(contributor-scan): a scan says how many source files it left out under its runs directory (3.1, follow-up)
`56c4620` made a scan skip its runs directory when it lies inside the scanned path, and said nothing about it. By the maintainer's decision of 2026-11-25, recorded in the handover, the scan now prints one notice. The decision, as the handover records it: "When source files lie under the runs directory inside the scanned path, the scan prints one notice: line naming the path and the number left out, the way run retention does." The line is `notice: skipped <n> source files under the runs directory <path>` (`source file` at one). `ousast scan` prints it, the `openultrasast.scan` tool returns it among its notices, and `openultrasast.benchmark` returns the notices of the scan it runs. Nothing is added to the manifest or the report. The count follows the scanned tree's own rules, so it is the number the skip took: a source file that the target's root `.gitignore` already keeps out, or that lies under a directory the scan ignores, brings no notice, and a `.gitignore` inside the runs directory does not hide what was left out. To that end `enumerate_source_files` in src/openultrasast/preprocess.py and the new `count_skipped_source_files` share one private predicate, `_is_read_as_source`. The enumeration returns the lists it returned before (the skip test now comes first, so a path under the skipped directory is no longer stat'ed). The count is taken after the preprocess stage, so a tree whose ignore file cannot be read stops the scan inside that stage, as before. It costs one more read of the target's root `.gitignore` and, where there is one, one more `git ls-files`, and only when the runs directory lies inside the scanned path. Nothing is said when no source file is left out, when the runs directory lies outside the scanned path, or when it is the target or lies above it. Tests: the notice tests failed on the code as it was (6 failed) and pass after the change. Four more failed on a first cut that counted by the runs directory's own `.gitignore` and pass on this one: a `.gitignore` inside the runs directory does not hide what the scan left out, nothing is left out where the target already ignores the runs directory, nothing under a directory the scan ignores, and a directory named `.gitignore` costs the scan nothing. The test that a target inside the runs directory is read as it was now also pins that nothing is said; a count that covered that target failed it. The 23 test files around the change pass (241 passed); ruff, mypy, the three gates and compileall pass, and the gates print what they printed before the change. An independent reviewer approved the change in two rounds. Its first round found the count by the wrong rules, which this cut closes. Its second round named two things that are left open and recorded in the handover: were the target's root `.gitignore` to become unreadable between the preprocess stage and the count, the scan would stop with no failed stage recorded in its trace and no manifest; and no test pins that a tracked source file under an ignored runs directory is counted. |
||
|
|
9a0b27e07b |
spec(contributor-scan): record the benchmark runs and the skipped runs directory under 3.1
The 3.1 task note gains two record paragraphs. `9e4983f` moved the benchmark runs beside the scan runs. `56c4620` made a scan skip its runs directory when it lies inside the scanned path: the maintainer's decision, as the handover records it, is quoted. Each paragraph closes the item the note of 2026-11-24 had marked "not yet done", and the older wording, "skip the cache when a scan meets a directory that contains it", is marked as overtaken by the decision, which names the runs directory only. The rest is labeled evidence on record: the skip applies only where the runs directory lies inside the scanned path (the reading the independent reviewer confirmed), it is silent, no run of this package keeps a source file today, and the counts of tests, lint and gates of `56c4620`. What is left for the maintainer is named as such and not decided: whether a scan should say when it left files out, whether a target inside the runs directory should be named, and a sentence for the user docs. No code changes. |
||
|
|
56c4620087 |
feat(contributor-scan): a scan skips its runs directory when it lies inside the scanned path (3.1, follow-up)
Since part A a native scan writes its run under the user cache or wherever `OPENULTRASAST_RUNS_DIR` points. A scan of a path that contains that directory, a home directory or a tree with the runs directory set inside it, took the files under it for source: those of earlier runs and those of its own run. On the code as it was, a source file under the runs directory inside the target was read and its finding reported (`file_targets=3 findings=2` for a tree of two files and one such copy). By the maintainer's decision, recorded as step 2c of the handover, the scan skips the runs directory only: `config.runs_dir`, the default location or the override. The other directories under `~/.cache/openultrasast` are read as before, and so is every tree whose runs directory lies outside it. `preprocess_repository` and `enumerate_source_files` in src/openultrasast/preprocess.py take a `skip` directory, and the preprocess stage of a scan (`_map_scan_targets` in cli.py) passes `Path(config.runs_dir)`. The skip applies only where the runs directory lies inside the scanned path: a target that is the runs directory or lies inside it is read as it was, so a runs directory set to `.` does not silence a scan. Both paths are compared resolved, so a symlinked or relative name is found, and the excluded path is built under the root as the walk spells it, so a relative root works too. Every other caller of the two functions passes no `skip` and is unchanged. No run of this package keeps a source file today (the independent reviewer's count: a quick run holds 15 files, all `.json`, `.jsonl`, `.md` or `.sarif`; the two benchmark runs in the real cache hold `.json` and `.toml`). The copy in the tests is a constructed case. Tests: four tests failed on the code as it was and pass after the change: the runs directory inside the scanned path, by the override, by the default location and by the override through a symlink, and the rest of the cache still read. Two more pin the narrow reading, a target that is the runs directory or lies inside it is read as it was; they failed on a first cut that skipped more than was decided. A direct call with a relative root pins the path comparison. The nine test files around the change pass (113 passed), as do the 37 files that exercise the scan path (362 passed); ruff, mypy, the three gates and compileall pass. Runs of the real CLI on one scratch subject, the code at HEAD against this tree: with the runs directory inside the target the copy under it is no longer read (`file_targets=4 findings=3` for five source files); with the runs directory a parent of the target, or the target itself, both read the same five files and report the same four findings. An independent reviewer approved the change in three rounds; its first round found that the first cut also silenced a scan whose target lay inside the runs directory, which this cut narrows to the decided case. |
||
|
|
9e4983f465 |
feat(contributor-scan): benchmark runs go beside the scan runs (3.1, follow-up)
`ousast benchmark` and its MCP twin wrote a run to `<target>/.openultrasast/benchmarks/<id>/`, into the scanned tree, and no user document said so. By the maintainer decision of 2026-11-24 a benchmark run now goes to `<runs_dir>/<benchmark-run-id>/`, beside the scan runs, where run retention removes it like a scan run. `create_benchmark_run` in src/openultrasast/benchmark.py takes the runs directory instead of the target. The two `_benchmark` functions, in cli.py and in mcp.py, load the configuration the way `_run_scan` does and pass `config.runs_dir`, so a benchmark run follows `OPENULTRASAST_RUNS_DIR` like the scan it runs. Both create the run once the scan has returned. Created first, as it was, the run was under the scan's own retention while the scan ran, and a scan that outlasted the retention window took it for an old one: the scoreboard could not be written and the scan outcome was never printed. A failed scan now also leaves no empty run behind. README.md and docs/examples.md name where a benchmark run goes. Tests: the three location assertions failed before the change and pass after it. A new test pins that retention removes a benchmark run like a scan run, and another that a benchmark keeps its run when its scan outlasts the retention window. The nine test files around the change pass (120 passed); ruff, mypy, the three gates and compileall pass. A run of the real CLI printed `run_dir=` and `benchmark_run_dir=` as siblings under the runs directory and left only the calibration ledger in the scanned tree. An independent reviewer approved the change in two rounds; its first round found the retention window, which this cut closes. |
||
|
|
78434a6e9f |
refactor(contributor-scan): split _run_scan into its stages (3.1, follow-up)
`_run_scan` in src/openultrasast/cli.py stood at a McCabe complexity of 18 and 124 logical lines, against the caps of 10 and 50 in .kiro/steering/code-standards.md. It is now 5 and 45 and reads as the stage sequence. The stages moved to six private helpers in the same module, in call order: _map_scan_targets, _collect_findings, _verify_and_fuse, _map_and_overlay, _add_obligation_and_model_findings and _run_map_stage. Two small records carry what crosses between them. _RunFiles names the ten artifacts a run writes, where the function kept ten path locals; _MapStage carries what the MAP stage hands to the reports, with the defaults of a scan that did not request that stage. The wrote_overlay flag is gone: the overlay is a list when the stage ran and None otherwise. No statement changed. What differs from the old function is where values live: the tool hunter's budget is read as config.hardening.max_findings, the fusion decisions come from their helper's return, and the reports and the manifest read the two records. Logical lines are counted the way the detection-core final gate counts them (the tokenize method). _main, _pre_push and _plane in the same file were already over the complexity cap and are not touched. Tests: the 38 test files that import the CLI or the MCP server pass (563 passed, 11 skipped); ruff, mypy and the three gates pass. Scans by the code before and after agree artifact for artifact: quick mode on a scratch copy of src and tests, and standard mode with defaults and with the scripted tool hunter under a budget of three findings. An independent reviewer approved the change in two rounds; its first round asked for the logical-lines cap, which this cut meets. The task note in .kiro/specs/contributor-scan/tasks.md records the split. |
||
|
|
61581f63b8 |
ci: raise the dagger job's timeout to 60 minutes
The limit of 20 minutes dates from
|