Skip to content

bug(platform): failed custom-provider credential edit still changes the provider URL and name #3662

Closed

Description

@yannickmonney

P1 · Reproduced locally at 44e0dcf254975286c0e9dea443b5cd1ca6b23347.

A failed save can redirect every credential using this custom provider to a new URL; cancelling the visible failed form leaves that global change active.

Reproduction:

  1. Create a custom provider with at least two credentials named A and B.
  2. Edit credential A; change its Base URL and enter the already-used credential name B.
  3. Save. The credential rename is rejected as a duplicate. Cancel the dialog.
  4. Read the provider definition and credential A again.

Expected: A rejected edit must preserve the previous provider definition and credential, or clearly report a partial save and provide recovery. Cancel must not leave an unacknowledged endpoint change.

Observed: The provider definition PUT succeeds first. The credential POST returns HTTP 409 CREDENTIAL_NAME_TAKEN. Credential A retains its old name, but the provider URL and display name have already changed and remain changed after Cancel.

Cause: useUpdateProviderCredential commits the definition at lines 198–204, then returns the credential update at line 206 without rollback or atomic validation. The UI presents both as one edit.

Frozen observation/control output:

CONFIRMED provider definition PUT=200; credential rename POST=409 CREDENTIAL_NAME_TAKEN; original credential unchanged; edited base URL and provider name survive Cancel

Control: The duplicate rename is refused by the real server and the credential name remains unchanged. The same probe confirms explicit modelAllowlist:null clearing succeeds through the real hook and adapter.

Exact probe command (5/5 tests passed; cwd is the detached source services/platform directory):

/Users/yannick/.npm/_npx/22f2fe8d8bc13000/node_modules/.bin/bun x vitest run --config /Users/yannick/.codex/notes/tale-100-findings/provider-connector-proof/vitest.config.ts /Users/yannick/.codex/notes/tale-100-findings/provider-connector-proof/provider-boundaries.probe.test.tsx --maxWorkers 1 --testTimeout 30000 --reporter verbose --silent=false

Proof boundary: Executed the actual CredentialEditDialog, provider credential adapter, mutation hooks, HTTP adapters and native localhost:3076 API. Reads after writes used the real persisted config/DB. Only owned local provider/credential fixtures were used; env references carry no credential secret and catalog source remained none in persisted definitions. No model, external provider or OAuth request ran. The component harness supplies catalog/credential props and a query client; this is not a browser run.

Source:

Deduplication: Cached all-state provider/credential issue titles and the current findings ledger reviewed. #2368 concerns differing old editors and #1387 an uneditable name; neither covers a rejected edit partially committing the provider definition. Parent performs live all-state dedup.

Independent parent verification: read the complete proof and reran all five tests against the retained owned localhost fixtures. All passed, including the native stale-hash refusal and post-failure persisted readbacks. Live all-state provider/credential/save, provider/stale and provider/manual-model searches found no matching root. Log: provider-connector-proof/parent-provider-boundaries.log.

Activity

  1. changed the title [-]bug(platform): bug: failed custom-provider credential edit still changes the provider URL and name[/-] [+]bug(platform): failed custom-provider credential edit still changes the provider URL and name[/+] on Sep 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugservice: platform

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions