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
12 changes: 7 additions & 5 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.8.18, 3.10.18, 3.12.11]
python-version: ["3.10", "3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4

Expand All @@ -20,11 +20,13 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- name: Install Poetry
run: pip install poetry
- name: Install uv
uses: astral-sh/setup-uv@v4
with:
enable-cache: true

- name: Install dependencies
run: poetry install -v
run: uv sync --all-extras

- name: Run tests
run: poetry run pytest
run: uv run pytest
18 changes: 10 additions & 8 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.12.11]
python-version: ["3.12"]
steps:
- uses: actions/checkout@v4

Expand All @@ -19,17 +19,19 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- name: Install Poetry
run: pip install poetry
- name: Install uv
uses: astral-sh/setup-uv@v4

- name: Install dependencies
run: poetry install -v
run: uv sync --all-extras

- name: Run tests
run: poetry run pytest
run: uv run pytest

- name: Configure PyPI credentials
run: poetry config http-basic.pypi ${{ secrets.PYPI_USER }} ${{ secrets.PYPI_PASSWORD }}
- name: Build package
run: uv build

- name: Publish to PyPI
run: poetry publish --build --no-interaction
run: uv publish
env:
UV_PUBLISH_TOKEN: ${{ secrets.PYPI_TOKEN }}
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ coverage
.history
__pycache__

debug.py
debug.py
.serena/
1 change: 1 addition & 0 deletions .python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.10
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
install:
poetry install
uv sync --all-extras

test:
poetry run pytest
uv run --all-extras pytest

build:
poetry build
uv build

clean:
rm -rf dist
Expand Down
31 changes: 25 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,36 @@ Install with:
pip install obiba-opal
```

Note: `obiba-opal` depends on `pycurl` which itself depends on system libraries (mostly OpenSSL related). In case `pycurl` installation
fails with **pip**, a quick fix is to install it via a system package:
## Development

This project uses [uv](https://docs.astral.sh/uv/) for dependency management and packaging.

### Setup Development Environment

1. Install uv:

See [uv installation](https://docs.astral.sh/uv/getting-started/installation/).

2. Install dependencies:
```shell
# on Debian systems
sudo apt-get install python3-pycurl
uv sync
```

# on RPM systems
sudo yum install python3-pycurl
3. Run tests:
```shell
uv run pytest
```

4. Build the package:
```shell
uv build
```

### Requirements

- Python 3.10 or higher
- uv (for development)

### CLI

To get the options of the command line:
Expand Down
Loading
Loading