docs(todo): track WinRM 4× concurrency instability + shim $IsWindows bug

§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 <noreply@anthropic.com>
This commit is contained in:
Simone
2026-06-07 14:06:21 +02:00
parent 66cdd4866f
commit f22b142c61
+28
View File
@@ -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 68
hanno perso 12 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`).