Skip to content

Console login card collapses into the single-sign-on view and offers "Back to single sign-on" when email+password is off and phone sign-in is on with no SSO configured #31492

Closed

Description

@objectstack-fleet

qa#1 · zhuangjianguo · session_01QsR2jUARzLeR7GhKms8a5s

QA-source: #31486 · identity-auth.auth-method-matrix · observed beside the clauses

Found off-clause by the QA run #31486 (subject 0647dabb), a neighbour of #29159 (which holds for its own case). Seen once in the browser; the mechanism is confirmed in source.

Reproduction (os dev with OS_AUTH_PHONE_NUMBER_ENABLED=true)

  1. As admin, PUT /api/settings/auth {"email_password_enabled":false} → 200. The auth config then reads emailPassword false, sso false, phoneNumber true, phoneNumberOtp true.
  2. Open /_console/login anonymously: the card shows only "Use a password instead"; the phone and OTP options are not on first paint.
  3. Click it: the form shows "Email or phone number", Password, "Sign in with verification code" and a "Back to single sign-on" button, though no SSO exists.

Mechanism

ui/packages/auth/src/LoginForm.tsx: passwordFormCollapsed = ssoEnforced || passwordSignInOff (line 342), and the backToSsoText button renders on passwordFormCollapsed && showPasswordFallback (line 788). #29159 gated only the copy (ssoOnlyCopy, line 510, which checks ssoEnforced || ssoEnabled); the collapse and the back button are not gated on SSO being present.

Owning package: @object-ui/auth (ui/packages/auth). Full evidence: #31486, slice C3a.

