From f22b142c6137ec3dd78b45d606965761726355ae Mon Sep 17 00:00:00 2001 From: Simone Date: Sun, 7 Jun 2026 14:06:21 +0200 Subject: [PATCH] =?UTF-8?q?docs(todo):=20track=20WinRM=204=C3=97=20concurr?= =?UTF-8?q?ency=20instability=20+=20shim=20$IsWindows=20bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit §3.6: Windows-host WinRM loses jobs under sustained 4× concurrency (burn-in §13 Win 36/40, rounds 6–8); mitigations noted (vCPU/parallelism, pypsrp timeout+retry). §3.7: Invoke-CIJob.ps1:37 derefs $IsWindows, undefined on Windows PowerShell 5.1 + StrictMode — throws unless CI_VENV_PYTHON is set. Co-Authored-By: Claude Opus 4.8 --- TODO.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/TODO.md b/TODO.md index ac8fab7..8911adb 100644 --- a/TODO.md +++ b/TODO.md @@ -833,6 +833,34 @@ da workflow. Attualmente fisso a `numvcpus=4, memsize=6144` — subottimo per bu **Rifiori quando**: Performance profiling mostra contentione CPU/RAM è bottleneck per la workload target. Per home lab, 4 vCPU/6 GB è ragionevole compromesso. +### 3.6 [P2] [ ] Stabilità WinRM sotto concorrenza 4× su host Windows +File: [src/ci_orchestrator/transport/winrm.py](src/ci_orchestrator/transport/winrm.py), +[docs/RUNBOOK.md §13](docs/RUNBOOK.md). + +Burn-in §13 (2026-06-07) su host Windows: guest **Windows 36/40** (round 6–8 +hanno perso 1–2 job per fault WinRM transitori — `ConnectTimeoutError` su 5986 e +`WSManFault 2150858843` "shell not found" — con round inflazionati a 269/266/622 s). +Guest **Linux 40/40** (SSH stabile). Stesso hardware: host Linux §9 = Win 40/40. +Auto-recupero OK (slot IP rilasciati, 0 orfani), ma OVERALL FAIL. + +Causa probabile: oversubscription vCPU (4 VM × 4 vCPU = 16) + overhead host-OS +Windows che manda in timeout WinRM concorrente (RAM non era il vincolo: 13.8 GB +liberi su 63.7). **Mitigazioni**: ridurre vCPU/VM (lega a §3.5), `-Parallelism 3`, +alzare connect-timeout pypsrp + retry a livello job in `_windows_build`. +**Rifiori quando**: si vuole concorrenza 4× Windows-guest affidabile su host Windows. + +### 3.7 [P3] [ ] Shim Invoke-CIJob.ps1 — `$IsWindows` non guardato (PS 5.1 + StrictMode) +File: [scripts/Invoke-CIJob.ps1:37](scripts/Invoke-CIJob.ps1). + +`if ($null -ne $IsWindows -and $IsWindows -eq $false)` dereferenzia `$IsWindows`, +inesistente su Windows PowerShell 5.1 → con `Set-StrictMode -Version Latest` +lancia `VariableIsUndefined` e il job fallisce subito. Si manifesta solo quando lo +shim gira sotto PS 5.1 **senza** `CI_VENV_PYTHON` settato (il ramo auto-detect). +Produzione setta `CI_VENV_PYTHON` via runner, quindi non si vede; colpisce invocazioni +manuali/burn-in. **Fix**: guardare con `if ((Test-Path variable:IsWindows) -and -not $IsWindows)` +o `Get-Variable IsWindows -EA SilentlyContinue`. +**Workaround attuale**: esportare `CI_VENV_PYTHON` prima di lanciare lo shim. + ### 8.1 [P3] [ ] Mirror GitHub Actions su Gitea locale (rimuovi dipendenza github.com) File: [.gitea/workflows/lint.yml](.gitea/workflows/lint.yml), Gitea (org `actions`).