Skip to content

Conversation

@tkersey
Copy link
Contributor

@tkersey tkersey commented Feb 27, 2025

Refactor GitHub workflows to use uv for setup and project installation

  • Replaced setup from local action to astral-sh/setup-uv@v5 and actions/setup-python@v5.
  • Updated Python setup to use python-version-file: "pyproject.toml".
  • Changed project installation command to uv sync --all-extras --dev.
  • Modified test commands to use uv run instead of poetry run.
  • Updated documentation link in README

@tkersey tkersey self-assigned this Feb 27, 2025
@tkersey tkersey requested review from Copilot and paulz February 27, 2025 16:05
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

PR Overview

This PR refactors the project to transition from Poetry to uv for dependency management, project installation, and test execution. Key changes include:

  • Updating pyproject.toml to use the new [project] configuration and uv settings with Hatchling.
  • Modifying GitHub workflows to install uv, set up Python, and run tests and commands using uv.
  • Revising documentation and README links and commands to reflect the switch from Poetry to uv.

Reviewed Changes

File Description
pyproject.toml Refactors configuration from Poetry to uv and Hatchling
.github/workflows/cat-test-examples.yml Updates steps to install uv and run tests using uv
.github/workflows/python-tests.yml Similar update to install uv and run tests commands
examples/team_recommender/readme.md Updates local setup instructions to use uv
docs/getting-started.md Adds instructions to use uv for project setup
README.md Switches test and code quality commands to uv and updates documentation links

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Comments suppressed due to low confidence (2)

.github/workflows/cat-test-examples.yml:35

  • The test command now targets a specific subdirectory which differs from the previous broader directory. Please verify that the new path is correct and intentional for running the example tests.
run: uv run pytest examples/team_recommender/tests/example_4_gate_on_success_threshold/

README.md:37

  • The archive link has been updated from pointing to 'wiki/ARCHIVE.md' to 'wiki'. Please confirm that this change correctly reflects the new location of the archive content.
- [Archive - To see potentially helpful previous iterations of the code](wiki)

@tkersey tkersey requested a review from Copilot February 27, 2025 17:04
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

PR Overview

This PR transitions the project’s workflows and configuration from Poetry to uv, updating the setup, installation, and test commands accordingly. Key changes include:

  • Refactoring the pyproject.toml to use the [project] section with dependency groups instead of Poetry’s configuration.
  • Updating GitHub workflows to install and run the project using uv instead of Poetry.
  • Modifying documentation and example files to reflect the new uv-based setup.

Reviewed Changes

File Description
pyproject.toml Refactored project configuration and dependency groups.
.github/workflows/cat-test-examples.yml Replaced Poetry steps with uv installation and command usage.
.github/workflows/python-tests.yml Updated test workflow to use uv for linting and testing commands.
docs/getting-started.md Added uv installation instructions alongside existing setup info.
examples/team_recommender/readme.md Updated local setup instructions to use uv commands instead of Poetry.
README.md Revised test and code quality commands and updated documentation links.
examples/team_recommender/conftest.py Removed an unused import to clean up the file.

Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.

Copy link
Contributor

@paulz paulz left a comment

Choose a reason for hiding this comment

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

thank you!

tkersey and others added 2 commits February 27, 2025 20:42
- Replaced setup from local action to `astral-sh/setup-uv@v5` and `actions/setup-python@v5`.
- Updated Python setup to use `python-version-file: "pyproject.toml"`.
- Changed project installation command to `uv sync --all-extras --dev`.
- Modified test commands to use `uv run` instead of `poetry run`.
- Updated documentation link in README

Signed-off-by: Tim Kersey <[email protected]>
@paulz paulz merged commit 98f5591 into main Feb 28, 2025
2 checks passed
@paulz paulz deleted the transition-to-uv branch February 28, 2025 04:45
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.

3 participants