Skip to content

Commit 914144c

Browse files
authored
chore: release of 0.10.0
Merge pull request #154 from Logic-py/develop
2 parents 659a351 + 0d16069 commit 914144c

12 files changed

Lines changed: 394 additions & 625 deletions

File tree

.github/actions/code-quality/action.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@ runs:
1616
- name: Run Ruff Formatting
1717
if: inputs.check-type == 'format'
1818
shell: bash
19-
run: poetry run ruff format --config pyproject.toml ${{ inputs.source-dir }}
19+
run: uv run ruff format --config pyproject.toml ${{ inputs.source-dir }}
2020

2121
- name: Run Ruff Linting
2222
if: inputs.check-type == 'lint'
2323
shell: bash
24-
run: poetry run ruff check --config pyproject.toml ${{ inputs.source-dir }}
24+
run: uv run ruff check --config pyproject.toml ${{ inputs.source-dir }}
2525

2626
- name: Run Mypy Type Checking
2727
if: inputs.check-type == 'type-check'
2828
shell: bash
29-
run: poetry run mypy --config-file pyproject.toml ${{ inputs.source-dir }}
29+
run: uv run mypy --config-file pyproject.toml ${{ inputs.source-dir }}
Lines changed: 7 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,24 @@
11
name: "Setup Environment"
2-
description: "Sets up Python, Poetry, and dependencies with caching"
2+
description: "Sets up Python, uv, and dependencies with caching"
33

44
inputs:
55
python-version:
66
description: "Python version to use"
77
required: false
88
default: "3.14"
9-
cache-key-suffix:
10-
description: "Additional suffix for cache key"
11-
required: false
12-
default: ""
139

1410
runs:
1511
using: "composite"
1612
steps:
17-
- name: Set up Python
18-
uses: actions/setup-python@v5
13+
- name: Install uv
14+
uses: astral-sh/setup-uv@v5
1915
with:
20-
python-version: ${{ inputs.python-version }}
16+
enable-cache: true
2117

22-
- name: Install Poetry
18+
- name: Set up Python
2319
shell: bash
24-
run: pip install poetry
25-
26-
- name: Cache Poetry dependencies
27-
uses: actions/cache@v4
28-
with:
29-
path: |
30-
~/.cache/pypoetry
31-
~/.poetry
32-
key: ${{ runner.os }}-poetry-${{ hashFiles('**/poetry.lock') }}${{ inputs.cache-key-suffix }}
20+
run: uv python install ${{ inputs.python-version }}
3321

3422
- name: Install dependencies
3523
shell: bash
36-
run: poetry install
24+
run: uv sync

.github/dependabot.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
55
version: 2
66
updates:
7-
# Update dependencies for Python (Poetry)
8-
- package-ecosystem: "pip"
7+
# Update dependencies for Python (uv)
8+
- package-ecosystem: "uv"
99
directory: "/"
1010
schedule:
1111
interval: "daily"

.github/workflows/config.yml

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,6 @@ on:
66
python-version:
77
description: "Python version to use"
88
value: "3.14"
9-
poetry-cache-path:
10-
description: "Poetry cache paths"
11-
value: |
12-
~/.cache/pypoetry
13-
~/.poetry
149
source-dir:
1510
description: "Source directory to check"
1611
value: "src/"
@@ -20,9 +15,6 @@ jobs:
2015
runs-on: ubuntu-latest
2116
outputs:
2217
python-version: "3.14"
23-
poetry-cache-path: |
24-
~/.cache/pypoetry
25-
~/.poetry
2618
source-dir: "src/"
2719
steps:
28-
- run: echo "Shared configuration loaded"
20+
- run: echo "Shared configuration loaded"

.github/workflows/main.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ jobs:
6767
with:
6868
python-version: ${{ needs.config.outputs.python-version }}
6969
- name: Run Tests
70-
run: poetry run pytest
70+
run: uv run pytest
7171

7272
release:
7373
needs: [ config, setup, format, lint, type-check, test ]
@@ -84,7 +84,7 @@ jobs:
8484
- name: Read version from pyproject.toml
8585
id: get_version
8686
run: |
87-
VERSION=$(poetry version --short)
87+
VERSION=$(python -c "import tomllib; print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")
8888
echo "VERSION=${VERSION}" >> $GITHUB_ENV
8989
9090
- name: Check if release exists
@@ -118,7 +118,7 @@ jobs:
118118
run: |
119119
chmod +x .github/generate_changelog.sh
120120
source .github/generate_changelog.sh
121-
121+
122122
echo "CHANGELOG<<EOF" >> $GITHUB_ENV
123123
if [ -n "${{ env.PREV_TAG }}" ]; then
124124
generate_categorized_changelog "${{ env.PREV_TAG }}" >> $GITHUB_ENV
@@ -135,10 +135,10 @@ jobs:
135135
name: ${{ env.VERSION }}
136136
body: |
137137
${{ env.CHANGELOG }}
138-
138+
139139
**Full Changelog**: ${{ env.URL }}
140140
draft: false
141141
prerelease: false
142142
target_commitish: main
143143
env:
144-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
144+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -94,12 +94,10 @@ ipython_config.py
9494
# install all needed dependencies.
9595
#Pipfile.lock
9696

97-
# poetry
98-
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
99-
# This is especially recommended for binary packages to ensure reproducibility, and is more
100-
# commonly ignored for libraries.
101-
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
102-
#poetry.lock
97+
# uv
98+
# uv.lock should be committed to version control to ensure reproducible installs.
99+
# https://docs.astral.sh/uv/concepts/projects/layout/#the-lockfile
100+
#uv.lock
103101

104102
# pdm
105103
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.

.pre-commit-config.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,22 +11,22 @@ repos:
1111
hooks:
1212
- id: ruff-format
1313
name: Formatting
14-
entry: poetry run ruff format
15-
language: python
14+
entry: uv run ruff format
15+
language: system
1616
types_or: [ python, pyi, jupyter ]
1717
pass_filenames: true
1818

1919
- id: ruff-lint
2020
name: Linting
21-
entry: poetry run ruff check
22-
language: python
21+
entry: uv run ruff check
22+
language: system
2323
types_or: [ python, pyi, jupyter ]
2424
pass_filenames: true
2525
exclude: tests
2626

2727
- id: mypy-type-check
2828
name: Type Checking
29-
entry: poetry run mypy
30-
language: python
29+
entry: uv run mypy
30+
language: system
3131
types_or: [ python, pyi, jupyter ]
3232
pass_filenames: true

.python-version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
3.14.2
1+
3.14.3

README.md

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,17 @@ Follow these steps to get started with this template:
3333

3434
1. **Clone the repository or use the template directly via GitHub.**
3535

36-
2. **Install Poetry:**
36+
2. **Install uv:**
3737

38-
Ensure you have [Poetry](https://python-poetry.org/) installed. If not, you can install it using:
38+
Ensure you have [uv](https://docs.astral.sh/uv/) installed. If not, you can install it using:
3939
```bash
40-
pip install poetry
40+
curl -LsSf https://astral.sh/uv/install.sh | sh
4141
```
42-
> **Note:** This template is set up using Poetry version 1.8.5.
4342

4443
3. **Install dependencies:**
4544

4645
```bash
47-
poetry install
46+
uv sync
4847
```
4948

5049
4. **Ready to Implement:**
@@ -57,7 +56,7 @@ Follow these steps to get started with this template:
5756
This project includes a continuous integration (CI) workflow that is triggered on every push and pull request, using
5857
GitHub Actions to run the following jobs:
5958

60-
1. **Setup**: Checks out the code, sets up Python, and installs dependencies using Poetry.
59+
1. **Setup**: Checks out the code, sets up Python, and installs dependencies using uv.
6160
2. **Format**: Formats the code with Ruff.
6261
3. **Lint**: Runs linting on the codebase with Ruff.
6362
4. **Type Check**: Checks for type consistency using Mypy.
@@ -79,10 +78,10 @@ This project includes the following dependencies:
7978
- `loguru`: ^0.7.3 (useful logging package)
8079

8180
- **Development Dependencies**:
82-
- `ruff`: ^0.8.x (for code linting and formatting)
81+
- `ruff`: ^0.14.x (for code linting and formatting)
8382
- `mypy`: ^1.x.y (for type checking)
8483
- `pre-commit`: ^4.x.y (for managing Git hooks)
85-
- `pytest`: ^8.x.y (for unit testing)
84+
- `pytest`: ^9.x.y (for unit testing)
8685

8786
### Optional: Pyenv
8887

@@ -147,20 +146,20 @@ This repository employs several tools to ensure code quality:
147146
To set up pre-commit hooks for automatic formatting and linting on commit, ensure `pre-commit` is installed:
148147

149148
```bash
150-
poetry install
149+
uv sync
151150
```
152151

153152
Then, install the hooks:
154153

155154
```bash
156-
poetry run pre-commit install
155+
uv run pre-commit install
157156
```
158157

159158
Once installed, the hooks will run automatically before each commit.
160159

161160
### Pre-commit Hooks Configuration
162161

163-
This repository uses pre-commit hooks to enforce code quality and standards before committing changes. Heres an
162+
This repository uses pre-commit hooks to enforce code quality and standards before committing changes. Here's an
164163
overview of the configured hooks:
165164

166165
#### 1. Commitlint Hook
@@ -179,13 +178,13 @@ overview of the configured hooks:
179178
You can run specific hooks manually using:
180179

181180
```bash
182-
poetry run pre-commit run <HOOK-ID>
181+
uv run pre-commit run <HOOK-ID>
183182
```
184183

185184
For example, to run the Ruff formatter:
186185

187186
```bash
188-
poetry run pre-commit run ruff-format
187+
uv run pre-commit run ruff-format
189188
```
190189

191190
For more information on pre-commit, visit [pre-commit.com](https://pre-commit.com).

0 commit comments

Comments
 (0)