Repository navigation
fix(build): stop ort's copy-dylibs from breaking Windows CI - #445
Merged
Merged
Conversation
Every Windows job has failed at `Lint (clippy)` since the ONNX Runtime
prebuilt download started landing on a newer archive. The panic is at
ort-sys/build/dynamic_link.rs:42, inside copy_dylibs:
fs::copy(&lib_path, &out_path).unwrap()
Os { code: 3, kind: NotFound }
That branch runs because `ort`'s default feature set includes
`copy-dylibs`. On Windows it symlinks the runtime DLLs into the cargo
target directory and falls back to copying when symlinking is denied --
which it is on a hosted runner without Developer Mode. The fallback writes
into a directory that does not exist there, and panics.
Nothing in this workspace needs the feature. No DLL is bundled: Windows
installs the runtime through the Wix prerequisite fragment, and the
release build handles its own copying. `copy-dylibs` only affects whether
`cargo test`/`cargo run` from the target directory can find the DLLs, and
CI never runs the ONNX paths against real models.
Both crates now take the default set apart and name what they use --
`std`, `ndarray`, `tracing`, `download-binaries`, `tls-native`, `api-27`
-- which is the default minus `copy-dylibs`.
This is a pre-existing breakage, not something the current branch
introduced: dev's own run at 18:34 on 2026-11-12 failed the same way.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Windows CI has been red on every PR since 2026-11-12 18:34, including
devitself. This fixes the cause.The failure
Every Windows job dies at
Lint (clippy), before compiling a single line of this workspace:Line 42 is inside
copy_dylibs:Root cause
ort's default feature set includescopy-dylibs:Both
omera-taggerandomera-clipdeclaredort = { version = "2.0.0-rc.13", features = ["download-binaries"] }withoutdefault-features = false, socopy-dylibswas always on.On Windows,
copy_dylibssymlinks the ONNX Runtime DLLs into the cargo target directory. Hosted runners run without Developer Mode, so symlinking is denied, and it falls back tofs::copy— into a directory that does not exist there. Panic.Why dropping it is safe
Nothing in this workspace bundles those DLLs:
windows/generated/runtime-prerequisite.wxs), not by shipping DLLs beside the binary.tauri.conf.jsondeclares nobundle.resources.copy-dylibsonly controls whethercargo test/cargo runinvoked from the target directory can resolve the DLLs at runtime. Dropping it costs nothing here.The change
Both crates now take the default set apart and name what they use:
That is the default minus
copy-dylibs. The crate's actual API surface is unchanged —Session,Tensor,inputs!andGraphOptimizationLevelare all still available, andcargo checkconfirms it.Cargo.lockis untouched; feature flags do not alter the dependency graph.Verification
cargo check --workspace --all-targets— clean.cargo clippy --workspace --all-targets -- -D warnings— clean.cargo test --workspace— all green.The real proof is the Windows job on this PR: it is the first one in two days that can get past
Lint (clippy).Scope
Build configuration only. No source, schema, IPC, UI or behavior change.
🤖 Generated with Claude Code