Skip to content

Round-2 review LOW findings follow-up (unleash-deterministic-tools) #743

Closed

Description

@jflowers

Deferred by maintainer decision during the unleash-deterministic-tools round-2 review council fix loop (artifact 8601976b-dae7-4250-92d4-ba2e68fdb0c1, 2026-10-16). HIGH + MEDIUM findings were fixed in iteration 2; these six LOW findings are deferred:

  1. pathspec magic on feature_dir (adversary run 0c6563e4): DetectResumeInputSchema.feature_dir reaches git status --porcelain -- <featureDir> without a check for leading-: git pathspec magic. Bounded blast radius (traversal guard holds; authoritative code-review completion is head-SHA equality). Fix: reject or escape leading : in the three feature_dir schemas.

  2. Tier value set enumerated 3 places (architect run e5abd9fe): UnleashTier (lib/unleash-templates.ts:27), WorkflowTier (index.ts:850), ExitTierSchema z.enum (index.ts:3076). Fix: follow the UNLEASH_EXIT_VARIANTS as-const single-sourcing pattern.

  3. unleash-summary artifact missing from docs scope (curator run 704e510f): docs issue docs: /uf.unleash deterministic-tool migration + /uf.finale unleash summary (Increment 2 of #716) #739 architecture.md scope row names tools + lib modules but not the .uf/artifacts/unleash-summary/<slug>.json contract. Fix: edit docs: /uf.unleash deterministic-tool migration + /uf.finale unleash summary (Increment 2 of #716) #739 scope row to name the artifact path, producer, consumer, camelCase shape.

  4. CHANGELOG completeness clause stale (guard run 16a15ccc): "Command markdown + Go/TS test updates only; scaffold mirrors byte-identical" understates the surface (review-dispatch refactor, plugin_activation.go, schemas READMEs). Fix: revise the clause.

  5. Clarification-marker grammar divergence (guard run 16a15ccc): CLARIFICATION_MARKER_PREFIX (bare marker matches) vs CLARIFICATION_MARKER_PATTERN (colon form required) — a bare hand-written marker trips detect_resume forever while scan_clarifications sees 0. Fix: make the extractor handle the superset (bare forms as unscoped questions).

  6. review-dispatch-artifact parser type-guards untested (testing run 6f909849): no dedicated unit test for parseReviewDispatchArtifact type-guard branches (non-record context/payload, non-string mode/verdict/branch/headSha, NaN timestamp). Fix: add .opencode/test/review-dispatch-artifact.test.ts.

Related deferred follow-ups from round 1: #741 (plugin index decomposition), #742 (epic blog post).

Activity

  1. added
    refactor
    on Oct 16, 2026
  2. jflowers commented on Oct 17, 2026

    @jflowers
    ContributorAuthor

    Status update after the PR #745 round-5 review fix loop (opsx/unleash-deterministic-tools):

    1. pathspec magic on feature_dir — Addressed. All three feature_dir schemas (DetectResumeInputSchema, ScanClarificationsInputSchema, ResolveClarificationInputSchema) now reject a leading : with INVALID_INPUT before any read or git call; regression tests pin the message (must not start with ':' (git pathspec magic)) and that no side effects run.

    2. Tier value set enumerated 3 places — Stale. The recommended as-const single-sourcing already exists: UnleashTier (lib/unleash-templates.ts:32), WorkflowTier (index.ts:840), and ExitTierSchema = z.enum(WORKFLOW_TIERS) (index.ts:3124) all derive from the one WORKFLOW_TIERS tuple. The finding's premise (three independent enumerations) no longer holds.

    3. unleash-summary artifact missing from docs scope — Addressed. docs: /uf.unleash deterministic-tool migration + /uf.finale unleash summary (Increment 2 of #716) #739's architecture.md scope row now names the .uf/artifacts/unleash-summary/<slug>.json contract: producer write_unleash_summary (uf-workflow), consumer uf_finale_pr_context (uf-finale), camelCase body {change_name, tier, feature_dir, review_verdicts, learnings_stored, whatWasBuilt, howToVerify, testResults}, and the 3 lib modules the plugin composes.

    4. CHANGELOG completeness clause stale — Addressed. The clause now states the fail-closed tool contract end to end: shared input glue (parseToolInput/resolveToolParam/failureFromError), pathspec-magic rejection, *_ERROR envelopes for unexpected failures with per-path catch-all regression tests, Step 2/3/5 delegation pins, and staged lib-module lockstep (content, tool-ownership, Divisor staging).

    5. Clarification-marker grammar divergence — Remains deferred by maintainer decision (PR feat(workflow): migrate deterministic uf.unleash procedures to plugin tools #745 round-5 finding F rejected citing this deferral).

    6. review-dispatch-artifact parser type-guards untested — Addressed. .opencode/test/review-dispatch-artifact.test.ts covers the valid parse plus every type-guard branch: malformed JSON, non-record roots, foreign artifact_type, non-record context/payload/input_context, non-string mode/verdict/branch/head_sha, and missing/unparseable timestamps sorting oldest (writtenAt 0).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    refactor

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions