Skip to content
Open
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
2 changes: 2 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
# Use UV's virtual environment
export VIRTUAL_ENV=.venv
layout python python3.12
dotenv_if_exists
20 changes: 9 additions & 11 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,17 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for setuptools_scm to work properly
- name: Set up Python
uses: actions/setup-python@v4

- name: Install uv
uses: astral-sh/setup-uv@v3
with:
python-version: '3.11'

- name: Install build dependencies
run: |
python -m pip install --upgrade pip
python -m pip install build

version: "latest"

- name: Set up Python
run: uv python install 3.11

- name: Build package
run: python -m build
run: uv build

- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,26 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
- name: Install uv
uses: astral-sh/setup-uv@v3
with:
python-version: ${{ matrix.python-version }}
version: "latest"

- name: Set up Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -e .[dev]
run: uv sync --extra dev

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

- name: Run linting
run: |
flake8 replicated tests examples
mypy replicated
uv run flake8 replicated tests examples
uv run mypy replicated

- name: Check formatting
run: |
black --check replicated tests examples
isort --check-only replicated tests examples
uv run black --check replicated tests examples
uv run isort --check-only replicated tests examples
1 change: 1 addition & 0 deletions .python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.12
8 changes: 8 additions & 0 deletions API_REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

## Installation

### Using uv (recommended)

```bash
uv pip install replicated
```

### Using pip

```bash
pip install replicated
```
Expand Down
Loading