Skip to content

skills: objectstack-api still teaches that DELETE is unrecoverable and that there is no recycle bin (#30237, ADR-0148) #30847

Closed

Description

@objectstack-fleet

domain:server#1 · os-elon-musk · session_016WV4cytLmJxfAmgPVjUbbW

Filing gate: the Skills-docs: follow-up owed line that every PR of #30237 carries (seat plan, PR 1 = #30780, merged as 25e1c1ad8b). ⛔ Not a claim.

Business reason. Since PR #30780, a by-id delete keeps the deleted rows in the recycle bin (sys_recycle_bin, ADR-0148). Later PRs of #30237 add purge and empty, restore, the allowRestoreOwnDeleted / manageRecycleBin permissions, and the REST doors. skills/objectstack-api/SKILL.md still teaches the opposite in two places:

  • About line 268: "restore / purge never derive — the trash surface is retired."
  • About line 417, the pitfall "Assuming DELETE is recoverable": "ObjectStack DELETE is a hard delete — there is no recycle bin". It points agents at trackHistory or a lifecycle archive instead.

An agent that follows the skill will build its own soft-delete, or tell a user that a deleted record is gone when an administrator can restore it.

Wanted. Rewrite both passages from main as it stands when this card is picked up:

  • what a delete keeps;
  • who may restore or purge, and with which permission;
  • which door to call;
  • what is forward-only (rows deleted before the bin existed are not in it).

Do not teach a door that has not landed. Keep each passage within its current length budget. It owes '@objectstack/skills': patch.

Serial: after #30237's restore and REST-door PRs (its PRs 3 and 5) land, so the skill can name a real door. Until then the card waits; pick it up early only to correct the "there is no recycle bin" sentence.

Reader: domain:skills (skills/**). Suggested-grade: p2 · a skill that contradicts shipped behaviour.

Activity

  1. objectstack-fleet commented on Nov 6, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U

    Path: none

    Triage: audit · p2 · domain:skills · 2026-11-06T06:53Z

    ⛔ Not a claim.


    Generated by Claude Code

  2. added
    documentationImprovements or additions to documentation
    domain:skillsDomain lane — seat card indexed by label:pm:seat
    pm:queueReady for the PM dispatch loop
    pm:dispatchedDispatched to a dev agent by /pm-dispatch
    and removed
    pm:queueReady for the PM dispatch loop
    on Nov 6, 2026
  3. objectstack-fleet commented on Nov 6, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

    Claim: PM loop round 1 · 2026-11-06T14:58Z · partial (the correction the triage audit asks for now)
    Session: session_01J8VVAj7CvjkGXvgXzd6RZ7
    Account: huangyiirene
    Branch: claude/project-thread-zyyxri (the card thread's designated branch; dev session session_01J8VVAnsTJVz6nCb7n8NUJs)
    Worktree: objectstack-issue-30847
    Domain: domain:skills
    Seat: domain:skills#3
    File surface: skills/objectstack-api/SKILL.md, only L47 ("hard delete"), the restore / purge sentence near L268 and the pitfall near L417 ("there is no recycle bin"); .changeset/*.md (stop on breach)
    Container & model: S, mode:thread, model Opus, effort: medium. dispatch-gates --tier reads MANDATORY contract-review tier (clause ①, skills/**); waived by the maintainer's standing order in this project (2026-11-03) and said so in the PR body; this seat runs the contract review.
    Clause-②: no
    Metadata-protocol: none
    Responsibility: n/a — teaching-text defect: the skill contradicts PR #30780 (a by-id delete keeps its rows in sys_recycle_bin, ADR-0148); objectstack carries the fix
    Thread-read: 6679098621
    Premise: holds on main 256a4b725: SKILL.md L47 says "hard delete", ≈L268 says the trash surface is retired, ≈L417 says "there is no recycle bin".
    Serial constraints cleared: PR #30844 (seat 2) edits the same SKILL.md (the ?names= filter) and is in the merge queue; seat 2's Notify: serial 6687759447 read. The thread merges main after #30844 lands, before opening its PR.

    Scope: the PR says Refs #30847, never Fixes. The restore / purge door teaching stays owed until #30237's restore and REST-door PRs land; at merge this seat releases the card with Blocked-by: #30237. Changeset owed: '@objectstack/skills': patch, never skip-changeset. Tier H.

  4. objectstack-fleet commented on Nov 6, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

    Claim widened (contract review FAIL on PR #30994, must-fix M1) · 2026-11-06T16:14Z

    File surface, added (stop on breach): skills/objectstack-api/evals/endpoints-auth-routes.json, case id 5 only (the "undelete invoices" prompt): its expected_output and its must_contain tokens trackHistory and lifecycle, which still grade the old "DELETE is a hard delete" teaching. 'restore' stays in must_not_contain. The eval ships in @objectstack/skills, so the corrected SKILL.md must not ship beside it. Same card, same patch changeset.

  5. objectstack-fleet commented on Nov 6, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

    ACCEPT → PR #30994 comment 6690169452

    Tier H: awaiting an approval from os-zhuang or hotlong (requested). This PR is the immediate-correction half (Refs); at merge this card returns to the queue with Blocked-by: #30237 for the restore-door teaching.

  6. objectstack-fleet commented on Nov 6, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

    Released · 2026-11-06T18:03Z · partial landed: PR #30994 (Refs #30847) merged. The skill now teaches that a by-id delete keeps business-object rows in the recycle bin (sys_recycle_bin) and that nothing lists or restores them over the API yet. Still owed here: the restore / purge door, permission and REST-route teaching, once #30237's restore and REST-door PRs land. Moved pm:dispatched → pm:blocked, assignee cleared.

    Blocked-by: #30237

  7. added
    pm:blockedBlocked by another issue/PR — body carries Blocked-by: #N
    and removed
    pm:dispatchedDispatched to a dev agent by /pm-dispatch
    on Nov 6, 2026
  8. objectstack-fleet commented on Nov 9, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U

    Path: none

    Triage: unblocked · pm:blocked → pm:queue · 2026-11-09T02:15Z

    ⛔ Not a claim.


    Generated by Claude Code

  9. added
    pm:queueReady for the PM dispatch loop
    pm:dispatchedDispatched to a dev agent by /pm-dispatch
    and removed
    pm:blockedBlocked by another issue/PR — body carries Blocked-by: #N
    pm:queueReady for the PM dispatch loop
    on Nov 9, 2026
  10. objectstack-fleet commented on Nov 9, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · zhuangjianguo · session_01QsR2jULfPnqQFGcZUtKDFH

    Claim: PM loop round 1 · 2026-11-09T02:58Z · the restore/purge half (PR #30994 landed the first half)
    Session: session_01QsR2jULfPnqQFGcZUtKDFH
    Account: zhuangjianguo (the seat's linked user; the card's assignee)
    Branch: claude/project-thread-3lyy7q (the card thread's designated branch, a measured platform exception to claude/issue-N-slug; dev session session_01QsR2jTbKfNKjrN2RAefJDH)
    Worktree: objectstack-issue-30847
    Domain: domain:skills
    Seat: domain:skills#3
    File surface: skills/objectstack-api/SKILL.md, skills/objectstack-api/rules/*.md and references/*.md only where the restore teaching already lives, skills/objectstack-api/evals/*.json (cases the rewrite breaks), one new .changeset file (stop on breach; explain in the report)
    Container & model: S, mode:thread, model: opus — dispatch-gates --tier skills/** mandates claude-fable-5-1; this build runs on Opus under the no-Fable-build exit (maintainer 「后续不再派 fable 卡」), and the contract review runs on the lane's isolated Fable reviewer. skills/** is Tier H: draft for a governed approver. effort: medium
    Clause-②: no
    Metadata-protocol: none
    Changeset · PR body: '@objectstack/skills': patch · Fixes #30847
    Responsibility: n/a — teaching-text defect: the skill says the recycle bin has no restore or purge door, which #30237 shipped (ADR-0148)
    Thread-read: 6730635071
    Premise: holds on main 9e1f1f9. skills/objectstack-api/SKILL.md L271-272 says "the recycle bin has no restore or purge door yet" and L412-414 says "nothing lists or restores it over the API yet". The live tree has restore, purge and list in packages/objectql/src/recycle-bin/, the allowRestoreOwnDeleted / manageRecycleBin grants, and POST /data/:object/recycle-bin/:entryId/restore in protocol.zod.ts. #30237 is closed.
    Serial constraints cleared: no open PR touches skills/objectstack-api/**. Seat 2's split (Notify 6730938517 on #31401) leaves this card to seat 3.

    Dispatch order: the card thread's opening message (common rules + order-30847.md, from the seat folder skills-seat-3/ of the project files). Writes: PR only via relay pr_create; comments, labels and bodies only via scripts/pm write tools; no GitHub MCP writes.

  11. objectstack-fleet commented on Nov 9, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · zhuangjianguo · session_01QsR2jTbKfNKjrN2RAefJDH
    os-dev-report

    {
      "issue": 30847,
      "status": "done",
      "branch": "claude/project-thread-3lyy7q",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/31769",
      "head": "4efbaef8",
      "session": "session_01QsR2jTbKfNKjrN2RAefJDH",
      "premise_still_valid": true,
      "gates": "dispatch-gates --commands on 7d3edcd4: 46 derived; 45 exit 0; pnpm check:dual-build-cjs-loads exit 3 (PREREQUISITE NOT MET, NOT MEASURED, left to CI); --ran: 46 accounted, 45 run, 1 NOT-MEASURED. Not derived, run by hand: pnpm --filter @objectstack/spec run check:skill-examples exit 0 (332 blocks). Merge of origin/main (6 commits, none touching this diff) -> 4efbaef8; check-skills-token-ratchet re-run exit 0. PR body gates (changeset-no-major, adr-0087-registration, closing-keyword-parity, partof-closing-keyword): exit 0.",
      "token_budget": {
        "skills/objectstack-api/SKILL.md": "5157 -> 5157 tokens (ceiling 6314); 20646 -> 20646 bytes; 441 -> 441 lines",
        "skills/objectstack-api/evals/endpoints-auth-routes.json": "6129 -> 6454 bytes (eval fixture, measured not ratcheted)",
        "pack_all_SKILL_md_lines": "4599 -> 4599"
      },
      "passages_rewritten": [
        "skills/objectstack-api/SKILL.md:269-271 restore/purge derive from delete (was: never derive, no door)",
        "skills/objectstack-api/SKILL.md:405-414 pitfall 2: keeps, recycleBinEntryId, four doors, two grants, four 409 RESTORE_* codes (was: nothing lists or restores)"
      ],
      "byte_payment_cuts": [
        "L55 'aggregation through the query one' survives: Derived operations table row aggregate",
        "L58-59 'authorable values are the six primitives' survives: API Methods opening sentence",
        "L240 'Always prefix with /api/v1/' survives: every Endpoint Naming Conventions row",
        "Auth Configuration D6 cross-ref title shortened survives: section authRequired and the D6 pairing",
        "Best Practice 3 least-privilege auth survives: Auth Configuration public + permissions pair",
        "Realtime 'pointer-style, read the spec source' survives: References 'Always Read the source'"
      ],
      "doors_named": [
        "POST /data/:object/recycle-bin/:entryId/restore, GET and DELETE /data/:object/recycle-bin, DELETE /data/:object/recycle-bin/:entryId: packages/rest/src/recycle-bin-routes.ts",
        "recycleBinEntryId on the delete answer and the restore path: packages/spec/src/api/protocol.zod.ts",
        "allowRestoreOwnDeleted / manageRecycleBin gates: packages/objectql/src/recycle-bin/restore.ts, list.ts, purge.ts; packages/core/src/security/effective-object-permissions.ts GRANT_BITS",
        "restore/purge derive from delete: packages/spec/src/data/api-derivation.ts API_METHOD_DERIVATION",
        "30-day default retention: packages/objectql/src/recycle-bin/retention.ts",
        "RECYCLE_BIN_RESTORE_REFUSAL_CODES, status 409: packages/spec/src/data/recycle-bin.zod.ts"
      ],
      "eval_cases_changed": [
        "endpoints-auth-routes.json id 5: expected_output rewritten; must_contain 'recycle bin' -> '/recycle-bin/'; must_not_contain + 'nothing lists or restores'"
      ],
      "deviations": [
        "must_not_contain keeps 'restore' (quoted literal): it still guards declaring a derived verb in apiMethods, which the new teaching still forbids; the order read it as contradicting the new teaching",
        "model: dispatch-gates --tier mandates the contract-review model for skills/**; built on default tier under the no-Fable-build exit",
        "test:repo and dogfood not run: teaching text only, no package source moves"
      ],
      "files_changed": [
        ".changeset/30847-api-skill-recycle-bin-doors.md",
        "skills/objectstack-api/SKILL.md",
        "skills/objectstack-api/evals/endpoints-auth-routes.json"
      ],
      "api_writes": "2 relay writes: pr_create (#31769), this comment; plus git push x2",
      "mcp_calls": "3 GitHub MCP reads: issue_read get x1, issue_read get_comments x2; no write tool",
      "security_findings": "none",
      "out_of_scope_findings": []
    }
  12. objectstack-fleet commented on Nov 9, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:skills#3 · zhuangjianguo · session_01QsR2jULfPnqQFGcZUtKDFH

    Landed · 2026-11-09T04:20Z — PR #31769 merged through the merge queue (merge commit 630a0baa68), after os-zhuang approved head f1508341. This is the second half of the card; the first half landed as #30994. The api skill now teaches that restore and purge derive from delete, the four recycle-bin doors, the two grants, recycleBinEntryId, and the four 409 RESTORE_* codes. Eval case 5 grades recycle-bin. Left as a possible follow-up: the cut Best Practice 3 "least-privilege auth" rule (review F2). Fixes closed the card; pm:dispatched is removed in the same act.

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

Metadata

Metadata

Assignees

Labels

documentationImprovements or additions to documentationdomain:skillsDomain lane — seat card indexed by label:pm:seatpriority:p2Medium: important, M3

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions