Repository navigation
fix(docker): complete partially traced packages in standalone co-location - #9615
Merged
Merged
Conversation
…tion Publish-to-Docker-Hub has failed on every release/v3.8.50 push since #9151 enabled publishing from active release branches: the post-build guard dies with "Cannot find module .../@atjsh/llmlingua-2/dist/index.js" while the co-location step right above it reports 100 packages copied. Root cause: Next's file tracing materializes @atjsh/llmlingua-2 PARTIALLY in the standalone (package.json lands, the dist/ payload its main points at does not). colocateOptionals' no-clobber checked existsSync on the package DIRECTORY, so the partial shell counted as present and the one package that mattered was skipped forever (#9185 added the closure walk but kept the directory-level check). Fix: presence is now judged by entrypoint integrity — the package resolves from inside the target tree (same contract as the Dockerfile guard). Partial directories are completed with a file-level no-clobber merge (cpSync force:false), so files the trace did materialize are never overwritten and pinned instances (dist transformers 3.5.2) keep their protection. Validation (TDD): 2 new tests in docker-llmlingua-optionals-9166.test.ts reproduce the CI failure (partial package skipped; closure-wide early-exit firing while a member is partial) — red on the old code, 5/5 green after.
…ypoint resolution The PR's isPackageIntact check uses require.resolve to validate that co-located packages have a usable entrypoint inside the target tree. The pre-existing test's mock packages lacked main fields and index files, so require.resolve failed and the idempotency assertion broke. Update buildRoot() to give every closure package a resolvable entry (main + index.js), mirroring what real npm packages ship. Refs #9615
…-colocate-partial-trace
…-colocate-partial-trace # Conflicts: # config/quality/file-size-baseline.json # open-sse/services/combo.ts # tests/unit/repro-9630-combo-false-503.test.ts
…-colocate-partial-trace
…-colocate-partial-trace
ddarkr
added a commit
to ddarkr/OmniRoute
that referenced
this pull request
Aug 26, 2026
Conflict resolutions: - open-sse/config/providers/shared.ts: take upstream's 872K Codex OAuth context window (verified against live /codex/models endpoint) - scripts/build/colocateOptionals.mjs: take upstream's isPackageIntact (PR diegosouzapw#9615) which supersedes downstream's hasCompleteTree with an entrypoint-resolution integrity check
muhamadgalihsaputra
pushed a commit
to niyatna/NiyatnaRoute
that referenced
this pull request
Sep 27, 2026
…tion (diegosouzapw#9615) * fix(docker): complete partially traced packages in standalone co-location Publish-to-Docker-Hub has failed on every release/v3.8.50 push since diegosouzapw#9151 enabled publishing from active release branches: the post-build guard dies with "Cannot find module .../@atjsh/llmlingua-2/dist/index.js" while the co-location step right above it reports 100 packages copied. Root cause: Next's file tracing materializes @atjsh/llmlingua-2 PARTIALLY in the standalone (package.json lands, the dist/ payload its main points at does not). colocateOptionals' no-clobber checked existsSync on the package DIRECTORY, so the partial shell counted as present and the one package that mattered was skipped forever (diegosouzapw#9185 added the closure walk but kept the directory-level check). Fix: presence is now judged by entrypoint integrity — the package resolves from inside the target tree (same contract as the Dockerfile guard). Partial directories are completed with a file-level no-clobber merge (cpSync force:false), so files the trace did materialize are never overwritten and pinned instances (dist transformers 3.5.2) keep their protection. Validation (TDD): 2 new tests in docker-llmlingua-optionals-9166.test.ts reproduce the CI failure (partial package skipped; closure-wide early-exit firing while a member is partial) — red on the old code, 5/5 green after. * fix: update colocate test mock packages to match isPackageIntact entrypoint resolution The PR's isPackageIntact check uses require.resolve to validate that co-located packages have a usable entrypoint inside the target tree. The pre-existing test's mock packages lacked main fields and index files, so require.resolve failed and the idempotency assertion broke. Update buildRoot() to give every closure package a resolvable entry (main + index.js), mirroring what real npm packages ship. Refs diegosouzapw#9615 * docs(changelog): fragment for diegosouzapw#9615 * fix(yuanbao-web): accept content field in SSE text events (upstream format change) (diegosouzapw#8739) Closes diegosouzapw#8739 * fix(errorClassifier): classify ChatGPT Web SENTINEL_BLOCKED 403 as FORBIDDEN, enabling combo fallback (diegosouzapw#8813) Closes diegosouzapw#8813 * fix(vertex): route Claude models to native rawPredict and respect targetFormat overrides (diegosouzapw#8994) Closes diegosouzapw#8994 * fix(cursor): preserve tool context across multi-turn conversations when client lacks conversation_id (diegosouzapw#9029) Closes diegosouzapw#9029 * fix(sse): move Antigravity client system content to first user message to avoid upstream 429 (diegosouzapw#9030) Closes diegosouzapw#9030 * fix(combo): distinguish pre-dispatch skips from genuine failures to prevent false 503 ALL_ACCOUNTS_INACTIVE (diegosouzapw#9630) Closes diegosouzapw#9630 * fix: repair stray brace in combo.ts and fix no-explicit-any types in repro-9630 test --------- Co-authored-by: diegosouzapw <diegosouzapw@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Contexto
Publish to Docker Hub falha em 100% dos pushes da release/v3.8.50 desde que o #9151 ativou o publish em release branches ativas (último verde: v3.8.49, 30/07). O guard pós-build morre com:
…logo depois de o co-locate reportar
✅ Co-located 100 LLMLingua SLM optional package(s).Causa-raiz
O file tracing do Next materializa
@atjsh/llmlingua-2parcialmente no standalone: opackage.jsonentra, o payloaddist/que omainaponta não. O no-clobber docolocateOptionals.mjschecavaexistsSyncno diretório do pacote — a casca parcial contava como presente e o único pacote que importava era pulado para sempre (o #9185 adicionou o closure walk mas manteve o check por diretório). O early-exit "already co-located" tinha o mesmo defeito.Fix
Presença agora é julgada por integridade do entrypoint — o pacote resolve de dentro da árvore-alvo (mesmo contrato do guard do Dockerfile). Diretórios parciais são completados com merge no-clobber por arquivo (
cpSync force:false): o que o trace materializou nunca é sobrescrito, e instâncias pinadas (transformers 3.5.2 no dist) mantêm a proteção — o teste de contrato existente segue verde.Validação (TDD)
2 testes novos em
tests/unit/docker-llmlingua-optionals-9166.test.tsreproduzem a falha do CI (pacote parcial pulado; early-exit global disparando com membro parcial): red no código velho → 5/5 green com o fix.Refs #9151, #9185, #9166. Run com a falha: https://github.com/diegosouzapw/OmniRoute/actions/runs/31091515674
This run inherits ~10 base-red failures caused by:
The only PR-introduced failure was the test, fixed in 706cebe.
This run inherits ~10 base-red failures caused by:
134(ccr_blocks vs proxy_logs_egress_ip) — being fixed in fix(db): resolve CCR migration version collision #9618OMNIROUTE_MAX_POOL_SIZE/OMNIROUTE_DB_POOL_SIZEclaimed in docs but not in code9415-newapi-sub2api-aggregator-balance.md)The only PR-introduced failure was the
colocateLlmlinguaOptionals is idempotenttest, fixed in 706cebe.