Skip to content

[FIX][CI] Pin OrcJIT publish wheel to main, drop unused tag input - #615

Closed
cyx-6 wants to merge 1 commit into
apache:mainfrom
cyx-6:fix-orcjit-publish
Closed

cyx-6 wants to merge 1 commit into
apache:mainfrom
cyx-6:fix-orcjit-publish

Conversation

@cyx-6

@cyx-6 cyx-6 commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Problem

The Publish OrcJIT wheel workflow failed on its last manual run
(run 27092992406,
dispatched with tag: v0.1.0). All four build legs failed with:

cibuildwheel: Could not find any of {setup.py, setup.cfg, pyproject.toml} at root of package

Root cause

publish_orcjit_wheel.yml was copy-pasted from the main-package
publish_wheel.yml and inherited a tag workflow_dispatch input wired into the
build-orcjit-wheel action's checkout_ref. The composite action then does an inner
actions/checkout { ref: <tag> } that replaces the working tree with the repo
state at that tag.

But the OrcJIT addon (apache-tvm_ffi_orcjit) is a standalone package, versioned
by its own addons/tvm_ffi_orcjit/pyproject.toml (currently 0.1.0), independent of
the tvm-ffi repo tags. The addon was added in #254 (2026-03-27) and first appears in
tag v0.1.10. Dispatching with any older tag — v0.1.0 here — checks out a tree with
no addon directory, so cibuildwheel finds no pyproject.toml. (The overwrite also
clobbers the action's own action.yml, producing the confusing secondary
"Can't find 'action.yml'" post-step error.)

The repo tag was never the addon's version source — only a (wrong) checkout source.

Fix

Single-file change to publish_orcjit_wheel.yml:

  • Remove the unused tag workflow_dispatch input.
  • Pin the build to checkout_ref: main, so publish always builds the current addon
    source. The wheel version comes from the addon's pyproject.toml.

The build-orcjit-wheel action keeps its checkout_ref input unchanged, because the
orcjit job in ci_test.yml still uses it (checkout_ref: ${{ github.sha }}) to build
the addon at the PR head SHA. The action's inner submodules: recursive checkout is
load-bearing: CIBW_TEST_COMMAND does pip install --force-reinstall {project}, which
rebuilds the main apache-tvm-ffi from the repo root and needs 3rdparty/dlpack +
libbacktrace.

Validation

Dispatched on a fork with the patched workflow
(run 27130310085): all four
build_wheels legs — ubuntu x86_64, ubuntu aarch64, macOS arm64, Windows AMD64 — built,
tested, and uploaded wheels successfully. upload_pypi fails on the fork only because it
has no PyPI trusted-publisher mapping (invalid-publisher); that step works on
apache/tvm-ffi, which has the pypi environment configured. actionlint passes clean.

publish_orcjit_wheel.yml was copy-pasted from the main-package publish_wheel.yml
and inherited a `tag` workflow_dispatch input wired into the build-orcjit-wheel
action's checkout_ref. The OrcJIT addon (apache-tvm_ffi_orcjit) is a standalone
package versioned by its own addons/tvm_ffi_orcjit/pyproject.toml, independent of
the tvm-ffi repo tags, so the tag was never a version source -- only a (wrong)
checkout source. Dispatching the workflow with an old tag (e.g. v0.1.0, which
predates the addon) made the action check out a tree with no addon, and
cibuildwheel failed with "Could not find ... pyproject.toml" (run 27092992406).

Remove the tag input and pin checkout_ref to main, so the publish always builds
the current addon source; the wheel version comes from its pyproject.toml. The
build-orcjit-wheel action keeps its checkout_ref input because ci_test.yml's
orcjit job still uses it to build the addon at the PR head SHA.
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@cyx-6 cyx-6 closed this Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants