Skip to content

chore: revert change to skip user-agent for openrouter#169

Merged
andreynering merged 4 commits intomainfrom
openrouter-useragent
Mar 19, 2026
Merged

chore: revert change to skip user-agent for openrouter#169
andreynering merged 4 commits intomainfrom
openrouter-useragent

Conversation

@andreynering
Copy link
Copy Markdown
Member

@andreynering andreynering commented Mar 13, 2026

This depends on the following fix for the OpenAI SDK:

Keeping this PR as a draft for now.

@andreynering andreynering self-assigned this Mar 13, 2026
andreynering added a commit that referenced this pull request Mar 19, 2026
The OpenAI SDK has a bug on dealing with SSE events. This was affected
OpenRouter, but we made a workaround for it. See:

* #166
* #169

We made a fix for the SDK, but it wasn't merged yet:

* openai/openai-go#621

In the meantime, an user reported that Avian has the same issue, but it's
impossible for us to workaround it. Because of this, we had to fork the
SDK. We're pinning the `fantasy` branch from our fork:

* https://github.com/charmbracelet/openai-go/tree/fantasy
andreynering added a commit that referenced this pull request Mar 19, 2026
The OpenAI SDK has a bug on dealing with SSE events. This was affected
OpenRouter, but we made a workaround for it. See:

* #166
* #169

We made a fix for the SDK, but it wasn't merged yet:

* openai/openai-go#621

In the meantime, an user reported that Avian has the same issue, but it's
impossible for us to workaround it. Because of this, we had to fork the
SDK. We're pinning the `fantasy` branch from our fork:

* https://github.com/charmbracelet/openai-go/tree/fantasy
@andreynering andreynering force-pushed the openrouter-useragent branch from 7343902 to 877b7a0 Compare March 19, 2026 18:41
@andreynering andreynering force-pushed the openrouter-useragent branch from 877b7a0 to a20fcb8 Compare March 19, 2026 18:45
@andreynering andreynering marked this pull request as ready for review March 19, 2026 18:45
@andreynering andreynering enabled auto-merge (rebase) March 19, 2026 18:47
@andreynering andreynering merged commit 5e4a443 into main Mar 19, 2026
16 checks passed
@andreynering andreynering deleted the openrouter-useragent branch March 19, 2026 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants