Skip to content

Commit c21c994

Browse files
JonZeollaclaude
andcommitted
fix: override VERSION and LOCAL_PLATFORM env vars for Windows task commands
Task eagerly evaluates top-level sh: vars and the namespace-package import for VERSION fails on Windows. Supply both VERSION and LOCAL_PLATFORM as env-var overrides so Task skips the sh: evaluation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 57c59f3 commit c21c994

1 file changed

Lines changed: 12 additions & 5 deletions

File tree

.github/workflows/ci.yml

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -210,24 +210,31 @@ jobs:
210210
Write-Host "Windows smoke test passed: project generated and verified successfully"
211211
- name: Initialize generated project
212212
shell: bash
213+
# VERSION and LOCAL_PLATFORM are top-level Taskfile vars evaluated via
214+
# `uv run` shell commands. On Windows the namespace-package import
215+
# that resolves VERSION fails, so we supply both as env-var overrides.
216+
env:
217+
VERSION: '0.0.0'
218+
LOCAL_PLATFORM: 'linux/amd64'
213219
run: |
214220
cd "$RUNNER_TEMP/replace-me"
215-
# Bootstrap the venv first so Task can evaluate top-level vars
216-
# (VERSION uses `uv run python -c` which needs the project importable)
217221
uv sync --frozen --all-extras
218-
export PYTHONPATH="$PWD"
219222
task -v init
220223
- name: Run tests
221224
shell: bash
225+
env:
226+
VERSION: '0.0.0'
227+
LOCAL_PLATFORM: 'linux/amd64'
222228
run: |
223229
cd "$RUNNER_TEMP/replace-me"
224-
export PYTHONPATH="$PWD"
225230
task -v test
226231
- name: Build Docker image
227232
shell: bash
233+
env:
234+
VERSION: '0.0.0'
235+
LOCAL_PLATFORM: 'linux/amd64'
228236
run: |
229237
cd "$RUNNER_TEMP/replace-me"
230-
export PYTHONPATH="$PWD"
231238
task -v build
232239
- name: Verify Docker image
233240
shell: bash

0 commit comments

Comments
 (0)