Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
34 changes: 34 additions & 0 deletions .github/workflows/locked-windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Locked Windows environment
on:
pull_request:
push:
branches: [main]
permissions:
contents: read
jobs:
locked-windows:
name: Locked Windows Python 3.12
runs-on: windows-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
with:
persist-credentials: false
- uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97
with:
python-version: "3.12"
- name: Build a fresh environment from the lock
shell: pwsh
run: |
./tools/Install-Locked.ps1 -Python python -Environment .venv-locked
- name: Verify locked dependencies and exercise the research code
shell: pwsh
run: |
$ErrorActionPreference = 'Stop'
$runtime = '.venv-locked/Scripts/python.exe'
& $runtime -m pip check
if ($LASTEXITCODE) { throw 'Dependency consistency check failed' }
& $runtime -m ruff check src tests
if ($LASTEXITCODE) { throw 'Lint failed' }
& $runtime -m pytest -q
if ($LASTEXITCODE) { throw 'Tests failed' }
11 changes: 11 additions & 0 deletions ENVIRONMENT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Reproducible Windows research environment

The checked-in lock targets CPython 3.12 on Windows. Other Python/platform combinations need their own resolved and tested lock. The Git dependency, where present, is pinned to an immutable commit. The project itself must also be checked out at the desired recorded commit.

```powershell
powershell -File tools/Install-Locked.ps1 -Python C:/path/to/python.exe -Environment D:/new-environment
D:/new-environment/Scripts/python.exe -m pytest -q
D:/new-environment/Scripts/python.exe -m ruff check src tests
```

Install into a new directory; do not overlay an existing research environment. Update this lock only in a dedicated environment, rebuild from the proposed lock, run pip check and the complete tests, and commit the lock with its validation record. Do not copy editable local paths into the dependency lock.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[build-system]
requires = ["setuptools>=68"]
requires = ["setuptools==84.0.0"]
build-backend = "setuptools.build_meta"

[project]
Expand Down
17 changes: 17 additions & 0 deletions requirements.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Verified Windows / CPython 3.12 environment; runtime + dev + build requirements.
# Source versions: engineering acceptance 2026-10-09, rebuilt in a clean venv.
# Install with --no-deps; then install this repository --no-deps --no-build-isolation.
colorama==0.4.6
iniconfig==2.3.1
numpy==2.5.3
packaging==26.3
pandas==3.0.6
pluggy==1.6.0
Pygments==2.21.0
pytest==9.1.1
python-dateutil==2.9.0.post0
PyYAML==6.0.3
ruff==0.16.10
setuptools==84.0.0
six==1.17.0
tzdata==2026.5
18 changes: 18 additions & 0 deletions tools/Install-Locked.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
param([string]$Python = 'python', [string]$Environment = '.venv-locked')
$ErrorActionPreference = 'Stop'
$Repo = Split-Path $PSScriptRoot -Parent
Push-Location $Repo
try {
& $Python -c "import sys; assert sys.version_info[:2] == (3, 12), 'Use Python 3.12'"
if ($LASTEXITCODE) { throw 'Python 3.12 is required' }
if (Test-Path -LiteralPath $Environment) { throw 'Choose a new environment directory' }
& $Python -m venv $Environment
if ($LASTEXITCODE) { throw 'venv failed' }
$Runtime = Join-Path $Environment 'Scripts/python.exe'
& $Runtime -m pip install --no-deps -r requirements.lock
if ($LASTEXITCODE) { throw 'Locked dependency installation failed' }
& $Runtime -m pip install --no-deps --no-build-isolation -e .
if ($LASTEXITCODE) { throw 'Project installation failed' }
& $Runtime -m pip check
if ($LASTEXITCODE) { throw 'Dependency consistency check failed' }
} finally { Pop-Location }
Loading