Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/workflows/translate-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ jobs:
runs-on: ubuntu-latest
strategy:
fail-fast: false
# Cap matrix fan-out so the LiteLLM proxy at ANTHROPIC_BASE_URL
# never sees the full 14-way burst. With 4 jobs x MAX_CONCURRENT=2
# = 8 simultaneous requests, well under the proxy's empirical
# connection-drop knee point (see scripts/translate-docs/cli.ts).
max-parallel: 4
matrix:
lang: ${{ fromJson(needs.prepare.outputs.languages) }}

Expand Down
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

## Unreleased

### Fixes
- `.github/workflows/translate-docs.yml`: cap the `translate` matrix at `max-parallel: 4` so the 14-language fan-out can't burst past the LiteLLM proxy's connection-drop knee point. The previous `MAX_CONCURRENT = 2` cap in `scripts/translate-docs/cli.ts` (#300) limited per-job concurrency but not cross-job, so under push-to-main the proxy at `ANTHROPIC_BASE_URL` saw up to 14 jobs × 2 = 28 simultaneous requests and returned `APIConnectionError ("Connection error.")` on most of them — surfaced as a workflow-wide failure on run 25532970192 where all 14 matrix jobs errored. With the cap set to 4, the proxy sees at most 8 in-flight; wall-clock cost is bounded since each job is 4–9 minutes and 14 langs in batches of 4 still completes well inside the workflow's existing footprint. Tier-1 (Sonnet, 7 langs sharing one upstream model_name) is the cohort that hit the cliff hardest; Tier-2/3 (Haiku) had headroom and only the single largest doc page consistently errored (#TBD).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Changelog entry format is non-compliant and includes unresolved placeholder text.

Please rewrite this as a concise one-line entry ending with this PR number (#305); the current line includes #TBD and references #300 instead of the current PR.

Proposed changelog line
-- `.github/workflows/translate-docs.yml`: cap the `translate` matrix at `max-parallel: 4` so the 14-language fan-out can't burst past the LiteLLM proxy's connection-drop knee point. The previous `MAX_CONCURRENT = 2` cap in `scripts/translate-docs/cli.ts` (`#300`) limited per-job concurrency but not cross-job, so under push-to-main the proxy at `ANTHROPIC_BASE_URL` saw up to 14 jobs × 2 = 28 simultaneous requests and returned `APIConnectionError ("Connection error.")` on most of them — surfaced as a workflow-wide failure on run 25532970192 where all 14 matrix jobs errored. With the cap set to 4, the proxy sees at most 8 in-flight; wall-clock cost is bounded since each job is 4–9 minutes and 14 langs in batches of 4 still completes well inside the workflow's existing footprint. Tier-1 (Sonnet, 7 langs sharing one upstream model_name) is the cohort that hit the cliff hardest; Tier-2/3 (Haiku) had headroom and only the single largest doc page consistently errored (`#TBD`).
+- Cap `translate-docs` matrix with `max-parallel: 4` to limit cross-job fan-out and avoid LiteLLM proxy connection errors (`#305`)

As per coding guidelines, "Each entry should be a single line with format: - <description> (#<PR_number>)."

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- `.github/workflows/translate-docs.yml`: cap the `translate` matrix at `max-parallel: 4` so the 14-language fan-out can't burst past the LiteLLM proxy's connection-drop knee point. The previous `MAX_CONCURRENT = 2` cap in `scripts/translate-docs/cli.ts` (#300) limited per-job concurrency but not cross-job, so under push-to-main the proxy at `ANTHROPIC_BASE_URL` saw up to 14 jobs × 2 = 28 simultaneous requests and returned `APIConnectionError ("Connection error.")` on most of them — surfaced as a workflow-wide failure on run 25532970192 where all 14 matrix jobs errored. With the cap set to 4, the proxy sees at most 8 in-flight; wall-clock cost is bounded since each job is 4–9 minutes and 14 langs in batches of 4 still completes well inside the workflow's existing footprint. Tier-1 (Sonnet, 7 langs sharing one upstream model_name) is the cohort that hit the cliff hardest; Tier-2/3 (Haiku) had headroom and only the single largest doc page consistently errored (#TBD).
- Cap `translate-docs` matrix with `max-parallel: 4` to limit cross-job fan-out and avoid LiteLLM proxy connection errors (`#305`)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@CHANGELOG.md` at line 6, Replace the multi-sentence paragraph in CHANGELOG.md
with a single-line entry that follows the required format and uses this PR
number: write a concise one-line summary describing that the translate-docs
workflow limits the translate matrix to max-parallel: 4 to avoid upstream
connection errors, remove the unresolved placeholder `#TBD` and the incorrect
reference to `#300`, and end the line with `(`#305`)` so the final line looks
like: `- <concise description> (`#305`)`.


## 0.0.10-beta.5 — 2026-05-08

### Features
Expand Down