#9045: fix: add clear error message for legacy root-level aliases key
stale
Cluster:
Model Alias Fixes
## Problem
Fixes #7820
Users with root-level `aliases` in their config (valid in older versions) get a confusing Zod schema error when the gateway fails to start:
```
Unrecognized key(s) in object: 'aliases'
```
## Solution
Add `aliases` to the legacy config rules so users get a clear, actionable error message:
```
Root-level "aliases" is no longer supported. Use `openclaw models aliases add <alias> <model>` to configure model aliases.
```
## Change
Added to `LEGACY_CONFIG_RULES` in `legacy.rules.ts`:
```typescript
{
path: ["aliases"],
message:
'Root-level "aliases" is no longer supported. Use `openclaw models aliases add <alias> <model>` to configure model aliases.',
},
```
Most Similar PRs
#16104: fix: implement model aliases for /model command
by MisterGuy420 · 2026-02-14
65.8%
#20080: fix: resolve model aliases correctly when keyed by short name
by kamal-ayman · 2026-02-18
62.1%
#20049: fix(model-selection): resolve short-name alias keys correctly
by widingmarcus-cyber · 2026-02-18
59.6%
#22870: fix(config): allow modelByChannel in channels validation allowlist
by darcuri · 2026-02-21
59.0%
#23688: fix(gateway): accept raw IP addresses in gateway.bind for backward ...
by arosstale · 2026-02-22
58.7%
#19020: bugfix(gateway): Handle invalid model provider API config gracefully\…
by funkyjonx · 2026-02-17
58.2%
#19429: Fix/custom bind host validation
by frudas24 · 2026-02-17
56.8%
#8252: Config: honor legacy memorySearch alias
by sauerdaniel · 2026-02-03
55.8%
#10807: fix(config): coerce numeric meta.lastTouchedAt to ISO string
by mcaxtr · 2026-02-07
55.8%
#17021: fix(agents): read models from gateway config first
by Limitless2023 · 2026-02-15
55.6%