Skip to content

Fix setuptools constraint for pip >= 26.2 via PIP_BUILD_CONSTRAINT - #227

Merged
klemen1999 merged 1 commit into
mainfrom
fix/pip-build-constraint
Jul 31, 2026
Merged

Fix setuptools constraint for pip >= 26.2 via PIP_BUILD_CONSTRAINT#227
klemen1999 merged 1 commit into
mainfrom
fix/pip-build-constraint

Conversation

@klemen1999

@klemen1999 klemen1999 commented Jul 31, 2026

Copy link
Copy Markdown
Collaborator

Purpose

pip 26.2 enforces that PIP_CONSTRAINT no longer applies to isolated build environments, so the setuptools pin stopped protecting the mmcv sdist build (setup.py imports pkg_resources, removed in setuptools 82). Export PIP_BUILD_CONSTRAINT alongside PIP_CONSTRAINT and relax the unittests pin to the verified bound (<82, matching end2end and constraints.txt).

Specification

None / not applicable

Dependencies & Potential Impact

None / not applicable

Deployment Plan

None / not applicable

Testing & Validation

None / not applicable

AI Usage

Assisted-by: AGENT_NAME:MODEL_VERSION [TOOL1] [TOOL2]

Submitted code was reviewed by a human: YES/NO

The author is taking the responsibility for the contribution: YES/NO

Summary by CodeRabbit

  • Documentation

    • Updated installation guidance to support pip’s isolated build environments and ensure compatible package builds.
  • Chores

    • Improved automated test and installation workflows by applying consistent dependency constraints during builds.

pip 26.2 enforces that PIP_CONSTRAINT no longer applies to isolated
build environments, so the setuptools pin stopped protecting the mmcv
sdist build (setup.py imports pkg_resources, removed in setuptools 82).
Export PIP_BUILD_CONSTRAINT alongside PIP_CONSTRAINT and relax the
unittests pin to the verified bound (<82, matching end2end and
constraints.txt).
@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 60472b22-a68b-424c-9678-f6242d2b630e

📥 Commits

Reviewing files that changed from the base of the PR and between fa3d3d7 and 36462c3.

📒 Files selected for processing (3)
  • .github/workflows/end2end_tests.yaml
  • .github/workflows/unittests.yaml
  • README.md

📝 Walkthrough

Walkthrough

The pull request applies PIP_BUILD_CONSTRAINT alongside PIP_CONSTRAINT in CI workflows and README installation instructions. The unit-test workflow also changes the setuptools constraint from <81 to <82.

Changes

Build constraint updates

Layer / File(s) Summary
CI isolated-build constraints
.github/workflows/end2end_tests.yaml, .github/workflows/unittests.yaml
Dependency installation exports PIP_BUILD_CONSTRAINT with the generated constraints file. The unit-test workflow allows setuptools<82 and applies both variables when installing luxonis-ml.
Installation command update
README.md
The installation command exports both PIP_CONSTRAINT and PIP_BUILD_CONSTRAINT.

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding PIP_BUILD_CONSTRAINT to enforce the setuptools constraint for pip 26.2 and later.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/pip-build-constraint

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
2028 1130 56% 0% 🟢

New Files

No new covered files...

Modified Files

No covered modified files...

updated for commit: 36462c3 by action🐍

@github-actions

Copy link
Copy Markdown

Test Results

  6 files    6 suites   14m 23s ⏱️
 32 tests  32 ✅ 0 💤 0 ❌
192 runs  192 ✅ 0 💤 0 ❌

Results for commit 36462c3.

@klemen1999
klemen1999 merged commit f3c1c2c into main Jul 31, 2026
28 checks passed
@klemen1999
klemen1999 deleted the fix/pip-build-constraint branch July 31, 2026 09:47
klemen1999 added a commit to luxonis/luxonis-ml that referenced this pull request Jul 31, 2026
Picks up the PIP_BUILD_CONSTRAINT fix (luxonis/tools#227) needed since
pip >= 26.2 no longer applies PIP_CONSTRAINT to isolated build
environments, which broke the mmcv sdist build in the BOM tools tests.
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