Skip to content

test(id): add generated property coverage for settled-role tag-clear authorization (grouped histories) #6193

Closed

Description

@dezren39

Finding (from PR review)

Codex (chatgpt-codex-connector[bot]) raised this finding in its review of merged PR #5657 and it was never fixed or responded to:

  • PR: id: make tag.clear role-aware in the default view #5657 — "id: make tag.clear role-aware in the default view" (MERGED 2026-11-04T21:23:11Z, merge commit e4777f1)
  • Comment: id: make tag.clear role-aware in the default view #5657 (comment) (chatgpt-codex-connector[bot], 2026-11-04T21:25:31Z, P1, anchored at pkgs/id/tests/tag_clear_authority.rs:162; reviewed head b4b151c — the review was submitted just after the merge, so no in-PR fix was possible)
  • Essence: "Add generated coverage for settled-role authorization. The new grouped-subject authorization path is covered only by fixed examples. The updated property test in tag_claims.rs still generates only missing, ungrouped subjects, so its oracle never exercises owning-group selection or settled Admin membership. Add generated grouped histories checked against an independent authorization model, including different owning groups and membership changes; otherwise the central role-aware invariant remains outside the property/model coverage explicitly required by the repository's testing doctrine." (Codex cites the repo AGENTS.md testing-doctrine lines 41–45.)

No-response evidence

Still live on current main (verified 2026-11-05 by two independent gh api raw reads, main 4b41b86)

pkgs/id/tests/tag_claims.rs:

  • The history generator used by both proptest! blocks (lines 453 and 483) builds every subject event with group: None (generator sites at lines 73, 260, 271), and the module documents the property oracle as the ungrouped rule (line 312: "only the claim author may clear these ungrouped test subjects").
  • So the generated histories never exercise owning-group selection or settled Admin membership — the exact path PR id: make tag.clear role-aware in the default view #5657 added in pkgs/id/src/event_store/claims.rs (default_view_events, which resolves the subject's owning group and checks the settled projection for GroupRole::Admin).

pkgs/id/tests/tag_clear_authority.rs (227 lines) covers the grouped path only with fixed examples: a settled group Admin clearing another author's tag (line ~159), a non-member clearer (line ~167), and an Admin with no authority for ungrouped/missing subjects (line ~184). No generated histories, no membership changes, no multiple owning groups.

Acceptance criteria

  • Generated (property-based) grouped histories for tag-clear authorization: subjects owned by different groups, clearers with author / settled-Admin / non-member / removed-member roles, and membership changes mid-history, checked against an independent authorization model (the oracle), per the repo's PBT/MBT testing doctrine.
  • The new coverage fails if the grouped authorization path in default_view_events is broken (e.g. Admin check dropped or group selection bypassed) — demonstrate by mutation or by a recorded counterexample check.
  • Or: the finding is resolved on this issue by a documented decision with reasoning recorded (e.g. an argued case that the fixed examples plus other suites already bound the risk acceptably).

Activity

  1. added
    kind/testTest coverage, test infrastructure, or test-only fixes
    task/triageQueue packet kind: verify, reproduce, and route this item
    priority/normalOrdinary priority (the default)
    on Nov 5, 2026
  2. developing-today commented on Nov 5, 2026

    @developing-today
    Contributor
  3. added
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    on Nov 5, 2026
  4. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · state: filed

  5. added
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    and removed on Nov 5, 2026
  6. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · handed off

  7. 209 remaining items

  8. dezren39 commented on Nov 6, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · picked up

  9. dezren39 commented on Nov 6, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · done (PR opened)

  10. dezren39 commented on Nov 8, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    event: picked_up
    task: 13335
    worker: repo-worker-code
    lane: 7b47536b-c162-444c-be8a-3a9538cc4cb5
    verified: Fresh GitHub revalidation: PR #6573 is OPEN at head 198419e and authored by dezren39 (Drew); linked issue #6193 is OPEN and assigned to dezren39. The packet says the PR is unowned, which conflicts with both live ownership signals. PR labels include queue/parked, status/parked, work/assigned from the earlier handoff. No PR changes made.
    next: Block this task as escalated-to-user; require explicit Drew ownership handoff/authorization before any PR modification, merge, or close.

  11. added
    queue/blockedQueue or user escalation state
    status/blockedQueue or user escalation state
    user/escalatedRequires a Drew decision or access
    and removed on Nov 8, 2026
  12. dezren39 commented on Nov 8, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    event: blocked
    task: 13335 (pr_shepherd, repo-health-code-pilot)
    worker: repo-worker-code
    lane: 7b47536b-c162-444c-be8a-3a9538cc4cb5
    at: 2026-11-08T18:44Z
    blocker: The packet says PR #6573 is unowned, but fresh GitHub state shows the PR is authored by dezren39 (Drew) and this linked issue is assigned to dezren39. Under the no-touch rule for Drew-owned PRs, this lane will not modify, merge, or close PR #6573. Require explicit Drew ownership handoff/authorization. The task was blocked as escalated-to-user; the packet ownership assertion is stale.
    labels: user/escalated, queue/blocked, status/blocked. No changes were made to the PR or its labels. Current PR checks also include failures; no merge attempted.

  13. dezren39 commented on Nov 11, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · done (triage reconciliation)

    • Agent: repo-worker-code, OpenChamber scheduled lane ec118cad-0fd3-4652-91c4-27432f2f2efd
    • Session / ID: task 9993
    • Found via: queue claim; prior triage had already confirmed the gap and routed fix task 11226 (issue comment 6690108821).
    • Outcome: completed the stale triage task; PR test(id): generated grouped/settled-Admin property coverage for tag-clear authorization (#6193) #6573 and its separately blocked shepherd task 13335 remain untouched. Existing blocked/escalated labels belong to that separate work and are preserved.
  14. dezren39 commented on Nov 11, 2026

    @dezren39
    MemberAuthor

    Agent note — lane tmp-code-g, task 14843 — state: triaged

  15. added a commit that references this issue on Nov 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)kind/testTest coverage, test infrastructure, or test-only fixespriority/normalOrdinary priority (the default)queue/blockedQueue or user escalation statesource/pr-comment-reviewFiled by the pr-comment-review jobstatus/blockedQueue or user escalation statestatus:donetask/triageQueue packet kind: verify, reproduce, and route this itemuser/escalatedRequires a Drew decision or access

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions