openclaw/src
JK 323030594e
fix(agents): resolve model aliases in sessions_spawn (#59681)
* fix(agents): resolve model aliases in sessions_spawn

normalizeModelSelection() only trims the input — it never resolves
aliases through the model alias index. When a user passes an alias
like 'opus' to sessions_spawn, the child session gets patched with
the raw string, which the gateway cannot match to any provider.

Add resolveModelThroughAliases() to check bare strings against the
configured alias map before returning from
resolveSubagentSpawnModelSelection().

Fixes #57532
Refs #50736

* refactor: address review feedback on alias resolution

- Accept pre-built ModelAliasIndex instead of rebuilding per call
- Narrow helper signature to (string, ModelAliasIndex) → string
- Remove unreachable ?? raw fallback

Co-Authored-By: greptile-apps[bot]

* fix(agents): resolve sessions_spawn model aliases

---------

Co-authored-by: HowdyDooToYou <HowdyDooToYou@users.noreply.github.com>
Co-authored-by: vincentkoc <25068+vincentkoc@users.noreply.github.com>
2026-04-27 15:44:56 -07:00
..
acp fix(acp): allow manual spawn with dispatch paused 2026-04-27 14:40:12 +01:00
agents fix(agents): resolve model aliases in sessions_spawn (#59681) 2026-04-27 15:44:56 -07:00
auto-reply fix(models): keep user model switches strict 2026-04-27 23:32:44 +01:00
bindings
bootstrap
canvas-host chore: update a2ui bundle hash 2026-04-27 11:10:12 +01:00
channels fix(tts): pre-transcode synthesized audio to opus-in-CAF for native iMessage voice-memo bubbles via BlueBubbles (#72586) 2026-04-27 14:15:16 -07:00
chat
cli fix(cli): fail empty local model probes 2026-04-27 23:16:39 +01:00
commands fix(models): keep user model switches strict 2026-04-27 23:32:44 +01:00
compat
config fix(agent): preserve default-agent session routing compatibility (#72414) 2026-04-27 15:09:01 -07:00
context-engine
crestodian perf(test): route more unit tests through fast lane 2026-04-27 17:01:16 +01:00
cron fix(ci): sync locale and cron contract tests 2026-04-27 13:15:59 +01:00
daemon fix(doctor): avoid companion gateway service false positives 2026-04-27 23:30:29 +01:00
docs
flows refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
gateway test: cover trusted-proxy secret surfaces 2026-04-27 23:10:22 +01:00
hooks refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
i18n test: reduce repeated test setup overhead 2026-04-27 13:33:05 +01:00
image-generation test: speed up focused test setup 2026-04-27 13:00:43 +01:00
infra fix(gateway): keep startup sidecars responsive 2026-04-27 22:44:37 +01:00
interactive
link-understanding
logging fix(agents): redact Control UI tool payload secrets (#72319) 2026-04-27 23:30:50 +01:00
markdown
mcp refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
media fix(tts): pre-transcode synthesized audio to opus-in-CAF for native iMessage voice-memo bubbles via BlueBubbles (#72586) 2026-04-27 14:15:16 -07:00
media-generation
media-understanding fix(media): anchor sanitizeMimeType regex and reject trailing junk 2026-04-27 21:02:30 +01:00
memory
memory-host-sdk perf(test): route memory dreaming through unit-fast 2026-04-27 15:03:21 +01:00
model-catalog fix: narrow manifest alias overrides 2026-04-27 17:13:11 +01:00
music-generation
node-host refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
pairing test: reduce repeated test setup overhead 2026-04-27 13:33:05 +01:00
plugin-sdk refactor: route plugin test helpers through sdk 2026-04-27 23:12:21 +01:00
plugins ci: shard release validation reruns 2026-04-27 23:38:13 +01:00
process fix: isolate cron nested lane concurrency 2026-04-27 09:39:10 +01:00
proxy-capture revert(acp): remove Coven bridge 2026-04-27 11:26:05 -07:00
realtime-transcription
realtime-voice feat: add browser realtime talk transports 2026-04-27 14:22:32 +01:00
routing
scripts test: move more setup-free tests to unit-fast 2026-04-27 13:56:21 +01:00
secrets test: cover trusted-proxy secret surfaces 2026-04-27 23:10:22 +01:00
security fix: skip test-only plugin install scan findings 2026-04-27 15:00:55 +01:00
sessions
shared fix(agents): recover unclosed reasoning-only replies 2026-04-27 12:45:11 +01:00
status
tasks fix(gateway): unblock sidecar startup 2026-04-27 21:34:44 +01:00
terminal
test-helpers
test-utils fix(security): harden CodeQL secret ref validation 2026-04-27 13:53:27 -07:00
trajectory fix: clean up trajectory sidecars 2026-04-27 20:58:28 +01:00
tts perf(test): route speech provider registry through unit-fast 2026-04-27 16:16:12 +01:00
tui refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
types refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
utils
video-generation test: speed up focused test setup 2026-04-27 13:00:43 +01:00
web
web-fetch
web-search
wizard refactor(config): migrate plugin config access 2026-04-27 12:35:58 +01:00
browser-lifecycle-cleanup.test.ts test: reduce repeated test setup overhead 2026-04-27 13:33:05 +01:00
browser-lifecycle-cleanup.ts
channel-web.ts
docker-build-cache.test.ts test: cache dockerfile fixture reads 2026-04-27 12:42:29 +01:00
docker-image-digests.test.ts
docker-setup.e2e.test.ts
dockerfile.test.ts fix(feishu): preserve disabled group policy for explicit groups 2026-04-27 21:55:33 +01:00
entry.compile-cache.test.ts fix(cli): disable source checkout compile cache 2026-04-27 23:28:17 +01:00
entry.compile-cache.ts fix(cli): disable source checkout compile cache 2026-04-27 23:28:17 +01:00
entry.respawn.test.ts fix(cli): skip respawn for foreground gateway 2026-04-27 15:01:33 +01:00
entry.respawn.ts
entry.test.ts perf(test): route more unit tests through fast lane 2026-04-27 17:01:16 +01:00
entry.ts fix(cli): disable source checkout compile cache 2026-04-27 23:28:17 +01:00
entry.version-fast-path.test.ts
entry.version-fast-path.ts
extensionAPI.ts
global-state.ts
globals.ts
index.test.ts
index.ts fix(gateway): ignore broken pipe crashes 2026-04-27 20:17:04 +01:00
install-sh-version.test.ts test: reduce repeated test setup overhead 2026-04-27 13:33:05 +01:00
library.test.ts perf(test): route more unit tests through fast lane 2026-04-27 17:01:16 +01:00
library.ts
logger.test.ts
logger.ts
logging.ts
param-key.ts
plugin-activation-boundary.test.ts test: speed up plugin activation boundary test 2026-04-27 12:35:31 +01:00
poll-params.test.ts refactor: move telegram poll visibility out of core 2026-04-27 12:25:57 +01:00
poll-params.ts refactor: move telegram poll visibility out of core 2026-04-27 12:25:57 +01:00
polls.test.ts
polls.ts test: guard plugin boundary classifications 2026-04-27 12:35:43 +01:00
runtime.ts
ui-app-settings.agents-files-refresh.test.ts
utils.test.ts perf(test): route more unit tests through fast lane 2026-04-27 17:01:16 +01:00
utils.ts
version.test.ts
version.ts