Skip to content
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
13 changes: 5 additions & 8 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,19 @@ on:

jobs:
deploy:
runs-on: ubuntu-22.04
env:
POETRY_VIRTUALENVS_CREATE: "false"
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v3

- name: Install poetry
- name: Install uv
run: |
python -m pip install --upgrade pip
pip install poetry
pip install uv

- name: Build
run: |
poetry build
uv build

- name: Publish
run: |
poetry config pypi-token.pypi ${{ secrets.PYPI_API_TOKEN }}
poetry publish
uv publish --token ${{ secrets.PYPI_API_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .[develop]
pip install -e .[dev]
- name: Typing check
run: mypy .
- name: Run tests
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ Developing
Install dependencies using pip:

```bash
pip install -e .[develop]
pip install -e .[dev]
```

Run databases:
Expand Down
11 changes: 1 addition & 10 deletions docs/peewee_async/installing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,16 +35,7 @@ Install dependencies using pip:

.. code-block:: console

pip install -e .[develop]


Or using `poetry`_:

.. _poetry: https://python-poetry.org/docs/

.. code-block:: console

poetry install -E develop
pip install -e .[dev]


Running tests
Expand Down
72 changes: 43 additions & 29 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,39 +1,53 @@
[tool.poetry]
[project]
name = "peewee-async"
version = "1.2.1"
description = "Asynchronous interface for peewee ORM powered by asyncio."
authors = ["Alexey Kinev <rudy@05bit.com>", "Gorshkov Nikolay(contributor) <nogamemorebrain@gmail.com>"]
authors = [
{name = "Alexey Kinev", email="rudy@05bit.com"},
{name = "Gorshkov Nikolay", email = "nogamemorebrain@gmail.com"},
]
requires-python = ">=3.10"
readme = "README.md"
dependencies = [
"peewee>=3.15.4",
"typing-extensions>=4.12.2"
]


[tool.poetry.dependencies]
python = "^3.10"
peewee = "^3.15.4"
typing-extensions = "^4.12.2"

aiopg = { version = "^1.4.0", optional = true }
aiomysql = { version = "^0.2.0", optional = true }
cryptography = { version = "^43.0.1", optional = true }
pytest = { version = "^7.4.1", optional = true }
pytest-asyncio = { version = "^0.21.1", optional = true }
pytest-mock = { version = "^3.14.0", optional = true }
sphinx = { version = "^7.1.2", optional = true }
sphinx-rtd-theme = { version = "^1.3.0rc1", optional = true }
mypy = { version = "^1.10.1", optional = true }
types-PyMySQL = { version = "^1.1.0.20240524", optional = true }
psycopg = { version = "^3.2.0", optional = true }
psycopg-pool = { version = "^3.2.0", optional = true }

[tool.poetry.extras]
postgresql = ["aiopg"]
mysql = ["aiomysql", "cryptography"]
develop = ["aiopg", "aiomysql", "cryptography", "pytest", "pytest-asyncio", "pytest-mock", "mypy", "types-PyMySQL", "psycopg", "psycopg-pool"]
docs = ["aiopg", "aiomysql", "cryptography", "sphinx", "sphinx-rtd-theme"]
psycopg = ["psycopg", "psycopg-pool"]
[project.optional-dependencies]
postgresql = [
"aiopg>=1.4.0",
]
mysql = [
"aiomysql>=0.2.0",
"cryptography>=43.0.1"
]
psycopg = [
"psycopg>=3.2.0",
"psycopg-pool>=3.2.0"
]
docs = [
"Sphinx>=8.1.3",
"sphinx-rtd-theme>=3.1.0",
]
dev = [
"pytest==7.4.1",
"pytest-asyncio==0.21.1",
"pytest-mock>=3.14.0",
"peewee-async[postgresql]",
"peewee-async[mysql]",
"peewee-async[psycopg]",
"mypy>=1.19.0",
"types-PyMySQL>=1.1.0"
]

[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
requires = ["uv_build>=0.9.6,<0.10.0"]
build-backend = "uv_build"

[tool.uv.build-backend]
module-name = "peewee_async"
module-root = ""

[tool.mypy]
python_version = "3.10"
Expand All @@ -52,4 +66,4 @@ disallow_incomplete_defs = true
exclude = "(venv|load-testing|examples|docs)"

[tool.pytest.ini_options]
asyncio_mode = "auto"
asyncio_mode = "auto"