Vincent Koc
e4d80ed556
CI: restore main detect-secrets scan ( #38438 )
...
* Tests: stabilize detect-secrets fixtures
* Tests: fix rebased detect-secrets false positives
* Docs: keep snippets valid under detect-secrets
* Tests: finalize detect-secrets false-positive fixes
* Tests: reduce detect-secrets false positives
* Tests: keep detect-secrets pragmas inline
* Tests: remediate next detect-secrets batch
* Tests: tighten detect-secrets allowlists
* Tests: stabilize detect-secrets formatter drift
2026-03-07 10:06:35 -08:00
Peter Steinberger
b7733d6f5c
refactor(agents): dedupe oauth token env setup tests
2026-03-07 17:58:31 +00:00
Florian Hines
33e7394861
fix(providers): make all models available in kilocode provider ( #32352 )
...
* kilocode: dynamic model discovery, kilo/auto default, cooldown exemption
- Replace 9-model hardcoded catalog with dynamic discovery from
GET /api/gateway/models (Venice-like pattern with static fallback)
- Default model changed from anthropic/claude-opus-4.6 to kilo/auto
(smart routing model)
- Add createKilocodeWrapper for X-KILOCODE-FEATURE header injection
and reasoning.effort handling (skip for kilo/auto)
- Add kilocode to cooldown-exempt providers (proxy like OpenRouter)
- Keep sync buildKilocodeProvider for onboarding, add async
buildKilocodeProviderWithDiscovery for implicit provider resolution
- Per-token gateway pricing converted to per-1M-token for cost fields
* kilocode: skip reasoning injection for x-ai models, harden discovery loop
* fix(kilocode): keep valid discovered duplicates (openclaw#32352, thanks @pandemicsyn)
* refactor(proxy): normalize reasoning payload guards (openclaw#32352, thanks @pandemicsyn)
* chore(changelog): note kilocode hardening (openclaw#32352, thanks @pandemicsyn and @vincentkoc)
* chore(changelog): fix kilocode note format (openclaw#32352, thanks @pandemicsyn and @vincentkoc)
* test(kilocode): support auto-model override cases (openclaw#32352, thanks @pandemicsyn)
* Update CHANGELOG.md
---------
Co-authored-by: Vincent Koc <vincentkoc@ieee.org >
2026-03-07 08:14:06 -08:00
Vincent Koc
42e3d8d693
Secrets: add inline allowlist review set ( #38314 )
...
* Secrets: add inline allowlist review set
* Secrets: narrow detect-secrets file exclusions
* Secrets: exclude Docker fingerprint false positive
* Secrets: allowlist test and docs false positives
* Secrets: refresh baseline after allowlist updates
* Secrets: fix gateway chat fixture pragma
* Secrets: format pre-commit config
* Android: keep talk mode fixture JSON valid
* Feishu: rely on client timeout injection
* Secrets: allowlist provider auth test fixtures
* Secrets: allowlist onboard search fixtures
* Secrets: allowlist onboard mode fixture
* Secrets: allowlist gateway auth mode fixture
* Secrets: allowlist APNS wake test key
* Secrets: allowlist gateway reload fixtures
* Secrets: allowlist moonshot video fixture
* Secrets: allowlist auto audio fixture
* Secrets: allowlist tiny audio fixture
* Secrets: allowlist embeddings fixtures
* Secrets: allowlist resolve fixtures
* Secrets: allowlist target registry pattern fixtures
* Secrets: allowlist gateway chat env fixture
* Secrets: refresh baseline after fixture allowlists
* Secrets: reapply gateway chat env allowlist
* Secrets: reapply gateway chat env allowlist
* Secrets: stabilize gateway chat env allowlist
* Secrets: allowlist runtime snapshot save fixture
* Secrets: allowlist oauth profile fixtures
* Secrets: allowlist compaction identifier fixture
* Secrets: allowlist model auth fixture
* Secrets: allowlist model status fixtures
* Secrets: allowlist custom onboarding fixture
* Secrets: allowlist mattermost token summary fixtures
* Secrets: allowlist gateway auth suite fixtures
* Secrets: allowlist channel summary fixture
* Secrets: allowlist provider usage auth fixtures
* Secrets: allowlist media proxy fixture
* Secrets: allowlist secrets audit fixtures
* Secrets: refresh baseline after final fixture allowlists
* Feishu: prefer explicit client timeout
* Feishu: test direct timeout precedence
2026-03-06 19:35:26 -05:00
Altay
6e962d8b9e
fix(agents): handle overloaded failover separately ( #38301 )
...
* fix(agents): skip auth-profile failure on overload
* fix(agents): note overload auth-profile fallback fix
* fix(agents): classify overloaded failures separately
* fix(agents): back off before overload failover
* fix(agents): tighten overload probe and backoff state
* fix(agents): persist overloaded cooldown across runs
* fix(agents): tighten overloaded status handling
* test(agents): add overload regression coverage
* fix(agents): restore runner imports after rebase
* test(agents): add overload fallback integration coverage
* fix(agents): harden overloaded failover abort handling
* test(agents): tighten overload classifier coverage
* test(agents): cover all-overloaded fallback exhaustion
* fix(cron): retry overloaded fallback summaries
* fix(cron): treat HTTP 529 as overloaded retry
2026-03-07 01:42:11 +03:00
Vignesh Natarajan
fa3fafdde5
fix(auth): harden openai-codex oauth refresh fallback
2026-03-05 19:17:58 -08:00
Josh Avant
1c200ca7ae
follow-up: align ingress, atomic paths, and channel tests with credential semantics ( #33733 )
...
Merged via squash.
Prepared head SHA: c290c2ab6a
Co-authored-by: joshavant <830519+joshavant@users.noreply.github.com >
Co-authored-by: joshavant <830519+joshavant@users.noreply.github.com >
Reviewed-by: @joshavant
2026-03-03 20:29:46 -06:00
Shadow
e28ff1215c
fix: discord auto presence health signal ( #33277 ) (thanks @thewilloftheshadow) ( #33277 )
2026-03-03 11:20:59 -06:00
Peter Steinberger
9617ac9dd5
refactor: dedupe agent and reply runtimes
2026-03-02 19:57:33 +00:00
Peter Steinberger
ea1fe77c83
fix: normalize coding-plan providers in auth order validation
2026-03-02 19:26:09 +00:00
justinhuangcode
aab87ec880
fix(agents): scope volcengine-plan/byteplus-plan auth lookup to profile resolution
...
The configure flow stores auth credentials under `provider: "volcengine"`,
but the coding model uses `volcengine-plan` as its provider. Add a scoped
`normalizeProviderIdForAuth` function used only by `listProfilesForProvider`
so coding-plan variants resolve to their base provider for auth credential
lookup without affecting global provider routing.
Closes #31731
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com >
2026-03-02 19:22:19 +00:00
Frank Yang
ed86252aa5
fix: handle CLI session expired errors gracefully instead of crashing gateway ( #31090 )
...
* fix: handle CLI session expired errors gracefully
- Add session_expired to FailoverReason type
- Add isCliSessionExpiredErrorMessage to detect expired CLI sessions
- Modify runCliAgent to retry with new session when session expires
- Update agentCommand to clear expired session IDs from session store
- Add proper error handling to prevent gateway crashes on expired sessions
Fixes #30986
* fix: add session_expired to AuthProfileFailureReason and missing log import
* fix: type cli-runner usage field to match EmbeddedPiAgentMeta
* fix: harden CLI session-expiry recovery handling
* build: regenerate host env security policy swift
---------
Co-authored-by: Peter Steinberger <steipete@gmail.com >
2026-03-02 01:11:05 +00:00
Peter Steinberger
47fc6a0806
fix: stabilize secrets land + docs note ( #26155 ) (thanks @joshavant)
2026-02-26 14:47:22 +00:00
joshavant
ba2eb583c0
fix(secrets): make apply idempotent and keep audit read-only
2026-02-26 14:47:22 +00:00
joshavant
8944b75e16
fix(secrets): align ref contracts and non-interactive ref persistence
2026-02-26 14:47:22 +00:00
joshavant
4e7a833a24
feat(security): add provider-based external secrets management
2026-02-26 14:47:22 +00:00
joshavant
6a251d8d74
Auth profiles: resolve keyRef/tokenRef outside gateway
2026-02-26 14:47:22 +00:00
joshavant
e1301c31e7
Auth profiles: never persist plaintext when refs are present
2026-02-26 14:47:22 +00:00
joshavant
45ec5aaf2b
Secrets: keep read-only runtime sync in-memory
2026-02-26 14:47:22 +00:00
joshavant
8e33ebe471
Secrets: make runtime activation auth loads read-only
2026-02-26 14:47:22 +00:00
joshavant
b50c4c2c44
Gateway: add eager secrets runtime snapshot activation
2026-02-26 14:47:22 +00:00
Peter Steinberger
8315c58675
refactor(auth-profiles): unify coercion and add rejected-entry diagnostics
2026-02-26 14:42:11 +01:00
lbo728
7e7ca43a79
fix(auth-profiles): accept mode/apiKey aliases to prevent silent credential loss
...
Users following openclaw.json auth.profiles examples (which use 'mode' for
the credential type) would write their auth-profiles.json entries with:
{ provider: "anthropic", mode: "api_key", apiKey: "sk-ant-..." }
The actual auth-profiles.json schema uses:
{ provider: "anthropic", type: "api_key", key: "sk-ant-..." }
coerceAuthStore() and coerceLegacyStore() validated entries strictly on
typed.type, silently skipping any entry that used the mode/apiKey spelling.
The user would get 'No API key found for provider anthropic' with no hint
about the field name mismatch.
Add normalizeRawCredentialEntry() which, before validation:
- coerces mode → type when type is absent
- coerces apiKey → key when key is absent
Both functions now call the normalizer before the type guard so
mode/apiKey entries are loaded and resolved correctly.
Fixes #26916
2026-02-26 13:32:05 +00:00
Aleksandrs Tihenko
c0026274d9
fix(auth): distinguish revoked API keys from transient auth errors ( #25754 )
...
Merged via /review-pr -> /prepare-pr -> /merge-pr.
Prepared head SHA: 8f9c07a200
Co-authored-by: rrenamed <87486610+rrenamed@users.noreply.github.com >
Co-authored-by: gumadeiras <5599352+gumadeiras@users.noreply.github.com >
Reviewed-by: @gumadeiras
2026-02-25 19:47:16 -05:00
Vincent Koc
5de04960a0
Tests: cover OpenRouter cooldown display bypass
2026-02-24 19:12:08 -05:00
Vincent Koc
f1d5c1a31f
Auth: use cooldown helper in explicit profile order
2026-02-24 19:12:08 -05:00
Vincent Koc
daa4f34ce8
Auth: bypass cooldown tracking for OpenRouter
2026-02-24 19:12:08 -05:00
Peter Steinberger
382fe8009a
refactor!: remove google-antigravity provider support
2026-02-23 05:20:14 +01:00
Vignesh Natarajan
5c7c37a02a
Agents: infer auth-profile unavailable failover reason
2026-02-22 16:10:32 -08:00
Peter Steinberger
ad1072842e
test: dedupe agent tests and session helpers
2026-02-22 17:11:54 +00:00
Peter Steinberger
adfbbcf1f6
chore: merge origin/main into main
2026-02-22 13:42:52 +00:00
Peter Steinberger
07527e22ce
refactor(auth-profiles): centralize active-window logic + strengthen regression coverage
2026-02-22 13:23:19 +01:00
Peter Steinberger
7c3c406a35
fix: keep auth-profile cooldown windows immutable in-window ( #23536 ) (thanks @arosstale)
2026-02-22 13:14:02 +01:00
artale
dc69610d51
fix(auth-profiles): never shorten cooldown deadline on retry
...
When the backoff saturates at 60 min and retries fire every 30 min
(e.g. cron jobs), each failed request was resetting cooldownUntil to
now+60m. Because now+60m < existing deadline, the window kept getting
renewed and the profile never recovered without manually clearing
usageStats in auth-profiles.json.
Fix: only write a new cooldownUntil (or disabledUntil for billing) when
the new deadline is strictly later than the existing one. This lets the
original window expire naturally while still allowing genuine backoff
extension when error counts climb further.
Fixes #23516
[AI-assisted]
2026-02-22 13:14:02 +01:00
Peter Steinberger
e441390fd1
test: reclassify agent local suites out of e2e
2026-02-22 11:16:37 +00:00
Peter Steinberger
b03656a771
test(auth-profiles): dedupe oauth mode resolution setup
2026-02-22 07:44:57 +00:00
Peter Steinberger
b257ba9e30
test(auth-profiles): dedupe cleared-state assertions
2026-02-22 07:44:57 +00:00
Peter Steinberger
26eb1f781d
refactor(test): reuse state-dir env helper in auth profile override e2e
2026-02-21 13:00:16 +00:00
mudrii
7ecfc1d93c
fix(auth): bidirectional mode/type compat + sync OAuth to all agents ( #12692 )
...
Merged via /review-pr -> /prepare-pr -> /merge-pr.
Prepared head SHA: 2dee8e1174
Co-authored-by: mudrii <220262+mudrii@users.noreply.github.com >
Co-authored-by: obviyus <22031114+obviyus@users.noreply.github.com >
Reviewed-by: @obviyus
2026-02-20 16:01:09 +05:30
Nabbil Khan
f91034aa6b
fix(auth): clear all usage stats fields in clearAuthProfileCooldown (openclaw#19211) thanks @nabbilkhan
...
Verified:
- pnpm install --frozen-lockfile
- pnpm build
- pnpm check
- pnpm test:macmini
Co-authored-by: nabbilkhan <203121263+nabbilkhan@users.noreply.github.com >
Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com >
2026-02-19 22:21:37 -06:00
Glucksberg
38b4fb5d55
fix(auth/session): preserve override reset behavior and repair oauth profile-id drift (openclaw#18820) thanks @Glucksberg
...
Verified:
- pnpm build
- pnpm check
- pnpm test:macmini
Co-authored-by: Glucksberg <80581902+Glucksberg@users.noreply.github.com >
Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com >
2026-02-19 21:16:26 -06:00
adhitShet
399781aaca
fix: remove duplicate comment in orderProfilesByMode ( #21409 )
...
Merged via /review-pr -> /prepare-pr -> /merge-pr.
Prepared head SHA: 04271651d4
Co-authored-by: adhitShet <131381638+adhitShet@users.noreply.github.com >
Co-authored-by: gumadeiras <5599352+gumadeiras@users.noreply.github.com >
Reviewed-by: @gumadeiras
2026-02-19 19:46:51 -05:00
Peter Steinberger
32a704f630
refactor(auth): share resolve profile params type
2026-02-18 19:02:19 +00:00
Peter Steinberger
79cc4aec80
refactor(auth): share oauth result builders and token expiry checks
2026-02-18 18:54:40 +00:00
Peter Steinberger
63403d47d9
refactor(auth): share oauth profile config checks
2026-02-18 18:25:25 +00:00
Peter Steinberger
28d49b8d44
refactor(auth-profiles): reuse cooldown timestamp resolver
2026-02-18 17:13:47 +00:00
Peter Steinberger
b8b43175c5
style: align formatting with oxfmt 0.33
2026-02-18 01:34:35 +00:00
Peter Steinberger
31f9be126c
style: run oxfmt and fix gate failures
2026-02-18 01:29:02 +00:00
cpojer
d0cb8c19b2
chore: wtf.
2026-02-17 13:36:48 +09:00
Sebastian
ed11e93cf2
chore(format)
2026-02-16 23:20:16 -05:00