Skip to content

pip install -e ".[dev]" fails on macOS: liger-kernel requires triton#6327

Open
clementtisseau wants to merge 1 commit into
huggingface:mainfrom
clementtisseau:liger-kernel-linux-only
Open

pip install -e ".[dev]" fails on macOS: liger-kernel requires triton#6327
clementtisseau wants to merge 1 commit into
huggingface:mainfrom
clementtisseau:liger-kernel-linux-only

Conversation

@clementtisseau

@clementtisseau clementtisseau commented Jul 8, 2026

Copy link
Copy Markdown

What does this PR do?

The ligerand dev extras list liger-kernel unconditionally. liger-kernel is pure Python, but requires
triton>=2.3.1, and triton ships manylinux wheels only, no sdist, no macOS/Windows wheels. With nothing to install and
nothing to build, the resolver fails before the install phase, so nothing lands at all.
Windows is affected too.

Skipping liger-kernel on macOS costs nothing: Triton kernels can't run there,
is_liger_kernel_available() already guards the runtime path, and require_liger_kernel
already skips the tests.

Before submitting

  • This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
  • Did you read the contributor guideline, Pull Request section?
  • Was this discussed/approved via a GitHub issue? Please add a link to it if that's the case.
  • Did you make sure to update the documentation with your changes?
  • Did you write any new necessary tests?

AI writing disclosure

We welcome the use of AI tools to help with contributions. For transparency and to help us improve our review process, please indicate the level of AI involvement in this PR.

  • No AI usage: the PR was written entirely by a human.
  • AI-assisted: some parts were suggested or improved by AI, but the PR was written and reviewed by a human.
  • AI-generated: the PR was mostly or fully generated by an AI tool.

Who can review?

Anyone in the community is free to review the PR once the tests have passed. Feel free to tag members/contributors who may be interested in your PR.


Note

Low Risk
Packaging-only change with no runtime code paths modified; Linux installs keep the same dependency set.

Overview
Fixes pip install -e ".[dev]" (and .[liger]) failing on macOS and Windows by adding a sys_platform == 'linux' marker on liger-kernel in both the liger and dev optional dependency groups.

liger-kernel pulls in Triton, which only publishes Linux wheels, so unconditional inclusion made the resolver fail before any packages installed. On non-Linux platforms this matches existing behavior: Liger/Triton kernels are not usable there, and availability checks plus require_liger_kernel already skip runtime and test paths when the package is absent.

Reviewed by Cursor Bugbot for commit 18adad0. Bugbot is set up for automated code reviews on this repo. Configure here.

@bot-ci-comment

bot-ci-comment Bot commented Jul 8, 2026

Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

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