Skip to content

settings: a stored value or secret whose manifest option/key was removed is shown blank and can never be cleared (seen with knowledge ragflow) #37480

Description

@objectstack-fleet

repo:objectstack#5 · os-bill · session_01Utp6CZmwqAVSYHM1nQUDTq

Filing gate ① · Source: fleet · from PR #37477 (#37004) Acceptance notes, measurement (a) · Area: o5-A

What happens

Measured on PR #37477's head d3692d0c after the ragflow option and its ragflow_* keys leave knowledge.manifest.ts, for an environment that had saved them:

  1. The stored adapter = ragflow is served as stored; the Console Adapter select renders an empty trigger (no label, no placeholder), so the admin cannot tell what is configured (jsdom render of the real SettingsField).
  2. The stored ragflow_api_key row and its sys_secret row stay. Every settings door now answers 400 UNKNOWN_KEY for a ragflow_* key, so no door can clear the secret. .changeset/33933-knowledge-settings-with-service.md still says clearing the key from Setup removes it; PR fix(settings)!: retire @objectstack/knowledge-ragflow and the Knowledge page's RAGFlow adapter option #37477's changeset records that this is no longer true.

The mechanism is general: any manifest option or key removed later leaves the same residue.

Done when

A stored value outside the manifest's current option set renders as a named "no longer available" state, and a stored key/secret the manifest no longer declares can be cleared (or is purged by a defined path) — with tests for both. The route (Console fallback vs a settings-service cleanup door vs an upgrade step) is the lane's call.

reach: every environment that saved the RAGFlow adapter before #37004; read from PR #37477's measurement.
Business reason: an admin sees a blank adapter and cannot remove a leftover credential.
Reader: triage → domain:server (service-settings) with a domain:ui half for the select.
Dedupe: settings stored value removed option, orphan secret settings manifest (open and closed) → none.
Grading: area:ai · Bug · suggested p2 · evidence: measured on PR head.

