mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
Labels
No labels
android
bug
bugfix
ci
client
code freeze pause
container
dependencies
docs
documentation
duplicate
enhancement
feature
feature
feature
feature-creep
fixed-in-refactor
fixed-in-staging
good first issue
help wanted
in-pr
in-pr
needs-codeowner-decision
normal-scope
old-codebase
old-codebase
pull-request
qol
question
refactor
regression
revisit later
roadmap
scope-risk
scope-risk
server
server
shared
soup
upstream
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Pasta-Devs/Marinara-Engine#8313
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/8357
Author: @Promansis
Created: 10/26/2026
Status: ✅ Merged
Merged: 10/26/2026
Merged by: @Promansis
Base:
staging← Head:fix(connections)/8353-default-user-agent📝 Commits (2)
c80f7d3fix(connections): send a default User-Agent on provider requests (#8353)f1129e3Merge remote-tracking branch 'upstream/staging' into fix(connections)/8353-default-user-agent📊 Changes
4 files changed (+53 additions, -6 deletions)
View changed files
📝
packages/server/src/routes/connections.routes.ts(+3 -2)📝
packages/server/src/services/llm/base-provider.ts(+7 -2)📝
packages/server/src/utils/security.ts(+10 -1)📝
scripts/regressions/safe-fetch-response-activity.regression.ts(+33 -1)📄 Description
Linked issue
Closes #8353
Why this change
Featherless's edge answers
404 Gone.to requests whoseUser-Agentisnodeorundici, which is what Node'sfetchsends by default. Engine set no User-Agent on provider calls, so Fetch Models on a Custom (OpenAI-compatible) connection tohttps://api.featherless.ai/v1failed withProvider returned 404: Gone., while SillyTavern worked with the same URL. The Test button and chat completions go through the same path.Checked with curl against the endpoint and a bad key:
-A nodeand-A undicireturn404 Gone.;-A MarinaraEngine/2.5.1reaches the normal401auth error.What changed
utils/security.ts: newrequestHeadersWithDefaultUserAgent(), which setsUser-Agent: MarinaraEngine/<APP_VERSION>only when the caller did not set one.services/llm/base-provider.ts:llmFetchapplies it, covering chat and embedding generation.routes/connections.routes.ts: the/modelsfetch and the connection-test fetch apply it.safe-fetch-response-activity.regression.ts: one case on the existing loopback server assertsllmFetchand the discovery header helper send the default User-Agent (notnode) and that a caller-supplied User-Agent is kept.Deliberately not changed:
safeFetchitself andrequestHeadersWithIdentityEncoding. Both are shared by about 60 other callers (video, media, TTS, ChatGPT auth, OpenCode), and a global default would alter the OpenCode redirect-hop assertion. Every other caller sends the same headers as before. OpenCode's own User-Agent, OpenRouter attribution,accept-encoding: identityand the SSRF policy are unchanged.Validation
Local, on
f1129e3cc(feature commit merged withupstream/stagingat105a707a1):The new case fails with
'node'when thebase-provider.tschange is removed, and passes with it.node scripts/run-regressions.mjs --filterforsafe-fetch-response-activity,opencode-session,security(30),connection(10),provider(9),llm,openai,anthropicandopenrouter: all pass.pnpm format:checkpasses;pnpm lintreports 0 errors (1 existing client warning);pnpm --filter @marinara-engine/server buildexits 0.Not run: the full
pnpm checkand the complete regression suite. I did not test against a real Featherless key.pnpm checkpasses locallyContainer (Docker / Podman) built and ran without issue
Ran the app, clicked through the changes manually
Checked edge cases (light + dark mode, mobile viewport, empty states, error paths)
Above manual verification completed (describe below)
Read and followed
CONTRIBUTING.mdManual verification notes
Docs and release impact
docs-i18nbranch updated to match, or a[docs-i18n]follow-up issue opened (see CONTRIBUTING.md § Translated documentation)UI evidence (if applicable)
No UI change.
🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.