Skip to content

Commit

Permalink
Poetry setup
Browse files Browse the repository at this point in the history
  • Loading branch information
mwiewior committed Dec 16, 2024
1 parent 3531dda commit b1b5feb
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 10 deletions.
25 changes: 17 additions & 8 deletions .github/workflows/publish_to_pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,22 +22,23 @@ permissions:
# Make sure CI fails on all warnings, including Clippy lints
env:
RUSTFLAGS: "-Dwarnings"
POETRY_VERSION: 1.8.4

jobs:
linux_tests:
runs-on: ubuntu-latest
strategy:
matrix:
target: [x86_64]
python-version: ["3.8", "3.9", "3.10", "3.11"]
python-version: [ "3.9", "3.10", "3.11", "3.12" ]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:

python-version: ${{ matrix.python-version }}


- uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Set up Rust
run: rustup show
- uses: mozilla-actions/sccache-action@v0.0.3
Expand All @@ -56,6 +57,9 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
Expand All @@ -80,9 +84,10 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: '3.10'

architecture: ${{ matrix.target }}

- uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
Expand All @@ -108,12 +113,13 @@ jobs:
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:

target: ${{ matrix.target }}

args: --release --out dist --find-interpreter
sccache: 'true'
- name: Upload wheels
Expand All @@ -128,6 +134,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Build sdist
uses: PyO3/maturin-action@v1
with:
Expand Down
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ SHELL=/bin/bash

venv: ## Set up virtual environment
python3 -m venv .venv
.venv/bin/pip install -r requirements.txt
poetry lock --no-update
poetry install

install: venv
unset CONDA_PREFIX && \
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ authors = ["Marek Wiewiórka <marek.wiewiorka@gmail.com>"]
readme = "README.md"

[tool.poetry.dependencies]
python = ">=3.9,<3.13"
python = ">=3.8,<3.13"
polars = "^1.16.0"
pandas = "^2.2.3"

Expand Down

0 comments on commit b1b5feb

Please sign in to comment.