fix(ci): correct comments, timeouts, and pip reliability in native e2e workflows (#878)

Review feedback on PR #837 identified several issues in the newly added
`wrap-native-e2e.yml` and `install-native-e2e.yml` workflows.

## Changes

**`wrap-native-e2e.yml`**
- Header comment claimed "linux / macos / windows" coverage — Windows is
matrix-excluded; updated to reflect actual runners and note Windows is
pending CRT fix
- Removed Windows-specific wording ("Windows path handling") from the
workflow description; made OS-agnostic
- `timeout-minutes`: `15` → `25` to match `init-native-e2e.yml` and
avoid maturin build flakes on macOS

**Both `wrap-native-e2e.yml` and `install-native-e2e.yml`**
- pip install made more resilient on macOS runners, matching the pattern
already used in `ci.yml`:
```yaml
- name: Install pytest
  shell: bash
  run: |
    python -m pip install --upgrade pip
    python -m pip install --retries 10 --timeout 60 pytest pytest-cov
```
- `timeout-minutes`: `15` → `25` in `install-native-e2e.yml` for the
same reason

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: JD Davis <mxjerrett@gmail.com>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
This commit is contained in:
Copilot 2026-06-11 21:02:05 -07:00 committed by GitHub
parent e408012c2b
commit b716c8c2ee
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 137 additions and 0 deletions

View file

@ -0,0 +1,66 @@
name: Install Native E2E
# Cross-platform smoke tests for safe ``headroom install`` paths. The goal here
# is portable CLI coverage that runs on real runners without mutating OS service
# managers or requiring Docker. Deeper lifecycle behavior remains covered by the
# existing native installer wrapper tests and install unit tests.
on:
pull_request:
branches: [main]
paths:
- "headroom/cli/install.py"
- "headroom/install/**"
- "tests/test_cli/test_install_cli.py"
- "tests/test_install/test_paths.py"
- ".github/actions/headroom-e2e-setup/**"
- ".github/workflows/install-native-e2e.yml"
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
jobs:
install-native:
runs-on: ${{ matrix.os }}
timeout-minutes: 25
strategy:
fail-fast: false
matrix:
# Windows is excluded today: upstream `esaxx-rs` (transitively from
# `tokenizers`) and `ort-sys` (onnxruntime via `fastembed`) link
# with conflicting MSVC C runtime libraries (/MT vs /MD), so the
# Rust extension cannot build for `win_amd64` until the upstream
# CRT conflict is resolved. Re-add `windows-latest` once the wheel
# builds cleanly there. Match init-native-e2e.yml so this workflow
# doesn't fail during setup before the install smoke tests run.
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v6
- name: Setup
uses: ./.github/actions/headroom-e2e-setup
with:
python-version: "3.11"
- name: Install pytest
shell: bash
run: |
python -m pip install --upgrade pip
python -m pip install --retries 10 --timeout 60 pytest pytest-cov
- name: Run install native smoke tests
shell: bash
run: |
pytest tests/test_cli/test_install_cli.py tests/test_install/test_paths.py --cov=headroom --cov-report=xml:coverage-install-native.xml --cov-report=term-missing -q
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
file: ./coverage-install-native.xml
flags: install-native
name: install-native-${{ matrix.os }}
fail_ci_if_error: false

71
.github/workflows/wrap-native-e2e.yml vendored Normal file
View file

@ -0,0 +1,71 @@
name: Wrap Native E2E
# Cross-platform smoke tests for the hidden ``headroom wrap ... --prepare-only``
# flows. These reuse the existing pytest bridge cases so we exercise the real
# CLI on linux / macos without depending on agent binaries or long-lived proxy
# processes. Windows will be added once the upstream CRT conflict is resolved
# (see matrix comment below).
#
# This complements the Docker-native wrap e2e by catching host-specific issues
# such as home-directory layout and filesystem quirks in prepare-only config
# injection.
on:
pull_request:
branches: [main]
paths:
- "headroom/cli/**"
- "headroom/providers/**"
- "headroom/rtk/**"
- "tests/test_cli/test_wrap_bridge.py"
- ".github/actions/headroom-e2e-setup/**"
- ".github/workflows/wrap-native-e2e.yml"
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
jobs:
wrap-native:
runs-on: ${{ matrix.os }}
timeout-minutes: 25
strategy:
fail-fast: false
matrix:
# Windows is excluded today: upstream `esaxx-rs` (transitively from
# `tokenizers`) and `ort-sys` (onnxruntime via `fastembed`) link
# with conflicting MSVC C runtime libraries (/MT vs /MD), so the
# Rust extension cannot build for `win_amd64` until the upstream
# CRT conflict is resolved. Re-add `windows-latest` once the wheel
# builds cleanly there. Match init-native-e2e.yml so this workflow
# doesn't fail during setup before the wrap smoke tests run.
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v6
- name: Setup
uses: ./.github/actions/headroom-e2e-setup
with:
python-version: "3.11"
- name: Install pytest
shell: bash
run: |
python -m pip install --upgrade pip
python -m pip install --retries 10 --timeout 60 pytest pytest-cov
- name: Run wrap native bridge tests
shell: bash
run: |
pytest tests/test_cli/test_wrap_bridge.py --cov=headroom --cov-report=xml:coverage-wrap-native.xml --cov-report=term-missing -q
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
file: ./coverage-wrap-native.xml
flags: wrap-native
name: wrap-native-${{ matrix.os }}
fail_ci_if_error: false