Skip to content

Commit

Permalink
Remove setup.py, use poetry github workflows.
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewkozlik committed Sep 3, 2024
1 parent fa1f8fc commit 795c4ab
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 86 deletions.
84 changes: 27 additions & 57 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
@@ -1,68 +1,38 @@
name: python-slip10

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
on: [push, pull_request]

jobs:
tests:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: ['3.9', '3.10']
os:
- ubuntu-latest
- macOS-latest
- windows-latest

runs-on: ${{ matrix.os }}
os: [ ubuntu-latest ]
python-version: ['3.8', '3.9', '3.10']
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Installation (deps and package)
run: |
python -m pip install --upgrade pip
pip install pytest
pip install -r requirements.txt -r tests/requirements.txt
python setup.py install
- name: Test with pytest
run: |
pytest -vvv
- uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: Setup python for ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: poetry install
- name: Run tests for Python-${{ matrix.python-version }} with ${{ matrix.os }}
run: poetry run pytest

linter:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Run `black` on the source code
run: |
python -m pip install --upgrade pip
pip install black
python -m black --check slip10 tests
coincurve_versions:
strategy:
matrix:
coincurve-version: [15, 16, 17]

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.10
uses: actions/setup-python@v2
with:
python-version: '3.10'
- name: Testing with Coincurve ${{ matrix.coincurve-version }}
run: |
python -m pip install --upgrade pip
pip install pytest
pip install -r requirements.txt -r tests/requirements.txt
pip install -I coincurve==${{ matrix.coincurve-version }}
python setup.py install
- uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: Setup python for ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: 3.9
- name: Install dependencies
run: poetry install --only=dev
- name: Run style check
run: poetry run make style_check
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ style_check:
black slip10/ tests/ *.py --check

style:
isort slip10/ tests/ *.py
black slip10/ tests/ *.py
isort slip10/ tests/
black slip10/ tests/


.PHONY: clean clean-build clean-pyc clean-test test style_check style
1 change: 0 additions & 1 deletion requirements.txt

This file was deleted.

26 changes: 0 additions & 26 deletions setup.py

This file was deleted.

0 comments on commit 795c4ab

Please sign in to comment.