Skip to content

Commit c62a673

Browse files
Standardize CI workflows with 'make' and 'uv' integration (#187)
* Update workflow to replace 'uv sync' with 'make' Replaces the use of `uv sync` with `make` across multiple GitHub Actions workflows to standardize the setup process. This simplifies and unifies the build steps for better maintainability and consistency across projects. Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> * Refactor CI workflows to use 'uv' for Python setup and dependency management Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> * Bump hypothesis from 6.135.0 to 6.135.1 (#188) Bumps [hypothesis](https://github.com/HypothesisWorks/hypothesis) from 6.135.0 to 6.135.1. - [Release notes](https://github.com/HypothesisWorks/hypothesis/releases) - [Commits](HypothesisWorks/hypothesis@hypothesis-python-6.135.0...hypothesis-python-6.135.1) --- updated-dependencies: - dependency-name: hypothesis dependency-version: 6.135.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump ruff from 0.11.12 to 0.11.13 (#189) Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.12 to 0.11.13. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](astral-sh/ruff@0.11.12...0.11.13) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.13 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Switch CI workflows to `uv` and remove `poetry.lock` Updated CI workflows to use `uv` for consistent dependency management and simplified commands, replacing `poetry` where applicable. Removed `poetry.lock` as it's no longer relevant with the transition to `uv`. Improved testing and documentation steps for better compatibility across platforms and Python versions. Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> * Update workflow to replace 'uv sync' with 'make' Replaces the use of `uv sync` with `make` across multiple GitHub Actions workflows to standardize the setup process. This simplifies and unifies the build steps for better maintainability and consistency across projects. Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> * Refactor CI workflows to use 'uv' for Python setup and dependency management Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> * Switch CI workflows to `uv` and remove `poetry.lock` Updated CI workflows to use `uv` for consistent dependency management and simplified commands, replacing `poetry` where applicable. Removed `poetry.lock` as it's no longer relevant with the transition to `uv`. Improved testing and documentation steps for better compatibility across platforms and Python versions. Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> * Add Renovate configuration for automated dependency management Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> --------- Signed-off-by: DanielAvdar <66269169+DanielAvdar@users.noreply.github.com> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 parent 6715660 commit c62a673

File tree

13 files changed

+1567
-1882
lines changed

13 files changed

+1567
-1882
lines changed

.github/workflows/ci.yml

Lines changed: 12 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,26 @@
1-
name: PR tests
1+
name: Tests
22
on:
33
pull_request:
4+
paths:
5+
- 'ml_orchestrator/**'
6+
- 'tests/**'
7+
- '.github/workflows/ci.yml'
8+
- 'pyproject.toml'
9+
- 'uv.lock'
410
workflow_dispatch:
5-
6-
711
jobs:
8-
tests:
12+
pytest:
913
runs-on: ${{ matrix.os }}
1014
strategy:
1115
matrix:
1216
os: [ ubuntu-latest, macos-latest, windows-latest ]
1317
python-version: [ '3.9', '3.10', '3.11', '3.12', '3.13' ]
1418
steps:
1519
- uses: actions/checkout@v4
16-
- run: pipx install poetry
17-
- run: poetry check
18-
- uses: actions/setup-python@v5
20+
- uses: astral-sh/setup-uv@v6
1921
with:
20-
python-version: ${{ matrix.python-version }}
21-
cache: poetry
22+
enable-cache: true
23+
- run: uv python install ${{ matrix.python-version }}
24+
- run: make test
2225

23-
- run: poetry install --all-extras
24-
- run: poetry run pytest
2526
continue-on-error: true
26-
check-docs-build:
27-
runs-on: ubuntu-latest
28-
steps:
29-
- uses: actions/checkout@v4
30-
- run: pipx install poetry
31-
- run: poetry check
32-
- uses: actions/setup-python@v5
33-
with:
34-
python-version: '3.11'
35-
cache: poetry
36-
- run: make
37-
- run: make doc

.github/workflows/code-checks.yml

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,24 @@ on:
44
pull_request:
55
workflow_dispatch:
66
jobs:
7-
lint:
8-
name: Code Check
7+
pre-commit-hooks:
98
runs-on: ubuntu-latest
109

1110
steps:
1211
- uses: actions/checkout@v4
13-
- run: pipx install poetry
14-
- uses: actions/setup-python@v5
12+
- uses: astral-sh/setup-uv@v6
1513
with:
16-
python-version: ${{ matrix.python-version }}
17-
cache: poetry
18-
19-
20-
- run: make
14+
enable-cache: true
15+
- run: uv python install 3.12
2116
- run: make check
17+
18+
typecheck:
19+
name: Types Check
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@v4
23+
- uses: astral-sh/setup-uv@v6
24+
with:
25+
enable-cache: true
26+
- run: uv python install 3.12
2227
- run: make mypy

.github/workflows/codecov.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,14 @@ on:
1111
workflow_dispatch:
1212
jobs:
1313
upload-coverage-report:
14+
name: Upload Report
1415
runs-on: ubuntu-latest
1516
steps:
1617
- uses: actions/checkout@v4
17-
- run: pipx install poetry
18-
- uses: actions/setup-python@v5
18+
- uses: astral-sh/setup-uv@v6
1919
with:
20-
python-version: '3.11'
21-
cache: poetry
22-
23-
- run: make
20+
enable-cache: true
21+
- run: uv python install 3.12
2422
- run: make coverage
2523
- uses: codecov/codecov-action@v5
2624
with:

.github/workflows/copilot-setup-steps.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ jobs:
1616
with:
1717
enable-cache: true
1818
- run: uv python install 3.11
19-
- run: uv sync --all-extras --all-groups --frozen
19+
- run: make

.github/workflows/docs.yml

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
name: Publish docs
1+
name: Doc-Test
22
on:
3-
release:
4-
types: [ published ]
3+
pull_request:
54
workflow_dispatch:
65

76
permissions:
@@ -16,19 +15,8 @@ jobs:
1615

1716
steps:
1817
- uses: actions/checkout@v4
19-
- run: pipx install poetry
20-
- run: poetry check
21-
- uses: actions/setup-python@v5
18+
- uses: astral-sh/setup-uv@v6
2219
with:
23-
python-version: '3.11'
24-
cache: poetry
25-
26-
- run: make
27-
- run: make doc
28-
29-
- name: Deploy
30-
uses: peaceiris/actions-gh-pages@v4
31-
with:
32-
github_token: ${{ secrets.GITHUB_TOKEN }}
33-
publish_dir: ./docs/build
34-
keep_files: true
20+
enable-cache: true
21+
- run: uv python install 3.12
22+
- run: make doctest

.github/workflows/parsing-checks.yml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,9 @@ jobs:
1010

1111
steps:
1212
- uses: actions/checkout@v4
13-
- run: pipx install poetry
14-
- uses: actions/setup-python@v5
13+
- uses: astral-sh/setup-uv@v6
1514
with:
16-
python-version: ${{ matrix.python-version }}
17-
cache: poetry
15+
enable-cache: true
1816

1917

2018
- run: make
@@ -36,13 +34,11 @@ jobs:
3634

3735
steps:
3836
- uses: actions/checkout@v4
39-
- run: pipx install poetry
40-
- run: poetry check
41-
- uses: actions/setup-python@v5
37+
- uses: astral-sh/setup-uv@v6
4238
with:
43-
python-version: '3.11'
39+
enable-cache: true
4440

45-
- run: poetry build
41+
- run: uv build
4642
- run: pip install dist/*.whl
4743
- run: python -m dummy_components.check_imports
4844
continue-on-error: true

.github/workflows/publish.yml

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,9 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- uses: actions/checkout@v4
15-
- run: pipx install poetry
16-
- uses: actions/setup-python@v5
17-
- run: poetry install --all-extras
18-
- run: poetry run pytest
19-
- run: poetry version ${{ github.ref_name }}
20-
- run: poetry build
21-
- run: poetry config pypi-token.pypi ${{ secrets.PYPI_API_TOKEN }}
22-
- run: poetry publish
15+
- uses: astral-sh/setup-uv@v6
16+
- run: uv python install 3.11
17+
- run: make
18+
- run: make test
19+
- run: uv build
20+
- run: uv publish --token ${{ secrets.PYPI_API_TOKEN }}

Makefile

Lines changed: 27 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,35 @@
33
default: install
44

55
install:
6-
poetry install --all-extras --all-groups
7-
# poetry run pre-commit autoupdate
8-
poetry run pre-commit install
6+
uv sync --all-extras --all-groups --frozen
7+
uvx pre-commit install
98

10-
test:
11-
poetry run pytest
12-
coverage:
13-
poetry run pytest --cov=ml_orchestrator --cov-report=xml --junitxml=junit.xml -o junit_family=legacy
9+
update:
10+
uv lock
11+
uvx pre-commit autoupdate
12+
$(MAKE) install
1413

15-
cov:
16-
poetry run pytest --cov=ml_orchestrator --cov-report=term-missing
14+
test: install
15+
uv run pytest
1716

18-
check:
19-
poetry run pre-commit run --all-files
20-
mypy:
21-
poetry run mypy ml_orchestrator --config-file pyproject.toml
17+
coverage: install
18+
uv run pytest --cov=ml_orchestrator --cov-report=xml --junitxml=junit.xml -o junit_family=legacy
19+
20+
cov: install
21+
uv run pytest --cov=ml_orchestrator --cov-report=term-missing
22+
23+
check: install
24+
uvx pre-commit run --all-files
25+
26+
mypy: install
27+
uv run mypy ml_orchestrator --config-file pyproject.toml
28+
29+
doctest: install-docs doc
30+
31+
install-docs:
32+
uv sync --group docs --frozen --no-group dev
2233

2334
doc:
24-
poetry run sphinx-build -M html docs/source docs/build/
35+
uv run --no-sync sphinx-build -M html docs/source docs/build/ -W --keep-going --fresh-env
36+
37+
check-all: check test mypy doc

0 commit comments

Comments
 (0)