Skip to content

feat(app-sdk): let the owner edit an app's declared ceiling in core - #47902

Draft
bolichen97 wants to merge 5 commits into
mainfrom
feat/app-owner-ceiling-settings-1205
Draft

bolichen97 wants to merge 5 commits into
mainfrom
feat/app-owner-ceiling-settings-1205

Conversation

@bolichen97

@bolichen97 bolichen97 commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: The owner changes an installed first-party app's owner-only ceiling, such as Ops Mission Control's autonomy limits, with plain form fields on that app's page in Kiro Crew, while the app itself can only read it.

Part of #26967. Campaign ruling D11, option A, in the owner's words: "A: OMC gets no write seam; its page only shows the current ceiling and links to core's owner-only settings page."

Today the only writer of ops_mission_control_policy.json (the app's mode and act-rules) is the built-in copy's own authenticated PUT /settings. Core fences the file (the agent's file tools refuse it, every sandbox masks it) but has no surface of its own that edits it. When the copy is deleted, that writer goes with it, so the deletion draft currently tells the owner to hand-edit the JSON file in the data home.

Why it matters

Without a core writer, deleting the copy leaves an ordinary owner hand-editing a protected JSON file to change how much an ops app may do on its own against their production incident tooling, and the deletion cannot follow ruling D11 option A, which is what keeps the app from being able to raise its own ceiling.

Not a goal

  • No write path for the app: no backend SDK name, no context seam, and no route an app token can call.
  • No change to any file's sandbox disposition, tool-gate rows or staging, and no file moves between the masked and read-only lists.
  • No read seam for an app's spawned backend: the app this is for reads its file from in-process hooks.
  • No change to the built-in copy or to the app repository: the copy does not declare ownerCeilings, and the app adds the declaration and its link in its own repository.
  • No translation of an app's own field labels: they show as the manifest writes them.
  • No new Settings tab: the entry sits on the app's detail page, beside the other owner-only app settings (Bot access, browsing sites, agent tools).

What changed (motivation → approach → change)

Approach. The app declares which data-home file holds its ceiling and what fields it holds; core decides whether it serves that file, shows a form for it on the app's page, and is its only writer. Generic and app-agnostic: no core module names an app or an app's file, and the one file served today is found from core's existing floor tables and the first-party app list, not from a new table.

  • Manifest field ownerCeilings (App Kit seam level 59). Up to 4 ceilings, each a file, a title, an optional description and up to 16 fields of five plain types: choice, choices, text, pairs (name and value rows) and list (rows of the other four). file must be one .json name at the data-home root starting with the app's name (- as _) and _. Any error refuses the manifest; a non-empty declaration is in the signed payload. APP_SDK_LEVEL becomes 59 on both sides and scripts/adoption_pin.py counts a declaration at level 59. The grammar module is imported only when a manifest declares the key, so an MCP server's listing loads nothing new.
  • Which file core serves (apps/owner_ceilings.serving_refusal, re-checked on every read and write): the name rule above; a first-party app (a built-in this build ships, or a former built-in with an adoption pin row); the file already in security._CREW_SECRET_LEAVES and in the sandbox's HIDDEN or READONLY leaves; and not a file the sandbox treats as a credential. A table that cannot be read refuses. A test judges every root leaf on the floor for every first-party app: exactly ops_mission_control_policy.json passes, and its provider-token store beside it is refused as a credential.
  • Routes (apps/owner_ceilings_routes.py, both unstable in route_access, owner-ceilings added to CORE_APP_ROUTE_SEGMENTS on both sides):
    • GET /api/apps/{name}/owner-ceilings (apps.owner_ceilings.read): every declared ceiling with its state, revision and, when it can be saved over, values.
    • PUT /api/apps/{name}/owner-ceilings/{file} (apps.owner_ceilings.write): {"values": {...}, "revision": "..."} replaces the declared fields.
  • Read, fail closed. Opened without following a link at its name, a regular file with one name, under 256 KiB. States: absent, ok, unreadable, corrupt, outside_shape, refused. Only absent and ok carry values or accept a save. A stored empty value the page never writes ("", [], {}, null) is outside the shape, because an app may read it differently from an absent key: for this app's act-rules, no actions grants every action and actions: [] grants none, so reading one and saving it back as the other would widen a grant. A stored value the write would store differently (a text, pair name or pair value with spaces around it) is outside the shape too, so saving an unrelated field never rewrites a label the app compares exactly.
  • Write. Values are checked against the declaration, then, under one in-process lock per file, the file is read again, a stale revision (SHA-256 of the bytes the page read) is refused with 409, the declared keys are replaced, every undeclared key is kept as it is, a result over the read's 256 KiB cap is refused (413 owner_ceiling_too_large, so no save leaves a file the page can no longer read), and the file is published through the existing masked staging directory (hidden_leaf_staging.publish_through_auth_store_staging), owner-only.
  • Page. AppDetailOwnerCeilings shows one card per declared ceiling on the app's detail page: radio buttons, checkboxes, text boxes and rows, never raw JSON. A state it cannot show explains why and has no form; a stale save says so and reads the file again; name and value rows that cannot become one object as entered (a repeated name, a value with no name) stop the save with a message instead of dropping a row; a new declaration rebuilds the draft in the same render, so no control renders against another shape; a session the owner gate refuses sees nothing. The stable link for an app's page is /apps/detail/<name>#owner-ceilings.
  • The app's read. The app reads its own file. Ops Mission Control's adopted copy runs its routes in-process (backend.hooks), where it already opens ctx.data_home / "ops_mission_control_policy.json", so no read seam is added. A spawned backend would see the file masked, as it does today; that is recorded as the case that would need a read seam.
  • Specs in the same commit: app-kit-platform.md section 59 and the level list, security.md, the App Kit manifest and API references.

Security

The file this writes is a security ceiling over the agent, so every check fails closed and nothing about its protection moves. Who may call: the owner's dashboard only, the read included; an app token (the app's own included, although the path is in its namespace) gets 403 app_token_forbidden, an internal caller (an agent's MCP tools and kiro-cli) gets 403 dashboard_session_required, and every other session gets owner_only from the same owner gate every owner setting uses (the built-in's own settings route used it too). What may be written: only a first-party app's own file that is already on both halves of core's floor and is not a credential, so a manifest cannot point the writer at a core record (for example a third-party app named aws-service and aws_service_consent.json), and only the declared keys, of the declared types, under their caps. The agent can neither declare a ceiling (installed manifests are sealed read-only in its sandbox) nor reach the routes. Audit: every refusal of either route writes a denied Security Event Log row with its code; every save writes allowed with critical=True after all checks and before the publish, so a save whose row cannot land is not made (500 owner_ceiling_not_saved), and failed when the publish does not land; rows name the app, the file and the keys, never a value. Disposition: the file keeps HIDDEN, its tool-gate rows and its staged publish; this reads those tables and changes none of them. Residual, unchanged: a HIDDEN file absent when a sandbox started is not masked in that sandbox, so the first save that creates the file is visible to sessions already running until they restart, as with the built-in's writer.

Backwards compatibility

Compatible: a manifest without ownerCeilings parses, validates and signs exactly as before (the key is left out of the signed payload when absent), and no existing route, file or disposition changes.

Writer sweep on origin/main @ fbb2051: no manifest, fixture, pin row or registry entry in the tree declares ownerCeilings or an endpoint under an owner-ceilings segment.

  • Reader: src/kiro_crew/apps/manifest.py:AppManifest.validate -- app -- an ownerCeilings key that used to sit unread in extra now refuses the install only when it is declared and invalid; nothing in the sweep declares one -- test_app_owner_ceilings.py::test_a_declaration_outside_the_grammar_refuses_the_manifest
  • Reader: src/kiro_crew/apps/manifest.py:app_endpoint_allowed -- app -- a contributed endpoint under /api/apps/<app>/owner-ceilings is refused now that core serves that segment; nothing in the sweep declares one -- test_file_menu_items.py::test_core_route_segments_covers_every_core_route_in_the_app_namespace

Tests

  • test/test_app_owner_ceilings.py (new; every test fails on main, where the module, the routes and the key do not exist): the grammar and its refusals, the signed payload, level 59 in the pin tool; value checks, the stored-empty refusal (the actions: [] widening case) and the stored-value-would-change refusal (" prod " labels); the served set over every first-party app and floor leaf, each refusal reason, and a floor that cannot be read; absent, ok, unreadable (second name, oversize), corrupt and out-of-shape reads, undeclared keys kept, stale revision, a save whose file would pass the read cap is refused before its audit row, an audit that raises writes nothing; both routes refuse an app token, an internal caller and a non-owner session with a row each, the owner's read and save, every refused save writes nothing and one denied row, a save the audit cannot record is not made.
  • website/src/pages/AppDetailOwnerCeilings.test.tsx (new): hidden with no declaration, the fields with stored values and the exact stored shape saved with the read revision, no form over an out-of-shape file, the stale-save notice and refetch, nothing for a refused session, the #owner-ceilings scroll, a repeated pair name stops the save with nothing sent, a field a newer declaration adds renders after a save, a control given another shape renders empty, and the form value conversions.

Proof: not provable -- other: feature PR; the tests target a new module, new routes and a new manifest key that main does not have.

Manual verification

Not run on this host (lint and check scripts only). CI is the test evidence; the real-machine run below drives the routes end to end.

Real-machine verification

Machine: the user-reserved EC2 host in us-west-2, driven over SSM only: Ubuntu 24.04.5 LTS, x86_64, 8 vCPU, CPython 3.12.3, run as an unprivileged user; the namespace sandbox is available.

Method: one venv got the dependencies from an editable install of the head; each tree under test (a shallow fetch of that commit) is first on PYTHONPATH. The same probe script (not in the repo) ran against each tree with the same command, PYTHONPATH=<tree>/src <venv>/python -P probe.py <work-dir>/omc-app.json, with its own throwaway HOME, KIROCREW_HOME and temp folder. The probe writes the adopted app's real manifest (its repository's app.json at the pinned commit, version 0.2.4) plus an ownerCeilings block for ops_mission_control_policy.json into the data home, mounts the core app routes with register_app_routes behind a stand-in for token auth that sets the caller (the local owner subject with the real owner gate, the app's token, an internal caller, another dashboard user), and calls them on a loopback ephemeral port. Then it reads and writes the file from a child started with backend_sdk.run_sandboxed(..., mode="standard"), and prints the Security Event Log rows the routes wrote.

Before (base fbb20518397d):

  • APP_SDK_LEVEL 58; the manifest's ownerCeilings is left unread in extra.
  • Every GET /api/apps/ops-mission-control/owner-ceilings and PUT .../owner-ceilings/ops_mission_control_policy.json, for every caller, answers 404: core has no surface that reads or writes the ceiling; the file stays absent.
  • Sandboxed child: cat of the file sees 0 bytes (the host file holds 42), and a write leaves the host file unchanged. No apps.owner_ceilings row.

After (head c9879c67df64; the earlier heads 957e24454a2b and 1d2f5059b820 gave the same lines, without the two refusals that head added):

  • APP_SDK_LEVEL 59; the declaration parses into ownerCeilings and validates.
  • Owner GET -> 200, state=absent, values={}.
  • App token -> 403 app_token_forbidden; internal caller -> 403 dashboard_session_required; another dashboard user -> 403 owner_only; on both routes, and the file is still absent.
  • Owner PUT of mode: act and one act-rule -> 200 state=ok; the file holds exactly those two keys, mode 0o600; the app's in-process read of the file gives mode = act.
  • Refusals: the same PUT again with the old revision -> 409 owner_ceiling_changed; mode: everything -> 400 owner_ceiling_invalid; an undeclared ledger_sync_remote -> 400 owner_ceiling_invalid.
  • Fail closed: a planted rule with actions: [] -> state=outside_shape and the PUT over it -> 409 owner_ceiling_outside_shape, the file byte-identical; a planted label " prod " -> state=outside_shape (would save differently) and a PUT of an unrelated field -> 409, the file byte-identical; a corrupt file -> state=corrupt and 409 owner_ceiling_corrupt; a 162,712-byte save whose file would pass 256 KiB -> 413 owner_ceiling_too_large, the file unchanged; a declaration naming ops_mission_control_secrets.json -> state=refused (owner_ceiling_is_credential) and its PUT -> 403.
  • Sandboxed child: the same as the base (cat sees 0 bytes, the write leaves the host file unchanged), so the file's disposition did not move.
  • 16 SEL rows: denied for each of the six caller refusals, one allowed with keys=['autonomy_rules', 'mode'] and no values, and denied with its code for each of the nine refusals above.

Cleanup: removed the run directory (the venv, both source trees, the probe, the fetched manifest and every throwaway home); no process from that directory left running; instances left running (user-reserved).

Screenshots / video

The real AppDetailPage in the capture harness, opened at /apps/detail/ops-mission-control#owner-ceilings with only gateway reads stubbed, so the page has scrolled to the card the app's own page links to.

Dark, the stored ceiling as the form shows it:

Owner ceiling card, dark

Dark, after the owner picks "Act on its own" (Save enabled):

Owner ceiling card edited, dark

Light theme, and a file the page cannot show

Owner ceiling card, light

A stored value the page never writes: the card says why and offers no form.

Owner ceiling card, out of shape

Related Issues

Part of #26967

Checklist

  • A Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...); PR Hygiene does not count commits
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

Contribution License Agreement

Contributions are accepted under the project's Apache-2.0 license.

Owner ruling D11 (option A) on #26967: an app gets no write path to
its autonomy ceiling; its page shows the current ceiling and links to
core's owner-only settings. Until now the only writer of such a file
was the built-in copy's own settings route, which leaves with the
copy. This adds the generic core writer, App Kit seam level 59:

- app.json ownerCeilings: the data-home file that holds the ceiling
  (named for the app) and its fields, five plain form types (choice,
  choices, text, pairs, list of those). Any error refuses the
  manifest; the declaration is signed with it.
- GET /api/apps/{name}/owner-ceilings and
  PUT /api/apps/{name}/owner-ceilings/{file}, owner dashboard only
  (app tokens and internal callers refused), both unstable. Core serves
  a file only for a first-party app, only when it is already on both
  halves of core's floor over the agent and is not a credential; it
  reads those tables and changes none of them.
- The read fails closed on an unreadable, linked, multi-linked,
  oversized, corrupt or out-of-shape file. The write keeps every
  undeclared key, refuses a stale revision, publishes through the
  masked staging directory, and writes its allowed SEL row
  fail-closed before the publish; every refusal writes a denied row.
- The app detail page shows one card per declared ceiling with a form
  control per field, and scrolls to #owner-ceilings when linked.

The app reads its own file: an in-process backend opens it under the
data home, so no app read seam is added.

Part of #26967
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Dec 5, 2026
@github-actions

github-actions Bot commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — 🔴 BLOCK

UX-level review of 6ed63d7e10170d93583b2a69260715cf69e5081e — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

UX-Verdict: BLOCK

When a ceiling can't be shown or changed, the only way forward the card offers is "Ask the agent", and that's the one actor this design locks out of the file. The owner is stuck and can't see what the app is allowed to do.

Blockers

The blocked-state card offers a fix that can't work
Trigger: the stored policy file is in the outside_shape, corrupt, unreadable or refused state. The PR itself names actions: [] as one way to get there.
Outcome: the card shows no values, only "This setting holds values this page can't show, so it can't be changed here." with askAgent (shot-04). The hint directly above says "neither the app nor its agents can change them", and the agent's sandbox keeps the file read-only. So the hand-off can't change anything. The blind reader said: "The box itself says the app and 'its agents' can't change these settings, yet now it sends me to an agent", and listed "Ask the agent" among the things it "would not dare to use". The owner can't see or change their ops app's autonomy limit from anywhere in the product. Severity: this happens rarely, but when it does it blocks the task outright, and it stays blocked until someone edits the file by hand.
Fix: pass noHandoffReason instead of askAgent. The notice should say what the file holds now, and either offer "Reset to defaults" or say plainly that the file has to be edited by hand.

