zed-industries/zed · error
cross-arch clippy not supported for
Error message
cross-arch clippy not supported for {platform}/{arch} What it means
The xtask workflow generator can run clippy jobs, but cross-architecture clippy (a non-default arch for the current platform) is only supported for macOS targets. For any other platform with a specified arch, it calls `unimplemented!()`, producing 'cross-arch clippy not supported for {platform}/{arch}'. This is a workflow-definition-time guard, not a runtime user error.
Solutions
- Omit the arch argument so clippy runs on the platform's default target (Linux/Windows default runners).
- Extend the match to map Linux/Windows arch targets to their triples and compatible runners if cross-arch support is needed.
- Run cross-arch linting via cross-compilation tooling (e.g. `cargo clippy --target <triple>`) outside the xtask workflow.
Example fix
// before
_ => unimplemented!("cross-arch clippy not supported for {platform}/{arch}"),
// after
_ => {
let _ = arch; // fall back to default target
platform.target_triple(None)
} Defensive patterns
Strategy: validation
Validate before calling
// only request cross-arch clippy on macOS
if arch.is_some() && !matches!(platform, Platform::Mac) {
return Err(anyhow!("cross-arch clippy only supported on mac"));
} Prevention
- Only pass an arch to clippy workflows for the Mac platform.
- Use platform defaults for Linux/Windows lint jobs.
- If cross-arch linting is needed, do it with explicit cargo --target invocations outside xtask.
When it happens
Trigger: Invoking the xtask test/clippy workflow generation with `--arch` (or equivalent) targeting a Linux or Windows platform with a specific architecture, e.g. `Platform::Linux` with `Arch::Aarch64`.
Common situations: CI matrix scripts trying to lint non-x86_64 Linux targets or non-default Windows arches via xtask, assuming feature parity with macOS cross-arch clippy.
Understand the failure class
Background: "unsupported platform" / "not supported on this platform" errors: what they mean and how to fix them — this error's family across 47 libraries.
Related errors
- not yet implemented
- actions.json not found at
- no GPUI crates found in the workspace
- not implemented
- Prebuilt remote servers are not yet available for
AI-assisted analysis of zed-industries/zed@916fc2b8cb (2026-09-19).
Data as JSON: /api/errors/3f0cf622391de667.
Report an issue: GitHub.
Appendix: source
Thrown at tooling/xtask/src/tasks/workflows/run_tests.rs:623
release_job(&[])
.runs_on(runners::LINUX_LARGE)
.add_step(steps::harden_runner())
.add_step(steps::checkout_repo())
.add_step(steps::setup_cargo_config(Platform::Linux))
.add_step(steps::cache_rust_dependencies_namespace())
.map(steps::install_linux_dependencies)
.add_step(steps::setup_sccache(Platform::Linux))
.add_step(steps::script("cargo build -p collab"))
.add_step(steps::script("cargo build --workspace --bins --examples"))
.add_step(steps::show_sccache_stats(Platform::Linux))
.add_step(steps::cleanup_cargo_config(Platform::Linux)),
))
}
pub(crate) fn clippy(platform: Platform, arch: Option<Arch>, harden: bool) -> NamedJob {
let target = arch.map(|arch| match platform {
Platform::Mac => platform.target_triple(arch),
_ => unimplemented!("cross-arch clippy not supported for {platform}/{arch}"),
});
let runner = match platform {
Platform::Windows => runners::WINDOWS_DEFAULT,
Platform::Linux => runners::LINUX_DEFAULT,
Platform::Mac => runners::MAC_DEFAULT,
};
let mut job = release_job(&[])
.runs_on(runner)
.when(harden && platform == Platform::Linux, |this| {
this.add_step(steps::harden_runner())
})
.add_step(steps::checkout_repo())
.add_step(steps::setup_cargo_config(platform))
.when(
platform == Platform::Linux || platform == Platform::Mac,
|this| this.add_step(steps::cache_rust_dependencies_namespace()),
)
.when(View on GitHub (pinned to 916fc2b8cb)