mirror of
https://github.com/Pasta-Devs/Marinara-Engine.git
synced 2026-12-03 19:00:50 +07:00
[PR #8710] [MERGED] fix(generate): game tool results stay before a user-turn prefill; repair staging node regressions #8760
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#8760
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/8710
Author: @Gunterlie
Created: 11/3/2026
Status: ✅ Merged
Merged: 11/3/2026
Merged by: @Gunterlie
Base:
staging← Head:fix/staging-node-regressions📝 Commits (5)
f2e756ffix(generate): keep game tool results before a user-turn prefill; sync two stale regressions3ccac22fix(generate): keep attachments on one message when splitting the prefill1b9cd1efix(generate): do not split the prefill out of a Single User Messagea5bdaa9fix(generate): keep a reasoning-carrying user prefill last in game tool roundsb86e3b9fix(generate): split the prefill out of a Single User Message with its label📊 Changes
6 files changed (+46 additions, -25 deletions)
View changed files
📝
packages/server/src/routes/generate.routes.ts(+12 -12)📝
packages/server/src/routes/generate/generate-route-utils.ts(+7 -3)📝
packages/server/src/routes/generate/tool-rounds.ts(+20 -4)📝
scripts/regressions/assistant-prefill-ends-prompt.regression.ts(+1 -0)📝
scripts/regressions/game-tool-controls.regression.ts(+5 -5)📝
scripts/regressions/open-issues.regression.ts(+1 -1)📄 Description
Why
Staging's required
node-regressions(shards 1/3 and 3/3) andcomplete-node-regressionsare red since the merges of 2026-11-02 21:57Z. They block every PR (e.g. #8708). No linked issue: CI repair requested by the maintainer.Root causes
open-issues.regression.ts(shard 3/3): stale assertion. #8704 (debug prompts keep real line breaks) changed the turn-game bot runner to logdebugJson(moveMessages). The test still matchedJSON.stringify(moveMessages, null, 2). The new behaviour is intended, so the assertion is updated.game-tool-controls.regression.ts(shard 1/3): real product bug from #8703. #8703 sends an Assistant Prefill as a user turn when there is no reply to open.endPromptOnAssistantPrefillthen reportsendsOnPrefill: false, and the prefill is merged into the last user message. The game tool-planning pass (tool-rounds.ts) only inserts its tool-results note before the tail when the tail is an assistant prefill. So the note was appended after the prefill and the prompt no longer ended on the prefill (against #8703's intent).What changed
generate-route-utils.ts:endPromptOnAssistantPrefillalso returnsuserPrefill(the prefill text) in the user-turn case.endsOnPrefillkeeps its meaning for all other callers.generate.routes.ts: passesuserPrefillinto the tool-rounds context.tool-rounds.ts: when the last user message ends withuserPrefill, split the prefill back out, insert the tool results before it, and keep the prefill last. Attachments stay on one message.open-issuesregex followsdebugJson;game-tool-controlsexpects the prefill roleuser;assistant-prefill-ends-promptexpects the newuserPrefillfield. The ordering expectation (results before the prefill) is unchanged.Validation
pnpm checkpasses.game-tool-controls,open-issues,assistant-prefill-ends-prompt,generate-tool-rounds,game-tool-outcomes,provider-compatregressions pass locally.regression:nodelocally: 1648/1650 passed. The 2 failures (native-export-memory,multiplayer-peer-server-security) are local-environment issues (missing runnerDATA_DIR, local TLS hostname), not part of the failing CI shards.Manual verification (unchecked)
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.