Evidence gaps

  • None of the screenshots show the "Saved." confirmation after a save. A shot taken after Save would close this.
  • The stale-edit notice ("This setting changed while you were editing it…") and the pair-row errors (owner_ceilings_pair_unnamed, owner_ceilings_pair_duplicate) don't appear in any screenshot either. One shot of each would close this.

Notes

  • Save sits at the bottom of a long card and is off-screen on first view (shots 01 and 03). The reader wrote: "I can't see any Save button on this screen." Keep Save in view while the form is dirty.
  • The rule's "Remove" and a label row's "Remove" look the same. Change the rule's button to "Remove rule" (and the matching "Add" to "Add rule") so the reader stops worrying "I might delete the wrong thing."
  • The hint "Only you can change these…" repeats what owner_ceilings_title, "Settings only you can change", already says. Drop the hint.

[UX-REVIEWED] 6ed63d7

Description read

[DESCRIPTION-READ] fa893a7bf28af85b4b1e4f1414182f9e55c12e8c641c3e20164dc8bb59dcda21

That sha256 names everything this verdict read: the PR description, plus the 7 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of 6ed63d7e10170d93583b2a69260715cf69e5081e — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Nothing blocks: core is now the only writer of the ceiling file, the app can only read it, and no file's sandbox or tool-gate protection changes.

