Skip to content

fix(auxiliary): pass original base_url to _maybe_wrap_anthropic in compression path - #21368

Closed
crayfish-ai wants to merge 2 commits into
NousResearch:mainfrom
crayfish-ai:crayfish-ai/pr-auxiliary-base-url-fix
Closed

fix(auxiliary): pass original base_url to _maybe_wrap_anthropic in compression path#21368
crayfish-ai wants to merge 2 commits into
NousResearch:mainfrom
crayfish-ai:crayfish-ai/pr-auxiliary-base-url-fix

Conversation

@crayfish-ai

Copy link
Copy Markdown
Contributor

Summary

fix(auxiliary): Pass original base_url to _maybe_wrap_anthropic in compression path

Without the original base_url, the compression path loses it and Anthropic detection fails.

Author: crayfish-ai

The /restart command triggered a drain that waited for ALL agents including
the caller agent itself, which was waiting for the HTTP response — creating
a deadlock that always timed out after 60 seconds.

Changes:
- _drain_active_agents(): add exclude_key param to filter out the caller
- _interrupt_running_agents(): add exclude_key param to skip the caller
- _stop_impl(): pass _restart_caller_key to both functions
- _handle_restart_command(): record caller's session_key before draining

Cherry-picked from 12c58cb81 (original fix) rebased to latest upstream/main.
@crayfish-ai crayfish-ai closed this May 7, 2026
@crayfish-ai
crayfish-ai deleted the crayfish-ai/pr-auxiliary-base-url-fix branch May 7, 2026 15:09
@alt-glitch alt-glitch added type/bug Something isn't working comp/agent Core agent runtime: loop, agent_init, prompt builder, context-compression, responses endpoint P3 Low — cosmetic, nice to have labels May 7, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Serial resubmission of #20228 and #20116 (both closed). Same fix: pass original base_url to _maybe_wrap_anthropic in compression path. Root cause same as merged #17467.

@crayfish-ai
crayfish-ai restored the crayfish-ai/pr-auxiliary-base-url-fix branch May 7, 2026 15:16
@crayfish-ai
crayfish-ai deleted the crayfish-ai/pr-auxiliary-base-url-fix branch May 9, 2026 17:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/agent Core agent runtime: loop, agent_init, prompt builder, context-compression, responses endpoint P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants