Skip to content

Replace setup.py with uv-compatible pyproject.toml#945

Open
kevalmorabia97 wants to merge 2 commits intomainfrom
kmorabia/remove-seutp.py
Open

Replace setup.py with uv-compatible pyproject.toml#945
kevalmorabia97 wants to merge 2 commits intomainfrom
kmorabia/remove-seutp.py

Conversation

@kevalmorabia97
Copy link
Collaborator

@kevalmorabia97 kevalmorabia97 commented Feb 27, 2026

What does this PR do?

Type of change: Project config update

Remove unnecessary setup.py as the same can be done with pyproject.toml. No change for users in terms of installation command.

Testing

Per PR tests passing is sufficient validation

Summary by CodeRabbit

  • Chores
    • Migrated project configuration from setup.py to pyproject.toml, adopting modern Python packaging standards.
    • Updated CI/CD workflows and development tools to reference the new configuration location.

Signed-off-by: Keval Morabia <28916987+kevalmorabia97@users.noreply.github.com>
@kevalmorabia97 kevalmorabia97 requested a review from a team as a code owner February 27, 2026 13:28
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 27, 2026

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

The changes migrate the project's Python package configuration from setup.py to pyproject.toml, the modern Python packaging standard. All project metadata, dependencies, and optional extras are moved to pyproject.toml, CI/CD workflows and configuration files are updated to reference the new configuration file, and the legacy setup.py is removed.

Changes

Cohort / File(s) Summary
Core Package Configuration Migration
pyproject.toml, setup.py
Comprehensive project metadata, dependencies, optional extras (onnx, hf, dev-lint, dev-docs, dev-test, all/dev), and packaging configuration added to pyproject.toml; legacy setup.py completely removed.
GitHub & CI Workflow Updates
.github/CODEOWNERS, .github/workflows/example_tests.yml, .github/workflows/gpu_tests.yml, .github/workflows/unit_tests.yml
Removed setup.py CODEOWNERS entry; updated workflow changed-files triggers to detect pyproject.toml instead of setup.py.
Development Tool Configuration
.pre-commit-config.yaml, tox.ini
Updated documentation/comments to reference pyproject.toml instead of setup.py.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~22 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title accurately describes the main change: replacing setup.py with a uv-compatible pyproject.toml configuration file.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch kmorabia/remove-seutp.py

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

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (2)
pyproject.toml (2)

56-63: Consider adding a comment explaining the ONNX runtime version split.

The version constraints differ significantly between Python versions (~=1.22.0 for Python ≤3.10 vs ~=1.24.2 for Python >3.10). A brief inline comment explaining why this split exists would help future maintainers understand the rationale.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@pyproject.toml` around lines 56 - 63, Add a short inline comment above the
ONNX Runtime dependency block explaining the rationale for the Python-version
split (why "~=1.22.0" is used for python_version <= '3.10' and "~=1.24.2" for
python_version > '3.10'), referencing the specific package lines
"onnxruntime~=1.22.0", "onnxruntime-gpu~=1.22.0", "onnxruntime~=1.24.2", and
"onnxruntime-gpu~=1.24.2"; the comment should note compatibility/wheel
availability differences across Python versions and platforms (CPU vs GPU,
aarch64/Darwin/Windows) so future maintainers understand the constraint choices.

20-21: Consider using LICENSE instead of LICENSE_HEADER for license-files.

Both LICENSE and LICENSE_HEADER exist and contain the full Apache 2.0 license text. While the current configuration is valid, the conventional practice is to reference the main LICENSE file in license-files rather than LICENSE_HEADER.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@pyproject.toml` around lines 20 - 21, Update the pyproject.toml license-files
entry to reference the conventional LICENSE filename instead of LICENSE_HEADER:
change the license-files array value from "LICENSE_HEADER" to "LICENSE" so the
top-level "license-files" key points to the main license file.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In `@pyproject.toml`:
- Around line 56-63: Add a short inline comment above the ONNX Runtime
dependency block explaining the rationale for the Python-version split (why
"~=1.22.0" is used for python_version <= '3.10' and "~=1.24.2" for
python_version > '3.10'), referencing the specific package lines
"onnxruntime~=1.22.0", "onnxruntime-gpu~=1.22.0", "onnxruntime~=1.24.2", and
"onnxruntime-gpu~=1.24.2"; the comment should note compatibility/wheel
availability differences across Python versions and platforms (CPU vs GPU,
aarch64/Darwin/Windows) so future maintainers understand the constraint choices.
- Around line 20-21: Update the pyproject.toml license-files entry to reference
the conventional LICENSE filename instead of LICENSE_HEADER: change the
license-files array value from "LICENSE_HEADER" to "LICENSE" so the top-level
"license-files" key points to the main license file.

ℹ️ Review info

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 35e6099 and 44a9045.

📒 Files selected for processing (8)
  • .github/CODEOWNERS
  • .github/workflows/example_tests.yml
  • .github/workflows/gpu_tests.yml
  • .github/workflows/unit_tests.yml
  • .pre-commit-config.yaml
  • pyproject.toml
  • setup.py
  • tox.ini
💤 Files with no reviewable changes (2)
  • .github/CODEOWNERS
  • setup.py

@codecov
Copy link

codecov bot commented Feb 27, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.14%. Comparing base (35e6099) to head (7511ca8).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #945      +/-   ##
==========================================
- Coverage   72.15%   72.14%   -0.01%     
==========================================
  Files         210      209       -1     
  Lines       23515    23511       -4     
==========================================
- Hits        16967    16963       -4     
  Misses       6548     6548              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@kevalmorabia97 kevalmorabia97 requested a review from a team as a code owner February 27, 2026 20:53
@kevalmorabia97 kevalmorabia97 changed the title Replace setup.py with pyproject.toml Replace setup.py with uv-compatible pyproject.toml Feb 27, 2026
@kevalmorabia97 kevalmorabia97 force-pushed the kmorabia/remove-seutp.py branch from 9723427 to 4ce4702 Compare February 27, 2026 22:36
Signed-off-by: Keval Morabia <28916987+kevalmorabia97@users.noreply.github.com>
@kevalmorabia97 kevalmorabia97 force-pushed the kmorabia/remove-seutp.py branch from 4ce4702 to 7511ca8 Compare February 27, 2026 22:39
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.

1 participant