Skip to content

Pin the path the native forwarder sends upstream - #75

Merged
vitramir merged 1 commit into
mainfrom
native-path-regression-test
Aug 9, 2026
Merged

Pin the path the native forwarder sends upstream#75
vitramir merged 1 commit into
mainfrom
native-path-regression-test

Conversation

@vitramir

@vitramir vitramir commented Aug 9, 2026

Copy link
Copy Markdown
Contributor

Regression test for the composition in buildRequest:

target := strings.TrimSuffix(binding.UpstreamEndpoint, "/") + r.URL.RequestURI()

The caller's whole path is appended, so an upstream that carries a path of its own sends it twice. That is what made codex's /backend-api/codex/responses arrive as /backend-api/codex/backend-api/codex/responses and come back 404 — which reads as a missing endpoint rather than a bug here. Fixed on the binding side in llm#56; this stops it recurring silently.

A path on the binding is appended to the caller's own, so an upstream
carrying one forwards it twice. The vendor answers 404 and it reads as a
missing endpoint rather than a composition bug.
@vitramir
vitramir merged commit 79b39af into main Aug 9, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant