Skip to content

CI: Constrain all dependencies; introduce a Monday workflow to update pins #558

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 30, 2025

Conversation

booxter
Copy link
Contributor

@booxter booxter commented May 21, 2025

Closes: #541

@mergify mergify bot added CI/CD Affects CI/CD configuration testing Relates to testing dependencies Pull requests that update a dependency file labels May 21, 2025
@booxter booxter marked this pull request as draft May 21, 2025 14:05
@mergify mergify bot added the ci-failure label May 21, 2025
@booxter booxter force-pushed the constraints branch 2 times, most recently from 9cd5100 to 82c4916 Compare May 22, 2025 15:20
@mergify mergify bot added ci-failure and removed ci-failure labels May 22, 2025
@mergify mergify bot added the ci-failure label May 22, 2025
@mergify mergify bot added ci-failure and removed ci-failure labels May 22, 2025
@booxter
Copy link
Contributor Author

booxter commented May 22, 2025

The smoke failure is generic: #505 but I wonder how come we hit it twice here.

@mergify mergify bot added ci-failure and removed ci-failure labels May 22, 2025
@booxter
Copy link
Contributor Author

booxter commented May 28, 2025

@Mergifyio rebase

Copy link
Contributor

mergify bot commented May 28, 2025

rebase

✅ Branch has been successfully rebased

@booxter
Copy link
Contributor Author

booxter commented May 28, 2025

@booxter booxter marked this pull request as ready for review May 29, 2025 10:05
Copy link
Member

@nathan-weinberg nathan-weinberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, will leave second approval to @instructlab/training-maintainers so they can indicate if they are happy with this direction

@nathan-weinberg nathan-weinberg requested a review from a team May 29, 2025 14:43
@mergify mergify bot added the one-approval label May 29, 2025
Signed-off-by: Ihar Hrachyshka <[email protected]>
@@ -41,7 +41,7 @@ runs:
run: |
source venv/bin/activate
# The list is taken from the pull request linked above
pip install torch packaging setuptools wheel psutil ninja
pip install torch packaging setuptools wheel psutil ninja -c constraints-dev.txt
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I totally get that we have to do this step for flash-attn.

We have to use tox-current-env to enable this workaround, correct? i.e. because we can't build our venv in a single shot (what Tox supports) we instead have to do a four-part environment build:

  1. install Tox
  2. install the dependencies for flash-attention
  3. install tox-current-env
  4. run full package installation (including FA build and local package build)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Is there some concern here? Not sure if the comment should be addressed in some form, or just acknowledged. :) Let me know!

pip install .
pip_install="pip install -c constraints-dev.txt"
$pip_install -r ./deps.txt --no-build-isolation
$pip_install .
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we've installed the other project deps via $pip_install -r ./deps.txt --no-build-isolation do we want to do a --no-deps installation here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure. I think the effect will be the same, since we indeed already pre-installed all dependencies, (with constraints enforced), but I'd rather not if it's not required. Do you think of some specific scenario where omitting --no-deps could bite us?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think effect is the same essentially

Copy link
Contributor

@JamesKunstle JamesKunstle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks very good, mostly makes total sense to me. A few comments.

booxter added 2 commits May 29, 2025 18:13
It will pull the `uv` based implementation that is a lot more speedy and
robust.

Signed-off-by: Ihar Hrachyshka <[email protected]>
pip install .
pip_install="pip install -c constraints-dev.txt"
$pip_install -r ./deps.txt --no-build-isolation
$pip_install .
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think effect is the same essentially

# install with Torch and build dependencies installed
python3.11 -m pip install packaging wheel setuptools-scm
python3.11 -m pip install .[cuda] -r requirements-vllm-cuda.txt
PYTHON=python3.11 ./scripts/install-ilab-with-cuda.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice sneaking this in here :) we needed to switch to this anyway

@mergify mergify bot merged commit e8cb0a0 into instructlab:main May 30, 2025
19 checks passed
@mergify mergify bot removed the one-approval label May 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI/CD Affects CI/CD configuration dependencies Pull requests that update a dependency file testing Relates to testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI: constrain all packages to avoid unexpected breakages
4 participants