Activity

  1. added
    bug
    domain:ui
    pm:queue
    priority:p2
    on Nov 8, 2026
  2. objectstack-fleet commented on Nov 8, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U

    Path: none

    Triage: audit · p2 · domain:ui · 2026-11-08T12:00Z

    ⛔ Not a claim.


    Generated by Claude Code

  3. objectstack-fleet commented on Nov 8, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jVEjiYrK7onirxUGyo

    Claim: PM loop round 1 · 2026-11-08T12:15Z
    Session: session_01QsR2jTpDZ3S2UNafH1sonG (card thread, dev) · seat session_01QsR2jVEjiYrK7onirxUGyo
    Account: zhuangjianguo
    Branch: claude/project-thread-houx42
    Worktree: objectstack-issue-31492
    Domain: domain:ui
    Seat: domain:ui#3
    File surface: ui/packages/auth/src/LoginForm.tsx, its tests, locale packs only if a label changes, root .changeset/; ⛔ no server or packages/spec/** change
    Container & model: S, mode:thread, model: default tier (dispatch-gates --tier: no path-derived mandate), effort: high
    Clause-②: no
    Metadata-protocol: none
    Responsibility: ui/packages/auth/src/LoginForm.tsx passwordFormCollapsed (L342) in objectstack collapses on passwordSignInOff without asking whether SSO exists | the platform path is the advertised auth config (features.sso, features.ssoEnforced, features.phoneNumber, features.phoneNumberOtp) | a deployment that signs in by phone only; its users get a login card without the way in
    Thread-read: 6721218702
    Premise: holds: passwordFormCollapsed = ssoEnforced || passwordSignInOff (L342) and the back button on passwordFormCollapsed && showPasswordFallback (L788), on origin/main 58f66b937
    Serial constraints cleared: other domain:ui cards in build on this seat are #31472, #31492, #31494 and #27482, on disjoint source files; any shared locale-pack lines are serialised by the merge queue

    Scope: the card's Reproduction and Mechanism. Not collapsed and no back-to-SSO button when no SSO is offered or enforced and a phone way in is; every other config cell unchanged. PR says Fixes #31492. Brief: /mnt/project-files/issue-31492/brief.md.

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

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jTpDZ3S2UNafH1sonG
    os-dev-report

    {
      "issue": 31492,
      "status": "done",
      "branch": "claude/project-thread-houx42",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/31533",
      "head": "3a40e3e1",
      "session": "session_01QsR2jTpDZ3S2UNafH1sonG",
      "premise_still_valid": true,
      "summary": "LoginForm no longer collapses into the single sign-on view when the password door is shut, no SSO is offered (features.sso) or enforced (features.ssoEnforced) and a phone way in is advertised: passwordFormCollapsed = ssoEnforced || (passwordSignInOff && (ssoEnabled || !phoneSignInOffered)). The phone+password form and the OTP link are on first paint; an OTP-only server opens on the OTP step with no switch to a refused password form (formMode); the identifier reads 'Phone number' via the existing phoneLabel/phonePlaceholder labels (no new key); sign-up stays hidden and the host password-form description is not drawn while emailPassword.enabled is false. The back-to-SSO button keeps its condition and is now reachable only where SSO is enforced or offered (argued in the PR body). Every other config cell is unchanged.",
      "tests": "cd ui && vitest run packages/auth/src/__tests__/ (locked): base d02c99edc 45 files/398 tests passed; f0a0c9c0 45/405 passed; head 3a40e3e1 45/405 passed. New: 7 cases in one top-level describe in noSignInMethod-29159.test.tsx (phone both ways, OTP step, phone-password submit, OTP only, phone-password only, CONTROL sso advertised, CONTROL enforced); one existing case there edited (it clicked the break-glass link to reach the OTP link, which was the defect). Ablation via scripts/ablation-replace.mjs on committed f0a0c9c0: passwordFormCollapsed restored to 'ssoEnforced || passwordSignInOff', anchor 1->0, blob af50e015->7530ce6b; file 6 failed/10 passed (the 5 phone-only cases plus the edited case; both CONTROLs green); restored blob == HEAD af50e015, git diff HEAD empty. No rebuild needed: tests import ../LoginForm from src. turbo type-check --filter=@object-ui/auth exit 0 on both heads; eslint on both touched files exit 0.",
      "gates": "dispatch-gates --commands derived 36 (same list on f0a0c9c0 and 3a40e3e1). On head 3a40e3e1: node scripts/check-adr-0087-registration.mjs --base origin/main :: exit 0; node scripts/check-adr-0087-registration.mjs --self-test :: exit 0; node scripts/check-changeset-no-major.mjs --base origin/main :: exit 0; node scripts/check-closing-keyword-parity.mjs :: exit 0; node scripts/check-closing-keyword-parity.mjs --self-test :: exit 0; node scripts/check-comment-mask-corpus.mjs :: exit 0; node scripts/check-empty-changeset.mjs --base origin/main :: exit 0; node scripts/check-empty-changeset.mjs --self-test :: exit 0; node scripts/check-sdui-manifest.mjs :: exit 0; node scripts/check-sdui-manifest.mjs --self-test :: exit 0; node scripts/ci/snapshot-next.mjs --self-test :: exit 0; node scripts/pm/release-rehearsal-clone.mjs --self-test :: exit 0; node scripts/release-pending-publish.mjs --self-test :: exit 0; pnpm --filter @objectstack/spec run check:duration-unit-keys :: exit 0; pnpm check:changeset-gate-self-tests :: exit 0; pnpm check:closed-ceremony-text :: exit 0; pnpm check:cross-package-test-inputs :: exit 0; pnpm check:dispatcher-error-vocabulary :: exit 0; pnpm check:driver-memory-census :: exit 0; pnpm check:engine-double-contract :: exit 0; pnpm check:gitlink-declared :: exit 0; pnpm check:nul-bytes :: exit 0; pnpm check:published-files :: exit 0; pnpm check:query-options-erasure :: exit 0; pnpm check:refd-timer-probe :: exit 0; pnpm check:registry-log-declared :: exit 0; pnpm check:rest-log-spy-declared :: exit 0; pnpm check:skill-identifier-liveness :: exit 0; pnpm check:test-source-alias :: exit 0; pnpm check:tier-file-adoption :: exit 0; pnpm check:type-check-coverage :: exit 0; pnpm check:type-check-debt :: exit 0; pnpm check:undeclared-dep-imports :: exit 0; pnpm check:watch-hint-literal :: exit 0; pnpm check:where-matcher :: exit 0; pnpm --dir ui exec vitest run scripts/ :: exit 0. --ran: 36 derived, 36 run, 0 NOT-MEASURED. Body gates on the final PR body: check-changeset-no-major, check-adr-0087-registration, check-closing-keyword-parity, check-partof-closing-keyword all exit 0. PR check-runs: in_progress at report time.",
      "line_budget": "3 files, +217/-25 vs origin/main (LoginForm.tsx +56/-20, noSignInMethod-29159.test.tsx +145/-5, changeset +16)",
      "files_changed": [
        ".changeset/31492-phone-only-login-card.md",
        "ui/packages/auth/src/LoginForm.tsx",
        "ui/packages/auth/src/__tests__/noSignInMethod-29159.test.tsx"
      ],
      "deviations": [
        "noSignInMethod-29159.test.tsx: one existing case edited (it pinned the click-through to the OTP link that the card calls the defect) and its client helper took an overrides argument; inside the claim surface ('its tests'), named here.",
        "Two behaviours beyond the bare collapse, both inside LoginForm.tsx: OTP-only servers open on the OTP step (the uncollapsed card would otherwise draw a refused email+password form on first paint), and the host password-form description is not drawn while email+password is off. The sign-up link is gated on passwordSignInOff explicitly so it stays hidden as before.",
        "Identifier label changed to 'Phone number' with the password door shut and phone+password on, via existing phoneLabel/phonePlaceholder; no locale key, Clause-② stays no.",
        "Main merged once before pr_create (f4b1f9ee, no auth overlap); main moved 5 more commits by pr_create, none touching ui/packages/auth, not merged.",
        "No live dogfood shot (optional per brief).",
        "Full ui vitest and full pnpm test not run locally; the touched package's whole suite and ui scripts/ were. CI Test UI runs the rest."
      ],
      "dogfood_battery": "n/a — no ! in the PR title and no (narrowing) arm",
      "mcp_calls": "3 — mcp__github__issue_read x3 (get, get_comments x2); reads only",
      "api_writes": "2 — relay pr_create (repository_dispatch, fleet-write run 42485066231, PR #31533, body read back identical 8279 bytes); this os-dev-report comment via post-stamped. Plus 2 git pushes (not REST).",
      "open_questions": [],
      "security_findings": "none",
      "out_of_scope_findings": [
        "class: a (candidate) · reach: NOT MEASURED, source reading of LoginForm on 3a40e3e1 only, so the seat decides whether it is filed · password off + SSO offered + phone OTP on and phone+password off: the card collapses (unchanged by this card's ruling) and breakGlassOffered is false, so the OTP way in is unreachable · dedupe words: LoginForm OTP unreachable SSO collapse breakGlassOffered",
        "carrier: none · noted, not filed: with password off, no SSO, a phone way in and a social provider, the provider divider still reads 'or continue with email' (copy)"
      ]
    }
  6. objectstack-fleet commented on Nov 8, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jVEjiYrK7onirxUGyo

    ACCEPT → PR #31533 comment 6722230687 · 2026-11-08T13:42Z · head 3a40e3e1 (a shut password door with a phone way in and no SSO draws the phone sign-in on first paint, with no back-to-SSO button; 242 lines, not governed, Fixes #31492). Clause-② no. Landing through the merge queue.

  7. objectstack-fleet commented on Nov 8, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:ui#3 · zhuangjianguo · session_01QsR2jVEjiYrK7onirxUGyo

    Landed · 2026-11-08T14:00Z

    Reading Value
    PR #31533 MERGED 2026-11-08T13:59:12Z, merge commit 8a8381477ef3fdb5255452cb51cf643ec6a72beb on main
    #31492 closed completed by the PR's Fixes; labels bug, priority:p2, domain:ui (pm:dispatched removed)

    Delivered: with email+password off, no single sign-on offered or enforced and a phone way in, the Console login card draws the phone sign-in on first paint (an OTP-only server opens on the OTP step), the identifier reads "Phone number", and no "Back to single sign-on" button is drawn. Every other configuration cell is unchanged. Remaining: none filed. Read from source only: password off with SSO offered and OTP only still keeps OTP behind the collapse; its reach is not measured.

  8. removed
    pm:dispatched
    on Nov 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugdomain:uipriority:p2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions