Skip to content

ci(conda): build and smoke-test win-64 in Conda Update, unpublished (#2060) - #2067

Merged
JarryShaw merged 1 commit into
mainfrom
ci/2060-windows-conda-phase1
Oct 23, 2026
Merged

JarryShaw merged 1 commit into
mainfrom
ci/2060-windows-conda-phase1

Conversation

@JarryShaw

Copy link
Copy Markdown
Owner

What is the purpose of your pull request?

  • ci — changes to CI configuration files and scripts

Description of your pull request and other information

Phase 1 of #2060. Conda Update's conda-dist gains a non-blocking windows-latest leg that builds and smoke-tests a win-64 package and cannot publish.

  • No publishing:
    • Only the two Anaconda upload steps read ANACONDA_TOKEN. The non-Intel upload now excludes windows-latest, the Intel one is Intel-only, and the GitHub Release steps are ubuntu-only.
    • A new test evaluates every secret-reading or publishing step's if: on windows-latest, requires that none runs, and requires that every other leg still uploads.
    • conda-dist's checkout is persist-credentials: false. conda-tag keeps its token for the tag push.
  • Stays green: each Windows step is continue-on-error on Windows only, and a final Windows summary step warns once per failed step. ci: a failed KTLO leg turns main and pull requests red; report it as a warning and exit 0 #1672 forbids a job-level continue-on-error, so a lost runner still fails the job.
  • bld.bat: now matches build.sh. The %%W loop pip-installs the vendored wheels into pcapkit\_extern, then installs ., and every install is followed by IF ERRORLEVEL 1 EXIT 1.
  • conda_vendor.py: adds win-64 (nt, PE-header native()). --smoke reads Lib/site-packages. conda/requirements.txt regenerates unchanged.
  • Found on the way: util/update_python_versions.py reads conda-dist's os axis. On main, its README parser raises on windows-latest, so it now reads the Windows images too.
  • Not yet run on Windows: cmd's handling of bld.bat, Git Bash path translation, conda under bash -el {0}, and win_amd64 wheel availability. The first Conda Update run on main is the real test, and phase 2 (publishing) waits on it.

…2060)

Phase 1 of #2060: `conda-dist` gains a non-blocking `windows-latest` leg
that builds and smoke-tests the package and publishes nothing.

- cron-conda.yml: the leg, a `win-64` case arm, `shell: bash` on the bash
  steps, setup-python's `python.exe` in the smoke test, and no persisted
  checkout token. Every step it runs has an `id` and continues on error
  there alone; `Windows summary` warns per failed step, as KTLO legs do
  (#1672). The upload steps are gated off it, so no step on the leg
  receives `ANACONDA_TOKEN`.
- bld.bat: build.sh's two installs, the wheels in one pip call with `%%`
  loop variables, each checked with `IF ERRORLEVEL 1 EXIT 1`.
- conda_vendor.py: win-64 in the platform tables, `os_name` `nt`, a PE
  reader for `.pyd`, and `Lib/site-packages` in `--smoke`, its Python read
  from the build string. conda/requirements.txt is unchanged.
- update_python_versions.py: reads the Windows images, so the conda leg's
  `windows-latest` label no longer stops the Python Versions update.
- leg_summary.py: a `conda-windows` tier.

test_conda_windows_leg_2060 pins all of it; the tests that read the conda
jobs, platforms or images follow. create-release.yml is phase 2's.
@JarryShaw JarryShaw added enhancement Issues requesting a new capability (set by the feature request template) ci Pull requests that change CI or workflow configuration (ci: subject prefix) review: running A cross-review is in flight against the current head - no verdict yet labels Oct 22, 2026
@JarryShaw

Copy link
Copy Markdown
Owner Author

GOOD TO GO at 44aaeb77d (Sonnet cross-review).

  • No publishing on Windows: the reviewer evaluated every step's if: for windows-latest. Neither Anaconda upload nor either GitHub Release step can run there, and the only new Windows step, Windows summary, reads no secret.
  • Other legs unchanged: ubuntu, macos-latest and macos-26-intel evaluate every step exactly as on main.
  • Credentials: nothing in conda-dist runs git with credentials, so persist-credentials: false is safe.
  • bld.bat: %%W, SETLOCAL EnableDelayedExpansion with !WHEELS!, quoted paths, and an IF ERRORLEVEL 1 EXIT 1 after each install.
  • conda_vendor.py: native() reads synthetic PE headers correctly (x86_64, arm64, and a truncated or bad header gives None), and --check passes.
  • Runner-images parser: checked against the live README, which lists windows-latest under Windows Server 2025, and it gives win32 x64.
  • Tests: every related module passes when run one at a time.
  • One nit: if the Windows checkout itself fails, Windows summary has no script to run, and the leg stays green with no warning.

@JarryShaw JarryShaw added review: good-to-go Cross-review at the current head says ready; CI state is separate and removed review: running A cross-review is in flight against the current head - no verdict yet labels Oct 22, 2026
@JarryShaw JarryShaw moved this to In review in PyPCAPKit Oct 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Coverage: 91.52% (unit tier, Python 3.15, 44aaeb77d, Unit Tests run success)

Package Statements Missed Branches Partial Cover
pcapkit (top level) 104 4 20 2 95.16%
pcapkit/const 19599 881 2618 867 92.11%
pcapkit/corekit 2565 71 812 37 96.56%
pcapkit/dumpkit 282 3 102 3 98.44%
pcapkit/foundation 2930 23 1022 25 98.79%
pcapkit/interface 138 4 52 3 96.32%
pcapkit/protocols 17414 219 4574 185 98.14%
pcapkit/toolkit 869 36 298 10 95.20%
pcapkit/utilities 473 7 136 5 98.03%
pcapkit/vendor 4431 1995 1018 167 51.73%

Per-file detail: the coverage-html artifact of this run.

@JarryShaw

Copy link
Copy Markdown
Owner Author

Ready to merge at 44aaeb77d: the review is GOOD TO GO and CI is complete (56 passed, 0 failed). The ordering leg ran 1966 tests with 0 failures. The 3.8–3.10 KTLO legs show 0 failing tests, and the PR is based on current main (c98541f84). The Windows leg only runs in Conda Update, so its first real run comes after merge, and phase 2 (publishing) waits on that run.

@JarryShaw
JarryShaw merged commit 27e6af1 into main Oct 23, 2026
65 checks passed
@JarryShaw
JarryShaw deleted the ci/2060-windows-conda-phase1 branch October 23, 2026 01:54
@github-project-automation github-project-automation Bot moved this from In review to Done in PyPCAPKit Oct 23, 2026
@JarryShaw

Copy link
Copy Markdown
Owner Author

Still ready after #2063 and #2064 merged. The branch is only BEHIND: it merges cleanly into main (d7581ebb1), so I haven't pushed a rebase. On the merged tree, the Windows-leg, helper, Python-versions-update, CI-report, release-gate and docs tests all pass.

@JarryShaw JarryShaw removed the review: good-to-go Cross-review at the current head says ready; CI state is separate label Oct 23, 2026
@JarryShaw JarryShaw added this to the PyPCAPKit v1.5 milestone Oct 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Pull requests that change CI or workflow configuration (ci: subject prefix) enhancement Issues requesting a new capability (set by the feature request template)

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant