fix(ci): rebalance Windows platform shards

This commit is contained in:
azizur100389 2026-09-21 19:37:37 +01:00
parent c629383bd5
commit c8786bb6ef
3 changed files with 10 additions and 2 deletions

View file

@ -162,7 +162,7 @@ jobs:
steps:
- id: gen
run: |
TOTAL=3 # cross-platform (windows/macOS) shards per OS
TOTAL=4 # cross-platform (windows/macOS) shards per OS
COV_TOTAL=3 # ubuntu coverage shards (merged before thresholds)
if [ "$TOTAL" -lt 1 ] || [ "$COV_TOTAL" -lt 1 ]; then
echo "shard totals must be >= 1" >&2; exit 1

View file

@ -47,6 +47,10 @@ export const WINDOWS_WEIGHTS_SEC: Readonly<Record<string, number>> = {
// Re-measured after the analyze --watch e2e landed in #3072. The previous
// 361 s entry undercharged this suite and left shard 1 close to the watchdog.
'test/integration/cli-e2e.test.ts': 621,
// Measured on windows-latest run 35636340549 (#3210): all 11 assertions
// passed, but the previously unweighted suite consumed 593 s and pushed
// shard 3 past the unchanged 20-minute watchdog.
'test/integration/xaml-search.test.ts': 593,
'test/integration/worker-pool.test.ts': 222,
'test/unit/incremental-vector-extension-ordering.test.ts': 87,
// Measured on Windows in run 34014266125 (#3190, 2026-09-06). These DB

View file

@ -22,7 +22,7 @@ import {
} from '../../scripts/cross-platform-shard.js';
import { ALL_CROSS_PLATFORM } from '../../scripts/cross-platform-tests.js';
const SHARD_TOTAL = 3;
const SHARD_TOTAL = 4;
/** Every shard of a split, as file lists. */
const allShards = (files: readonly string[], total: number): readonly (readonly string[])[] =>
@ -34,6 +34,9 @@ describe('cross-platform shard partition', () => {
// in the scheduling table. Keep the observed profile independent of the
// table so deleting a weight cannot make this regression pass again.
const observed: Readonly<Record<string, number>> = {
// Run 35636340549: all 11 tests passed in 593 s, but the missing weight
// packed this suite into a shard that reached the 20-minute watchdog.
'test/integration/xaml-search.test.ts': 593,
'test/integration/skills-e2e.test.ts': 550,
'test/unit/incremental-index-extension-dml-gate.test.ts': 414,
'test/integration/fts-extension-e2e.test.ts': 380,
@ -50,6 +53,7 @@ describe('cross-platform shard partition', () => {
const shards = allShards(ALL_CROSS_PLATFORM, SHARD_TOTAL);
const heavyweightLocations = [
'test/integration/cli-e2e.test.ts',
'test/integration/xaml-search.test.ts',
'test/integration/skills-e2e.test.ts',
'test/unit/incremental-index-extension-dml-gate.test.ts',
].map((file) => shards.findIndex((files) => files.includes(file)));