Notes

  • serving_refusal limits the seam to first-party apps whose files are already on both halves of the floor, so today it serves exactly one file. Third-party apps get a manifest field that always comes back refused. The App Kit references should say that plainly, so authors don't treat it as a general seam.
  • Until the built-in copy is deleted, its own PUT /settings is a second writer of the same file. The per-file lock only covers core's route. The 409 revision check keeps the overlap safe, so it doesn't need fixing.

[DESIGN-REVIEWED] 6ed63d7

Description read

[DESCRIPTION-READ] ea1076dc764f05d7115227ad679bcb369d696d1717d0a8a87eafa8a7e4f182ab

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of 6ed63d7e10170d93583b2a69260715cf69e5081e — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

First-Principles-Verdict: PASS

Nothing blocks. Every item lets the owner change an app's ceiling once the built-in writer is deleted. Ruling D11 option A and AGENTS.md's "generic, app-agnostic seam" rule both require this approach.

What this change ships

Inventory (9 items) — 9 justified

Intent: let the owner keep changing an adopted first-party app's autonomy ceiling, such as Ops Mission Control's mode and act-rules, from core once the built-in copy's PUT /settings is deleted, without giving the app a way to write it. ADDITION.

  1. The app's detail page shows a card per declared ceiling, using form controls instead of raw JSON — justified
  2. The owner can save that card and core writes the data-home file. The revision check refuses a stale save — justified
  3. New app.json key ownerCeilings: 5 field types, at most 4 ceilings and 16 fields, part of the signed payload — justified
  4. App SDK level 59 on both sides, and adoption_pin.py counts a declaration — justified
  5. Core serves a file only if it is first-party, already on both floor tables and not a credential. Only ops_mission_control_policy.json passes — justified
  6. Both routes refuse app tokens and internal callers, so only the owner's dashboard can use them — justified
  7. Every refusal and every save writes a Security Event Log row. A save whose allowed row cannot be written is not made — justified
  8. owner-ceilings is reserved in CORE_APP_ROUTE_SEGMENTS on both sides — justified
  9. New page strings in all 14 locales, and the stable link /apps/detail/<name>#owner-ceilings — justified

[FIRST-PRINCIPLES-REVIEWED] 6ed63d7

Description read

[DESCRIPTION-READ] 11bb7c658903c4de59e5ec692dc4f63af553a156a986317c98ee94a22011e95a

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

github-actions Bot commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed 6ed63d7e10170d93583b2a69260715cf69e5081e — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] 6ed63d7

Verdict parsed from the review's SHA-scoped output markers for commit 6ed63d7e10170d93583b2a69260715cf69e5081e.

False positive or not applicable? A repository writer can comment:
/ai-review override fable 6ed63d7e10170d93583b2a69260715cf69e5081e false-positive: <reason, 20 to 500 characters>

@github-actions

github-actions Bot commented Dec 5, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — 🔴 changes requested (blocking)

GPT 6.1 found at least one blocking issue that must be resolved before merging 6ed63d7e10170d93583b2a69260715cf69e5081e. 1 of 2 blocking finding(s) are security-class and were withheld from adjudication, so the blocking verdict stands.

This comment is updated in place on each push.

BLOCKING -- website/src/pages/appDetailOwnerCeilingFields.tsx:85 -- Form trimming silently rewrites accepted ceiling values

const text = v.trim()
Trigger: A declared pairs field contains {"env":"\uFEFFprod"} and the owner saves another field. stored_values() accepts the original unchanged because Python’s str.strip() preserves U+FEFF; OwnerCeilingCard.save() serializes every field through toWire(), whose JavaScript trimming removes it.
Outcome: The save overwrites the untouched value with "prod". For label_match, AutonomyRule.matches() compares values exactly, so the rewritten rule matches production signals the original rejected.
Anchor: residual/crash-data-loss-corruption
Fix: Align frontend normalization with backend normalization so every value accepted by the stored-value round-trip check remains unchanged when untouched.
Sites: Text trimming at website/src/pages/appDetailOwnerCeilingFields.tsx:76; pair-name trimming at website/src/pages/appDetailOwnerCeilingFields.tsx:84; recursive row conversion at website/src/pages/appDetailOwnerCeilingFields.tsx:98; exact-match reader at src/kiro_crew/apps/builtins/ops_mission_control/backend/rotation.py:197.

BLOCKING -- website/src/pages/AppDetailOwnerCeilings.tsx:72 -- Client validation hints share the failed-request error surface

setError(e.message)
{error && }
Trigger: The owner enters duplicate pair names or a value without a name and presses Save. toWire() throws CeilingFormProblem; the catch assigns its validation hint to the same state used for rejected API requests.
Outcome: A local validation hint renders as a blocking failure alert without any request being attempted, violating the rule’s explicit prohibition on mixing validation hints and server failures or passing validation-only messages to ErrorNotice.
Anchor: errors-use-error-notice
Fix: Render client-validation hints through separate plain-text state; reserve ErrorNotice for failed requests.
Sites: Validation producers at website/src/pages/appDetailOwnerCeilingFields.tsx:87 and website/src/pages/appDetailOwnerCeilingFields.tsx:88; server-failure assignment at website/src/pages/AppDetailOwnerCeilings.tsx:84.

[BLOCK-MERGE] 6ed63d7
[GPT-REVIEWED] 6ed63d7

Adjudication (Opus 5.5) — is blocking on each finding proportionate?

The harm rung is LOW. It confirms that toWire throws CeilingFormProblem for an unnamed or duplicate pair (website/src/pages/appDetailOwnerCeilingFields.tsx:87-88). The save handler catches it and calls setError (website/src/pages/AppDetailOwnerCeilings.tsx:72). That is the same state the request-failure branches set (AppDetailOwnerCeilings.tsx:81,84), so a local validation hint shows up as an ErrorNotice alert. Nothing is sent and the draft survives, so the owner can fix it and save again. The fix is cheap: a separate hint state rendered as plain text. Even so, the finding is anchored to errors-use-error-notice, and that rule carries blocking: true in .review-base-rules/website-AUTOSDE.yaml:681. It also explicitly says validation hints "must not be dressed as" errors (website-AUTOSDE.yaml:704-706). The rule's flag outranks any weighing.

F1 (fenced): the conditions are plausible. A value with a leading U+FEFF passes the backend round-trip check, but toWire trims it away on every save (website/src/pages/appDetailOwnerCeilingFields.tsx:76,84-85). That silently rewrites a field the owner never touched. When the field is used as an exact-match label rule, the rule widens, which loosens a governance ceiling. Such a value can come from pasted text or a hand-edited ceiling file, and nothing on the save path detects the change or recovers it.

[ADJUDICATION] 6ed63d7e10170d93583b2a69260715cf69e5081e total=1 uphold=1 downgrade=0
UPHOLD F2 website/src/pages/AppDetailOwnerCeilings.tsx:72 reason=autosde-blocking-rule
[GPT-ADJUDICATED] 6ed63d7e10170d93583b2a69260715cf69e5081e

[ADJUDICATION-FENCED] 6ed63d7e10170d93583b2a69260715cf69e5081e fenced=1 flagged=0
UPHOLD-FENCED F1 website/src/pages/appDetailOwnerCeilingFields.tsx:85 -- Any save trims every field through toWire, so a value with a leading BOM that the backend accepted is silently rewritten and an exact-match ceiling rule widens, from ordinary pasted input and with no recovery path.
[GPT-ADJUDICATED-FENCED] 6ed63d7e10170d93583b2a69260715cf69e5081e

False positive or not applicable? A repository writer can comment:
/ai-review override gpt 6ed63d7e10170d93583b2a69260715cf69e5081e false-positive: <reason, 20 to 500 characters>

The declared field type is narrowed to a string before it picks the
field's options, the per-type caps get names of their own, and the
feature map gains the app detail page's owner ceilings row.

Part of #26967
A stored value the page would save differently (text, a pair name or
value with spaces around it) now reads as outside the shape, so a save
of an unrelated field cannot trim a label the app compares exactly. A
save whose file would pass the read's 256 KiB cap is refused before the
audit row and the publish. Name and value rows that cannot become one
object as entered stop the save with a message instead of dropping a
row, and the card rebuilds its draft in the same render a new
declaration arrives, so no control renders against another shape.

Part of #26967
The revision a save names now covers the app's declaration as well as
the file's bytes, so a form opened before an app update that declares
one more field is refused instead of saving without that field and
deleting its stored value. A required field binds what the owner saves,
not what the file holds, so a file that already carries the app's other
values still shows. The oversized-file case gets explicit test ids, so
its bytes are not the test's node id.

Part of #26967
The ceiling card's catalog values spell the product name with the
productName placeholder, the French save error puts a narrow no-break
space before its colon, and the short Add label has translator context.
The per-file lock table is marked as a cache that holds no test state,
and the builtin snapshot round-trip probe declares an owner ceiling so
the copy of that field is exercised.

Part of #26967

This branch has not been deployed

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

Labels

readiness: checking Automated validation is still running

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant