Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch from poetry to uv #97

Merged
merged 1 commit into from
Sep 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,14 @@ jobs:
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install poetry
uses: abatilo/actions-poetry@v3
- name: Install uv
uses: yezz123/setup-uv@v4
- name: Dependencies
run: |
poetry config virtualenvs.create false
poetry install
uv sync --no-cache
- name: Lint
run: |
poe lint
uv run poe lint
- name: Tests
env:
RTM_API_KEY: ${{ secrets.RTM_API_KEY }}
Expand All @@ -40,7 +39,7 @@ jobs:
if: ${{needs.secrets.outputs.valid}} == 'true'
run: |
if python --version | grep -q 'Python 3.12' ; then
poe test-with-coverage
uv run poe test-with-coverage
fi
- name: Codecov
uses: codecov/codecov-action@v4
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
rtm-token.txt
__pycache__/
dist/
poetry.lock
uv.lock
.env
.pytest_cache
.vscode
Expand Down
53 changes: 28 additions & 25 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[tool.poetry]
[project]
name = "rtmilk"
version = "2.1.0"
description = "Remember The Milk API wrapper"
authors = ["Rehan Khwaja <[email protected]>"]
license = "MIT"
homepage = "https://github.com/rkhwaja/rtmilk"
maintainers = [
{ name = "Rehan Khwaja", email = "[email protected]" }
]
keywords = ["RememberTheMilk", "Remember", "Milk"]
readme = "README.md"
classifiers = [
Expand All @@ -16,26 +16,21 @@ classifiers = [
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12"
]

[tool.poetry.dependencies]
python = ">=3.9,<4"
requests = ">=2.23.0"
urllib3 = [
{ version = ">=1.26", python = ">=3.10,<4" }
requires-python = ">=3.9"
dependencies = [
"requests>=2.23.0",
"urllib3>=1.26; python_version>='3.10'",
"pydantic>=2.4.2",
"aiohttp>=3.9",
"listdiff>=1.0.2",
]
pydantic = ">=2.4.2"
aiohttp = ">=3.9"
listdiff = ">=1.0.2"

[tool.poetry.group.dev.dependencies]
pytest = ">=7.1"
pyperclip = ">=1.8.0"
python-dateutil = ">=2.8.1"
python-dotenv = ">=0.17.1"
pytest-cov = ">=3"
pytest-asyncio = ">=0.16.0"
poethepoet = ">=0.16.4"
ruff = ">=0.6.3"
[project.urls]
Homepage = "https://github.com/rkhwaja/rtmilk"

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[tool.poe.tasks]
build = "poetry build --no-interaction"
Expand Down Expand Up @@ -66,6 +61,14 @@ multiline-quotes = "single"
[tool.pytest.ini_options]
pythonpath = ["src"]

[build-system]
requires = ["poetry_core>=1.1"]
build-backend = "poetry.core.masonry.api"
[tool.uv]
dev-dependencies = [
"pytest>=7.1",
"pyperclip>=1.8.0",
"python-dateutil>=2.8.1",
"python-dotenv>=0.17.1",
"pytest-cov>=3",
"pytest-asyncio>=0.16.0",
"poethepoet>=0.16.4",
"ruff>=0.6.3",
]
Loading