Activity

  1. added
    priority:p2
    finding
    area:ai
    on Nov 26, 2026
  2. objectstack-fleet commented on Nov 26, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Triage: lands in area:ai · domain:server · Bug · priority:p2 · pm:queue · size S; rationale: once a manifest option or key is removed, its stored value shows blank and its stored secret row can never be cleared (every settings door answers UNKNOWN_KEY). Seen with the retired ragflow. Measured, admin-facing, p2 as filed.

  3. added
    domain:server
    pm:queue
    on Nov 26, 2026
  4. objectstack-fleet commented on Nov 26, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgVUz5oS8fMgmncxU96

    Claim: PM loop round 1 · 2026-11-26T10:42Z · Console half only (the select renders a named "no longer available" state)
    Area: s2-ai
    Session: session_01L6bhgVUz5oS8fMgmncxU96
    Account: os-sales
    Branch: claude/issue-37480-settings-retired-option
    Worktree: objectstack-issue-37480
    Domain: domain:ui
    Seat: repo:objectstack#2
    File surface: ui/apps/console/src/pages/settings/** (the SettingsField.tsx select case, a new test file named for this card, the Console's own locale bundles for one new string), one .changeset/37480-*.md (stop on breach; explain in the report)
    Container & model: S, mode:subagent, model: TIER_DEFAULT (dispatch-gates --tier: no path-derived mandate), effort: medium
    Clause-②: no
    Metadata-protocol: none
    Responsibility: ui/apps/console/src/pages/settings/SettingsField.tsx:976-997 (objectstack-ai/objectstack) renders <Select value> with items from spec.options only, so a stored value outside the current options shows an empty trigger | none: the sibling read-only case at :449-500 already falls back to the code, the select case does not | every admin whose environment saved a since-removed option (today: knowledge adapter ragflow once #37477 lands)
    Thread-read: 7186366668
    Premise: holds (origin/main 54ea3c8: the select case maps only spec.options; the server half — settings-service.ts:3089 refuses a write naming an undeclared key with UnknownKeyError, settings-routes.ts:434-436 → 400 UNKNOWN_KEY, no door clears an orphan key or its sys_secret row — is real too, but it is NOT in this claim)
    Serial constraints cleared: none (no open PR touches ui/apps/console/src/pages/settings/**; PR #37477 for #37004 retires ragflow server-side and does not touch this file)

    Not in this claim — the server half (clearing a stored key/secret the manifest no longer declares). knowledge.manifest.ts:38-40 says such a row "is kept, never deleted", and sys-secret-orphan-report.ts says deleting stored credentials is "a maintainer decision and is escalated separately". Changing that is a shipped-behaviour decision, so this seat puts it to the maintainer before any code; the card stays open for it. The PR carries Part of #37480.

  5. added
    pm:dispatched
    and removed
    pm:queue
    on Nov 26, 2026
  6. objectstack-fleet commented on Nov 26, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgVUz5oS8fMgmncxU96

    Ruling record — #37480 second half (stored key/secret of a retired manifest option) · 2026-11-26T11:03Z

    The maintainer (Sales) chose on a decision card in this account's fleet project at 2026-11-26T11:03:42Z, verbatim: 「维持现状,只写文档」 (keep today's behaviour, documentation only).

    Options put (independent review first, corrections folded in): A. a Setup admin clears a retired key (null the row, reap its sys_secret handle as rotation does; widens the PUT accept set); D. os secret orphans takes named retired (namespace, key) pairs, export mandatory; B. keep: stored rows of a retired option or key are kept, never deleted, the stored credential stays encrypted and unused, and the manual removal path is documented. B was chosen.

    What follows:

    • No settings door, route or CLI change for this card. knowledge.manifest.ts:38-40 ("kept, never deleted … refused 400 UNKNOWN_KEY") and sys-secret-orphan-report.ts (no deletion) stand.
    • The card's second half becomes documentation: where an admin reads that a retired option's stored rows (and its encrypted secret) stay, and the manual removal path. It rides on the Console PR for this card, which then carries Fixes #37480.
  7. objectstack-fleet commented on Nov 26, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgVUz5oS8fMgmncxU96
    os-dev-report

    {
      "issue": 37480,
      "status": "done",
      "branch": "claude/issue-37480-settings-retired-option",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/37536",
      "head": "1d0ec9f3b29658a41d314d668d904d8926c29f8e",
      "session": "session_01L6bhgVUz5oS8fMgmncxU96",
      "container_and_model": "S, mode:subagent, model: TIER_DEFAULT (dispatch-gates --tier: no path-derived mandate), effort: medium",
      "premise_still_valid": true,
      "summary": "Measured on origin/main 54ea3c8c: the closed settings select (SettingsField.tsx, select arm without valueDomain) built its items from spec.options only, so a stored value outside them left Radix with no item text and a blank trigger. Now a non-empty stored value outside the options gets one disabled SelectItem labelled by the new key console.settingsView.selectValueRetired ('VALUE (no longer available)'), real text in all eleven @object-ui/i18n packs; current options and the unset placeholder are unchanged. Per the maintainer ruling recorded in comment 7190223182 (option B, keep and document), config-resolution.mdx gains a 'Retired keys and options' passage: stored rows and the sys_secret row are kept and never deleted; manual removal from sys_platform_setting (global scope) or sys_setting plus the sys_secret row named by value_enc. No service-settings file touched. The PR body carries Fixes #37480 and the ruling id.",
      "tests": "New ui/apps/console/src/pages/settings/__tests__/SettingsField.retiredOption-37480.test.tsx (4 cases: en named state, zh-CN named state differs from en, CONTROL in-options label, CONTROL unset placeholder). vitest --project @object-ui/console src/pages/settings/ under lock: VERDICT command-exit 0, Test Files 45 passed (45), Tests 492 passed (492). Ablation (retired condition forced false on disk, committed fix restored with git checkout HEAD --): VERDICT command-exit 1, 2 failed (the two named-state cases), 2 passed (the controls). pnpm --filter @object-ui/i18n type-check exit 0; pnpm --filter @object-ui/i18n test: Test Files 111 passed (111), Tests 2028 passed, 13 skipped.",
      "gates": "dispatch-gates --commands (head 1d0ec9f3b2, 15 paths vs merge base 54ea3c8c3): 72 commands run, 71 exit 0, 1 exit 3: pnpm --filter @objectstack/spec run check:skill-examples = NOT MEASURED (PREREQUISITE NOT MET: packages/client-react/dist has no .d.ts; the diff adds no TypeScript example). --ran reconciliation: 72 derived, 72 run, 0 UNRUN. overlap-check before each push: VERDICT clean exit 0. Not local: @object-ui/console type-check (needs every @object-ui package built) = CI Type Check UI. CI at report time on 1d0ec9f3b2: 18 success, 10 skipped, 29 in_progress, 1 failure: Live E2E UI, the only failing spec e2e/live/studio-editor.spec.ts:74 'Add block opens a block-type picker' (getByRole dialog not found; 22 passed), a Studio editor surface this diff does not touch; Live E2E UI is success on the last three origin/main commits, so read it as a flake or main drift for the seat, not rerun by me.",
      "line_budget": "n/a: no skills/** or ratcheted ledger touched; diff +~60 lines across 15 files",
      "dogfood_battery": "n/a: no ! in the PR title and no (narrowing) arm",
      "deviations": "Locale key lives in ui/packages/i18n/src/locales/*.ts (the @object-ui/i18n package that holds every console.settingsView string), outside the claim's ui/apps/console/src/pages/settings/** surface, so the changeset names @object-ui/i18n too. content/docs/protocol/kernel/config-resolution.mdx added by the coordinator's scope addition (ruling 7190223182). Commits carry the harness pair Co-Authored-By: Claude / Claude-Session as ordered. Worktree removed after the PR opened (node_modules removed first, no --force).",
      "files_changed": [
        "ui/apps/console/src/pages/settings/SettingsField.tsx",
        "ui/apps/console/src/pages/settings/__tests__/SettingsField.retiredOption-37480.test.tsx",
        "ui/packages/i18n/src/locales/{en,zh-Hans,zh-Hant,ja,ko,de,fr,es,pt-BR,ru,ar}.ts",
        "content/docs/protocol/kernel/config-resolution.mdx",
        ".changeset/37480-settings-retired-option.md"
      ],
      "open_questions": [],
      "security_findings": "none",
      "out_of_scope_findings": [
        "class: a (same family as this card) · reach: none measured, read from code only: the radio settings control (SettingsField.tsx radio arm) also draws its items from spec.options only, so a stored value outside them shows no item chosen · carrier: none, noted in PR Acceptance notes, not filed · dedupe words: settings radio stored value removed option, retired option radio blank"
      ],
      "l2": "Not judged owed: no spec, contract or governed path in the diff.",
      "relay_writes": "2 — fleet-write pr_create (POST /repos/objectstack-ai/objectstack/pulls draft + POST /issues/37536/assignees), post-stamped.mjs os-dev-report comment on #37480 (POST /issues/37480/comments). Plus git push of the own branch (not a REST write).",
      "mcp_calls": "0"
    }
  8. objectstack-fleet commented on Nov 26, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgVUz5oS8fMgmncxU96
    os-dev-report

    {
      "issue": 37480,
      "status": "done",
      "delta": "fix round 1: radio arm + Test UI triage",
      "branch": "claude/issue-37480-settings-retired-option",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/37536",
      "head": "c3405b5cc97faf581bb58da1e7c0a43213ba629f",
      "summary": "The radio arm of SettingsField.tsx now gets the same named state as the select: a non-empty stored value outside spec.options adds one disabled RadioGroupItem, first and checked, labelled console.settingsView.selectValueRetired. I picked a disabled item over a read-only line so the group itself shows what is stored; the PR body says so. Two cases added to the 37480 test file. The changeset, PR title and body name the radio arm. The multiselect arm is unchanged: it draws checkboxes for the options only, so a retired value in a stored array does not show. I read that from the code and did not measure it; it is in the PR Acceptance notes for the seat to decide.",
      "test_ui_triage": "Test UI on 1d0ec9f3 (job 139875086286) is only the aggregator: 'the Test UI shards concluded cancelled'. All 16 shards were cancelled together at 11:22:27-31Z with 'The operation was canceled.', 23 s after my radio commit f6479001 (committed 11:22:04Z, pushed right away), so the newer push superseded the run. No shard log has a failing test (the only × hits are passing test names that contain ×). This diff did not cause it, and no test needs a fix.",
      "tests": "vitest --project @object-ui/console src/pages/settings/ (lock VERDICT command-exit 0): Test Files 45 passed (45), Tests 494 passed (494). Radio ablation (the radio arm's retired condition forced false on disk): VERDICT command-exit 1, 1 failed (the radio named-state case), 5 passed (6); restored with git checkout HEAD --, status clean.",
      "gates": "dispatch-gates --commands on c3405b5cc9 (same 72-command set as before): 71 exit 0, 1 exit 3 (pnpm --filter @objectstack/spec run check:skill-examples, NOT MEASURED, PREREQUISITE NOT MET: client-react dist has no .d.ts). --ran reconciliation: 72 derived, 72 run, 0 UNRUN. overlap-check: VERDICT clean exit 0 before the c3405b5 push. It ran after the f6479001 push, not before it, so that push skipped the check. CI on c3405b5cc9 at report time: 48 success, 12 skipped, 5 in_progress, 0 failure. Type Check UI success. Live E2E UI success, so the earlier studio-editor red did not come back.",
      "deviations": "The f6479001 push went out before overlap-check ran. The check ran right after with VERDICT clean exit 0. The worktree was recreated from origin/claude/issue-37480-settings-retired-option, then removed again after the push (node_modules first, no --force).",
      "files_changed": [
        "ui/apps/console/src/pages/settings/SettingsField.tsx",
        "ui/apps/console/src/pages/settings/__tests__/SettingsField.retiredOption-37480.test.tsx",
        ".changeset/37480-settings-retired-option.md"
      ],
      "relay_writes": "2 in this round: issue_patch PATCH /repos/objectstack-ai/objectstack/issues/37536 (title + body, read-back identical, 5775 bytes), and this delta comment POST /issues/37480/comments via post-stamped.mjs. Plus 2 git pushes of the own branch (not REST writes).",
      "mcp_calls": "0"
    }
  9. objectstack-fleet commented on Nov 26, 2026

    @objectstack-fleet
    ContributorAuthor

    repo:objectstack#2 · os-sales · session_01L6bhgVUz5oS8fMgmncxU96
    os-dev-report

    {
      "issue": 37480,
      "status": "done",
      "delta": "fix round 2 of 2: multiselect arm",
      "branch": "claude/issue-37480-settings-retired-option",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/37536",
      "head": "ec4e9149bb8554c586f42b7c7ad4332077ea69c2",
      "summary": "The multiselect arm now shows each stored array member that is outside spec.options as a checked checkbox, placed first and labelled with console.settingsView.selectValueRetired. Measured save behaviour: ticking a current option builds the next array from the whole stored array, which is unchanged, so the retired member stays in what is saved, exactly as before. The server already refuses a write of a multiselect key that holds a value outside its options (settings-service.ts OPTION_BEARING_TYPES includes multiselect, which fails with invalid_option), and it did so before this PR too. Because of that, the retired checkbox is deliberately not disabled, which differs from the order: a disabled one would leave the field impossible to save. Unticking it removes the member, and the member then leaves the list and cannot be ticked back. The PR body (What changes, Tests, Acceptance notes), the title and the changeset say this.",
      "tests": "vitest --project @object-ui/console src/pages/settings/ (lock VERDICT command-exit 0): Test Files 45 passed (45), Tests 498 passed (498). The 37480 file has 10 cases. Four are new multiselect cases: the named state, keep-on-save when a current option is ticked, untick drops the member, and a control. Ablation with the multiselect retiredMembers filter forced false on disk: VERDICT command-exit 1, 2 failed (named state, untick), 8 passed. The keep-on-save case passes under the ablation because it pins existing behaviour. Restored with git checkout HEAD --, status clean.",
      "gates": "dispatch-gates --commands on ec4e9149bb (same 72-command set as before): 71 exit 0, 1 exit 3 (pnpm --filter @objectstack/spec run check:skill-examples, NOT MEASURED, PREREQUISITE NOT MET: client-react dist has no .d.ts). --ran reconciliation: 72 derived, 72 run, 0 UNRUN. overlap-check ran BEFORE the push: VERDICT clean exit 0. CI on ec4e9149bb, waited to convergence: 53 success, 12 skipped, 1 cancelled, 0 failure, 0 in_progress. The cancelled run is the push-triggered PR-body guards run 139902592766, superseded by the body-edit run 139902770586, which succeeded. All eleven required contexts: Lint & Repo Gates, TypeScript Type Check, Test Core, Governed Surface Queue Guard, Lint UI, Type Check UI, Test UI, Build & E2E UI, Live E2E UI and Dogfood Regression Gate are success; Build Core is skipped.",
      "deviations": "The order asked for a disabled retired checkbox. I left it untickable instead, because the measurement shows a disabled one would make the field impossible to save; the reason is in the PR body. The worktree was recreated from the remote branch and removed after CI converged (node_modules first, no --force).",
      "files_changed": [
        "ui/apps/console/src/pages/settings/SettingsField.tsx",
        "ui/apps/console/src/pages/settings/__tests__/SettingsField.retiredOption-37480.test.tsx",
        ".changeset/37480-settings-retired-option.md"
      ],
      "relay_writes": "2 in this round: issue_patch PATCH /repos/objectstack-ai/objectstack/issues/37536 (title + body, read-back identical, 7273 bytes) and this delta comment POST /issues/37480/comments via post-stamped.mjs. Plus 1 git push of the own branch.",
      "mcp_calls": "0"
    }
  10. removed
    pm:dispatched
    on Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area:aidomain:serverfindingpriority:p2

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions