openclaw/src
Josh Lehman 6bd480ea1f
fix: honor explicit auth profile selection (#62744)
* Auth: fix native model profile selection

Fix native `/model ...@profile` targeting so profile selections persist onto the intended session, and preserve explicit session auth-profile overrides even when stored auth order prefers another profile. Update the reply/session regressions to use placeholder example.test profile ids.

Regeneration-Prompt: |
  Native `/model ...@profile` commands in chat were acknowledging the requested auth profile but later runs still used another account. Fix the target-session handling so native slash commands mutate the real chat session rather than a slash-session surrogate, and keep explicit session auth-profile overrides from being cleared just because stored provider order prefers another profile. Update the tests to cover the target-session path and the override-preservation behavior, and use placeholder profile ids instead of real email addresses in test fixtures.

* Auth: honor explicit user-locked profiles in runner

Allow an explicit user-selected auth profile to run even when per-agent auth-state order excludes it. Keep auth-state order for automatic selection and failover, and add an embedded runner regression that seeds stored order with one profile while verifying a different user-locked profile still executes.

Regeneration-Prompt: |
  The remaining bug after fixing native `/model ...@profile` persistence was in the embedded runner itself. A user could explicitly select a valid auth profile for a provider, but the run still failed if per-agent auth-state order did not include that profile. Preserve the intended semantics by validating user-locked profiles directly for provider match and credential eligibility, then using them without requiring membership in resolved auto-order. Add a regression in the embedded auth-profile rotation suite where stored order only includes one OpenAI profile but a different user-locked profile is chosen and must still be used.

* Changelog: note explicit auth profile selection fix

Add the required Unreleased changelog line for the explicit auth-profile selection and runner honor fix in this PR.

Regeneration-Prompt: |
  The PR needed a mandatory CHANGELOG.md entry under Unreleased/Fixes. Add a concise user-facing line describing that native `/model ...@profile` selections now persist on the target session and explicit user-locked OpenAI Codex auth profiles are honored even when per-agent auth order excludes them, and include the PR number plus thanks attribution for the PR author.
2026-04-07 16:12:25 -07:00
..
acp refactor: dedupe acp lowercase helpers 2026-04-07 15:53:50 +01:00
agents fix: honor explicit auth profile selection (#62744) 2026-04-07 16:12:25 -07:00
auto-reply fix: honor explicit auth profile selection (#62744) 2026-04-07 16:12:25 -07:00
bindings
bootstrap
canvas-host refactor: dedupe locale lowercase helpers 2026-04-07 22:57:52 +01:00
channels refactor: dedupe channel trimmed readers 2026-04-08 00:09:42 +01:00
chat refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
cli fix(test): align exec approvals expectations 2026-04-07 23:57:46 +01:00
commands refactor: dedupe command trimmed readers 2026-04-08 00:09:41 +01:00
compat
config refactor: dedupe command config lowercase helpers 2026-04-07 20:57:03 +01:00
context-engine feat: expose prompt-cache runtime context to context engines (#62179) 2026-04-07 09:29:57 -07:00
cron refactor: dedupe core trimmed string readers 2026-04-07 22:57:52 +01:00
daemon refactor: dedupe normalization lowercase helpers 2026-04-07 22:57:52 +01:00
docs
flows fix: restore ci after trim reader dedupe 2026-04-07 06:42:34 +01:00
gateway refactor: dedupe gateway trimmed readers 2026-04-08 00:09:42 +01:00
hooks refactor: dedupe normalization lowercase helpers 2026-04-07 22:57:52 +01:00
i18n
image-generation refactor: dedupe lowercase helper readers 2026-04-07 15:12:32 +01:00
infra perf(test): trim infra provider and approval suites 2026-04-08 00:10:20 +01:00
interactive refactor: dedupe reply lowercase helpers 2026-04-07 10:37:39 +01:00
link-understanding
logging refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
markdown
mcp refactor: dedupe core lowercase helpers 2026-04-07 20:58:01 +01:00
media refactor: dedupe media and discord lowercase helpers 2026-04-07 13:44:41 +01:00
media-generation fix(test): restore support shard boundaries 2026-04-07 08:59:23 +01:00
media-understanding refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
memory-host-sdk refactor: dedupe remaining lowercase helpers 2026-04-07 22:57:52 +01:00
music-generation refactor: dedupe lowercase helper readers 2026-04-07 15:12:32 +01:00
node-host refactor: dedupe core lowercase helpers 2026-04-07 20:58:01 +01:00
pairing refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
plugin-sdk refactor: move qa suite definitions into markdown 2026-04-07 23:39:50 +01:00
plugins refactor: dedupe core trimmed string readers 2026-04-07 22:57:52 +01:00
process refactor: dedupe path lowercase helpers 2026-04-07 15:53:50 +01:00
realtime-transcription refactor: dedupe provider registry normalizers 2026-04-07 10:37:38 +01:00
realtime-voice refactor: dedupe provider registry normalizers 2026-04-07 10:37:38 +01:00
routing refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
scripts test: stabilize scoped runners and qa ports 2026-04-07 15:28:46 +01:00
secrets refactor: dedupe lowercase helper readers 2026-04-07 15:12:32 +01:00
security refactor: dedupe extension lowercase helpers 2026-04-07 15:12:32 +01:00
sessions refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
shared refactor: dedupe channel trimmed readers 2026-04-08 00:09:42 +01:00
tasks refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
terminal refactor: dedupe infra lowercase helpers 2026-04-07 15:53:50 +01:00
test-helpers refactor: dedupe extension lowercase helpers 2026-04-07 15:12:32 +01:00
test-utils refactor: dedupe path lowercase helpers 2026-04-07 22:57:52 +01:00
tts refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
tui refactor: dedupe core lowercase helpers 2026-04-07 20:58:01 +01:00
types
utils refactor: dedupe provider lowercase helpers 2026-04-07 15:53:50 +01:00
video-generation refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
web
web-fetch fix(build): drop duplicate web fetch helper 2026-04-07 13:34:20 +01:00
web-search refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
wizard refactor: dedupe misc lowercase helpers 2026-04-07 22:24:32 +01:00
browser-lifecycle-cleanup.test.ts
browser-lifecycle-cleanup.ts
channel-web.ts
docker-build-cache.test.ts
docker-image-digests.test.ts
docker-setup.e2e.test.ts
dockerfile.test.ts fix: make qa lab docker boot resilient 2026-04-07 09:04:18 +01:00
entry.respawn.test.ts
entry.respawn.ts
entry.test.ts
entry.ts
entry.version-fast-path.test.ts
extensionAPI.ts
global-state.ts
globals.ts
index.test.ts
index.ts
install-sh-version.test.ts
library.test.ts
library.ts
logger.test.ts
logger.ts
logging.ts
param-key.ts refactor: dedupe remaining lowercase helpers 2026-04-07 22:57:52 +01:00
plugin-activation-boundary.test.ts Config: split static channel configured helper 2026-04-07 13:07:40 +08:00
poll-params.test.ts
poll-params.ts refactor: dedupe daemon lowercase helpers 2026-04-07 13:44:42 +01:00
polls.test.ts
polls.ts
runtime.ts
ui-app-settings.agents-files-refresh.test.ts
utils.test.ts feat: Add first-class infer CLI for inference workflows (#62129) 2026-04-07 07:11:19 -05:00
utils.ts feat: Add first-class infer CLI for inference workflows (#62129) 2026-04-07 07:11:19 -05:00
version.test.ts
version.ts refactor: dedupe helper trim readers 2026-04-07 08:40:34 +01:00