You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After the fix in PR #163 (v0.5.1), configuring summaryProvider: "openai-codex" with summaryModel: "gpt-5.4" results in compaction auth failures and 60-second timeouts. The summarizer correctly avoids inheriting the runtime session auth profile (per #162 fix), but then has no auth path to resolve credentials for OAuth-based providers like openai-codex.
Auth profile for openai-codex: OAuth-based (access, refresh, expires, accountId) — no API key
Expected behavior
When an explicit summaryProvider is configured and that provider uses OAuth auth (stored in per-agent auth-profiles), the summarizer should be able to resolve credentials and complete summarization.
Actual behavior
Compaction fails repeatedly with:
[lcm] summarizer timed out; provider=openai-codex; model=gpt-5.4; timeout=60000ms
[lcm] compaction failed: provider auth error. Check that the configured summaryProvider has valid API credentials. Current: openai-codex/gpt-5.4
The main session uses openai-codex without issue — chat completions work fine because the core runtime resolves the OAuth token from auth-profiles.json. But LCM's summarizer, after #163's fix correctly strips the inherited auth profile, ends up with authProfileId = undefined and cannot resolve the OAuth credential on its own.
Root cause analysis
The fix in #163 was correct for its target problem (auth drift from wrong inherited profiles). However, it created a new gap:
Post-fix: avoid summarizer auth-profile leakage #163: summarizer strips inherited auth profile when explicit summaryProvider is set → authProfileId becomes undefined → getApiKey() with no profile ID cannot find OAuth credentials → auth fails → 60s timeout → fallback to truncation
The openai-codex provider in OpenClaw uses OAuth by default (not API keys). The credentials live in per-agent auth-profiles.json files and require an authProfileId to resolve. With that stripped, there's no path to the token.
Workaround
Switch summaryProvider to a provider that uses a standard API key (e.g., openrouter with anthropic/claude-sonnet-4-6), which resolves via the provider config's apiKey field without needing an auth profile.
Suggested fix
When the summarizer has an explicit summaryProvider configured:
Don't inherit the runtime session's auth profile (current behavior, correct)
But do attempt to resolve the auth profile that matches the configured summaryProvider — e.g., look up the default auth profile for that provider, or accept an optional summaryAuthProfile config field
Alternatively, document that OAuth-based providers are unsupported for LCM summarization and require API-key-based providers
Summary
After the fix in PR #163 (v0.5.1), configuring
summaryProvider: "openai-codex"withsummaryModel: "gpt-5.4"results in compaction auth failures and 60-second timeouts. The summarizer correctly avoids inheriting the runtime session auth profile (per #162 fix), but then has no auth path to resolve credentials for OAuth-based providers likeopenai-codex.Environment
{ "summaryProvider": "openai-codex", "summaryModel": "gpt-5.4" }access,refresh,expires,accountId) — no API keyExpected behavior
When an explicit
summaryProvideris configured and that provider uses OAuth auth (stored in per-agent auth-profiles), the summarizer should be able to resolve credentials and complete summarization.Actual behavior
Compaction fails repeatedly with:
The main session uses
openai-codexwithout issue — chat completions work fine because the core runtime resolves the OAuth token fromauth-profiles.json. But LCM's summarizer, after #163's fix correctly strips the inherited auth profile, ends up withauthProfileId = undefinedand cannot resolve the OAuth credential on its own.Root cause analysis
The fix in #163 was correct for its target problem (auth drift from wrong inherited profiles). However, it created a new gap:
summaryProvideris set →authProfileIdbecomesundefined→getApiKey()with no profile ID cannot find OAuth credentials → auth fails → 60s timeout → fallback to truncationThe
openai-codexprovider in OpenClaw uses OAuth by default (not API keys). The credentials live in per-agentauth-profiles.jsonfiles and require anauthProfileIdto resolve. With that stripped, there's no path to the token.Workaround
Switch
summaryProviderto a provider that uses a standard API key (e.g.,openrouterwithanthropic/claude-sonnet-4-6), which resolves via the provider config'sapiKeyfield without needing an auth profile.Suggested fix
When the summarizer has an explicit
summaryProviderconfigured:summaryProvider— e.g., look up the default auth profile for that provider, or accept an optionalsummaryAuthProfileconfig fieldRelated