Skip to content

service-automation: the inbound hook door accepts a post for a disabled holder's flow slot whose queued run is then skipped (measure what the sender is told) #33906

Closed

Description

@objectstack-fleet

domain:server#5 · zhuangjianguo · session_01QsR2jUZKdq3PK2Sab53cT3

Follow-up (c) of PR #33890 (#33748), from review-c's contract record 6895266928 / verdict 6895274667. Measure first.

维护者速读

What

Dedupe words: inbound hook disabled holder admitted never runs.


Generated by Claude Code

Activity

  1. added
    pm:queue
    domain:server
    on Nov 15, 2026
  2. objectstack-fleet commented on Nov 15, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · zhuangjianguo · session_01QsR2jUZKdq3PK2Sab53cT3

    Measurement · #33906 · the inbound hook door for a disabled holder's armed slot · 2026-11-15T15:56Z

    Measure-only (no branch, no PR). The rig was the real SchemaRegistry (com.acme.alpha ns alpha, com.acme.beta ns beta), the real AutomationEngine + flowNameResolver, and the real ApiTriggerPlugin on a LiteKernel with Hono. Two faces were driven: self-hosted POST /api/v1/automation/hooks[/:ns]/:flow/:hookId and runtime handleInboundHookRequest. Each post was signed (v1 timestamped) and the queue was drained into the armed callback. Readings were taken on origin/main 895783a1 and with PR #33890's engine.ts (blob a1b58d91), and the file was restored afterwards (blob = HEAD, git diff HEAD empty).

    state address main 895783a with #33890
    two holders, alpha disabled, slots armed alpha/t 202 accepted, alpha's flow runs (run row) 202 accepted, enqueued, run skipped (no run row, info once)
    same beta/t 202, beta runs 202, beta runs
    same bare t 401 INVALID_SIGNATURE (shared-name) same
    both disabled, armed alpha/t, beta/t 202, both run 202, neither runs
    sole holder disabled, armed alpha/solo, solo 202, runs 202, runs (#33905's subject)
    after re-sync withdrawFlowSlot(alpha) alpha/t 401 (unadmitted-address) same
    same beta/t (served!) 401 (unknown-flow): served holder's hook unarmed same (#33893's subject)
    nothing disabled (CONTROL) all qualified 202 + own body; bare shared 401 identical

    Result: with #33890, the door answers 202 "accepted" to a post that never runs. The armed-but-disabled state is reached when the disable announce or the re-sync's protocol read fails, or when a disable comes with no announce (enableOnInstall:false, a direct registry.disablePackage). #33890 itself pins that premise. After a successful re-sync, the same address gets the door's one 401. The full PATCH-disable stack through a booted app was NOT MEASURED; the reading of that path comes from the code.

    Pins: no test pins the hook door's answer for a disabled holder. flow-triggers-per-slot.test.ts:198-210 pins a slot that is toggled off, not a package disable, and option A below leaves it as it is.

    Options, in the dev's four-axis analysis:

    • A (dev's recommendation): inboundHookSlot leaves out a slot whose registry-held package is disabled. That address then gets the door's existing one 401, after the full body is read, the same bytes as the re-synced state. About 10 source lines plus pins. This is served→refused: !, BREAKING, an ADR-0087 marker, dogfood, Clause-②: no (narrowing). It lands after fix(service-automation)!: a trigger binding does not dispatch a slot whose package is disabled (ADR-0150 D3) #33890 (reuses isDisabledHolderSlot). Skills follow-up owed: skills/objectstack-automation/SKILL.md:383-395.
    • B: keep the 202 and add a warn per post. The silent drop stays on the wire.
    • C: 503 + Retry-After answered only to a verified post. This is a new answer arm on the door contract, and no measured pull asks for it.

    Out of scope, noted: the bare hook of a shared name with one served holder stays 401 shared-name (#33646's "Not moved" design question).


    Generated by Claude Code

  3. objectstack-fleet commented on Nov 15, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · zhuangjianguo · session_01QsR2jUZKdq3PK2Sab53cT3

    Seat ruling recorded · #33906 · option A · 2026-11-15T17:31Z

    Ruling (seat domain:server#5, seat thread): the anonymous inbound hook refuses an address whose slot belongs to a registry-held package that is disabled, using the door's existing one 401. AutomationEngine.inboundHookSlot leaves out such a slot (the isDisabledHolderSlot reading of PR #33890), so both faces answer 401 INVALID_SIGNATURE after the body is read in full, with the cause logged and never sent: the same bytes as after a re-sync. No maintainer card: this is not a new rule. It is seat ruling 6884403301 applied to the one door that ruling did not name. Amendment 2: an explicit address naming the disabled package is refused. Amendment 3: a disabled package's slot gets no flow, no dispatch, and is never substituted. Amendment 8: admission is judged on the same resolved slot that executes. ADR-0150 D5 gives this door one refusal. An isolated Fable review (/mnt/project-files/server-seat-5/fable-review-batch-1115b.md, #33906 section, HOLD = seat-level) confirmed the premise at engine.ts ~L5954 / ~L5336 / ~L4443.

    Correction to the measurement comment 6897225218: GitHub does not retry failed webhook deliveries on its own (it keeps them for manual redelivery). The accurate statement is "senders that retry on a non-2xx keep the event and can redeliver after a re-enable".

    The build:

    Prior rulings read: 6884403301 amendments 2, 3, 7, 8, 9; PR #33646 "Not moved: the anonymous inbound hook"; ADR-0150 D5; ADR-0041 §5; ADR-0138 D2; PR #33890 Acceptance notes. No ⛔ conflict.


    Generated by Claude Code

  4. objectstack-fleet commented on Nov 15, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · zhuangjianguo · session_01QsR2jUZKdq3PK2Sab53cT3

    Regrade p3 → p2 on the seat's instruction (seat thread): a silent event loss at a public door (202 accepted, run skipped) meets p2. Built standalone by area S6 after PR #34048 is queued. · 2026-11-15T17:31Z


    Generated by Claude Code

  5. added
    priority:p2
    and removed on Nov 15, 2026
  6. objectstack-fleet commented on Nov 15, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · zhuangjianguo · session_01QsR2jUZKdq3PK2Sab53cT3

    Claim: server area-lease mode (#33751 §2), area S6 lease A5, dispatched by seat domain:server#5 area thread · executed by an os-dev sub-agent (mode:subagent) · posted at 2026-11-15T23:54Z
    Session: session_01QsR2jUZKdq3PK2Sab53cT3
    Account: zhuangjianguo
    Branch: claude/area-A5b-33906
    Worktree: objectstack-issue-33906
    Domain: domain:server
    Seat: domain:server#5
    File surface: packages/services/service-automation/src/engine.ts (inboundHookSlot leaves out a slot whose registry-held package is disabled, via isDisabledHolderSlot); the inbound hook route only if the 401 face needs it to log the cause; a new test file named by the card; a major-marked changeset with the ADR-0087 marker (stop on breach; explain in the report)
    Container & model: S, mode:subagent, model: default (no path-derived mandate), effort: high
    Clause-②: no (narrowing)
    Metadata-protocol: none
    Skills-docs: follow-up owed — skills/objectstack-automation/SKILL.md:383-395 (the area files that card)
    Responsibility: objectstack service-automation: the anonymous inbound hook answers 202 for a disabled holder's flow slot and the queued run is then skipped, a silent event loss | served holders, nothing disabled, a toggled-off slot | every package-held flow with an inbound hook whose package is disabled
    Thread-read: 6898449441
    Premise: holds (measurement 6897225218, corrected in 6898449441; Fable review fable-review-batch-1115b.md #33906 section)
    Route: seat ruling A (6898449441): the door's existing one 401 INVALID_SIGNATURE on both faces after the body is read in full, cause logged and never sent; nothing enqueued; re-enable answers 202 again with no re-arm.
    Serial constraints cleared: lands after PR #34048 (#33893+#33905, isDisabledHolderSlot judges a name one package holds); built from origin/main once #34048 merged, or from its branch with a main merge before push.
    Pre-claim lane: server because packages/services/service-automation/src/engine.ts
    Pre-claim deps: PR #34048 (S6, landing now).
    Prior rulings read: seat ruling 6884403301 amendments 2, 3, 7, 8, 9; PR #33646 "Not moved: the anonymous inbound hook"; ADR-0150 D5; ADR-0041 §5; ADR-0138 D2; PR #33890 Acceptance notes. No ⛔ conflict.


    Generated by Claude Code

  7. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 15, 2026
  8. objectstack-fleet commented on Nov 16, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · zhuangjianguo · session_01QsR2jUZKdq3PK2Sab53cT3
    os-dev-report

    {
      "issue": 33906,
      "status": "done",
      "branch": "claude/area-A5b-33906",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/34278",
      "pr_head": "84e37cab",
      "session": "session_01QsR2jUZKdq3PK2Sab53cT3",
      "premise_still_valid": true,
      "summary": "Built seat ruling A (6898449441). AutomationEngine.inboundHookSlot now answers `unadmitted` for a slot whose registry-held package is disabled (isDisabledHolderSlot): on a shared name it is judged after the qualified address picks its slot, so no other holder is substituted; on a name one package holds, every address of a disabled sole holder, the bare one included. Both faces then answer the door's existing one 401 INVALID_SIGNATURE after the body is read in full, byte-identical to the post-re-sync answer, with nothing enqueued; the engine logs the cause at info (cause 'disabled-holder', flow, package, slot), never sent. Asked at post time, so a re-enable answers 202 with no re-arm. No door file changed. The branch was cut from claude/area-A5b-33893 while #34048 was open; #34048 merged as 44fc2fc4 and origin/main was merged in twice before the PR opened (44fc2fc4 is an ancestor of the head).",
      "tests": "Head 84e37cab. New packages/qa/dogfood/test/inbound-hook-disabled-holder-33906.test.ts: real AutomationEngine from AutomationServicePlugin.init() (the plugin's own flowNameResolver), real SchemaRegistry, real ApiTriggerPlugin (self-hosted mount and trigger-api member), real runtime HttpDispatcher (the hosted face). `vitest run --project isolated test/inbound-hook-disabled-holder-33906.test.ts`: Test Files 1 passed, Tests 6 passed. Pins: co-holder disabled, qualified address gets 401 on both faces, byte-identical to inboundHookRefusalResponse() and to the answer after withdrawFlowSlot, 0 enqueued, 0 run, cause in the log only; both holders disabled, same; sole holder disabled, qualified and bare addresses, same, byte-identical after the re-sync; re-enable gives 202 and a run, with trigger bindings and queue subscriptions unchanged (no re-arm); CONTROL nothing disabled, 202 everywhere; CONTROL served co-holder, 202. `pnpm --filter @objectstack/service-automation test`: Test Files 284 passed, Tests 4040 passed (flow-triggers-per-slot.test.ts:198-210 untouched, green); typecheck exit 0. Ablation, taken at aa16cc6e with the same engine hunk: each leave-out made inert through ablation-replace.mjs (anchor 1 to 0, blob checked), rebuilt, and ablation-dist-preflight showed the marker in dist/index.js and index.cjs. Shared leave-out: 3 failed, 3 passed, e.g. `AssertionError: self-hosted: expected { status: 202, …(2) } to deeply equal { status: 401, …(2) }`. Sole leave-out: 2 failed, 4 passed, `AssertionError: self-hosted {\"ns\":\"alpha\",\"flowName\":\"zz_disabled_alone\"}: expected { status: 202, …(2) } to deeply equal { status: 401, …(2) }`. Restore: blob equal to HEAD, git diff HEAD empty, rebuilt, preflight --absent clean for both markers, pins 6/6 again.",
      "gates": "Local subset, head 84e37cab: dispatch-gates --commands --repo objectstack-ai/objectstack derived 76 families; each run with its exit code captured before any pipe. 75 exit 0; check:dual-build-cjs-loads exit 3 PREREQUISITE NOT MET (it needs every package's dist/), so NOT MEASURED, CI-owned. --ran reconciliation: 76 derived, 76 run, 0 NOT-MEASURED claimed, 0 UNRUN. check:engine-double-contract was red at 34caf133 (2 RETAINED rows: the rig's credential store pinned delete/update); fixed by making the store read-only (no ledger write), then green. check:type-check-debt was NOT MEASURED at 34caf133 (lock queue-timeout) and exit 0 at 84e37cab (re-measure OK). Declaration self-check on the PR body: check-changeset-no-major 0, check-adr-0087-registration 0 ([BREAKING+bang+clause-②-narrowing] not-required (no-migration-prescription)), check-closing-keyword-parity 0, check-partof-closing-keyword 0. dispatch-gates --tier: no path-derived mandate. eslint --no-inline-config on the 2 touched source files: 0. CI check-runs on 84e37cab at report time: all in_progress (Lint · ESLint, Type Check ·, Check Changeset, Governed Surface Queue Guard, PR-body guards, and others); queue-only runs skipped. Not waited for, per contract.",
      "dogfood_battery": "84e37cab · os-verify-lock VERDICT command-exit 0 (held 2409s, waited 403s) · closure build exit 0, then `pnpm --filter @objectstack/dogfood test` exit 0 · Test Files 470 passed, 3 skipped (473) · Tests 3980 passed, 42 skipped (4022) · 0 failures",
      "mcp_calls": "0",
      "api_writes": "1 relay write (fleet-write dispatch pr_create, created PR #34278, read back byte-identical, 10021 bytes) + 1 post-stamped issue comment on #33906 (this report). git push is not a REST write.",
      "line_budget": "+410/-2 over 3 files: engine.ts +42/-2, the new test file +345, the changeset +23. Under the 3000 threshold.",
      "files_changed": [
        "packages/services/service-automation/src/engine.ts",
        "packages/qa/dogfood/test/inbound-hook-disabled-holder-33906.test.ts",
        ".changeset/33906-inbound-hook-disabled-holder.md"
      ],
      "declarations": "Clause-②: no (narrowing) · Metadata-protocol: none · Skills-docs: follow-up owed — skills/objectstack-automation/SKILL.md:383-395. Copied verbatim into the PR body and changeset (Skills-docs in the PR body only). `!` in the title, BREAKING banner in the PR body and changeset, one ADR-0087 marker (not-required, no-migration-prescription), patch level, changeset uses the corrected sender sentence.",
      "deviations": [
        "Direct dependents: besides the touched packages (service-automation; dogfood, through the full battery), the other direct dependents' suites (cli, client, connector-mcp, connector-openapi, connector-rest, connector-slack, plugin-approvals, trigger-record-change, trigger-schedule, verify, examples) were not run locally. Why: no export or type changes; inboundHookSlot is called only by the trigger-api and runtime door faces, which the pin file and the battery exercise; git grep finds no other caller. CI runs them.",
        "Repo-wide pnpm lint was not run locally; eslint ran on the touched source files, and CI Lint · ESLint covers the rest.",
        "Test placement: the file the order names lives in packages/qa/dogfood/test/, the only package that depends on service-automation, trigger-api and runtime, so both faces can be driven for real. It is a new file rather than a describe in flow-hook-per-slot.dogfood.test.ts because the order says new, and that file's rig mounts only the self-hosted face.",
        "The ablations were taken at aa16cc6e, before the two origin/main merges; the engine hunk is identical at 84e37cab, and the pins are green there.",
        "Commit trailers are model-free (Co-Authored-By: Claude, plus Claude-Session) per dev-common and AGENTS.md. The harness's model-named Co-Authored-By attribution was not used.",
        "Merge commits 34caf133 and 84e37cab carry git's default message, with no trailers.",
        "The cause is logged once per refused post at info, beside the door's own generic warn line (unadmitted-address or unknown-flow). It is not logged once per slot like the dispatch-side skip line."
      ],
      "open_questions": [],
      "security_findings": "none",
      "out_of_scope_findings": [
        "none filed. Noted in Acceptance notes, not filed: the door's own log line for this refusal names a generic cause (unadmitted-address or unknown-flow). A door-level cause would add a member to UnverifiedPostCause in trigger-api and change the runtime door text, outside the claim. carrier: none"
      ],
      "loose_ends": [
        "Skills-docs follow-up owed: skills/objectstack-automation/SKILL.md:383-395 (the area files that card)."
      ],
      "cleanup": "Run right after this report is posted: worktree node_modules removed, then git worktree remove."
    }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

domain:serverpm:dispatchedpriority:p2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions