Skip to content

Commit

Permalink
Use poetry instead of setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
dbrattli committed Feb 22, 2022
1 parent 2716a45 commit 05d3a8c
Show file tree
Hide file tree
Showing 13 changed files with 837 additions and 133 deletions.
33 changes: 22 additions & 11 deletions .github/workflows/pythonpackage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,44 +16,55 @@ jobs:
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
pip install -r requirements.txt
pip install poetry
poetry install
- name: Check formatting
run: |
black --check --verbose rx
isort --check rx
poetry run black --check --verbose rx
poetry run isort --check rx
- name: Check type annotations (mypy & pyright)
run: |
pyright rx
mypy rx/__init__.py rx/operators rx/core/abc rx/core/observer rx/core/observable rx/disposable rx/internal rx/subject rx/scheduler
poetry run pyright rx
poetry run mypy
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7 --show-source --statistics
poetry run flake8 . --count --select=E9,F63,F7 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
poetry run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
pytest -n auto
poetry run pytest -n auto
coverage:
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: Install dependencies
run: |
pip install -r requirements.txt
pip install poetry
poetry install
- name: Run coverage tests
run: |
coverage run -m pytest
poetry run coverage run -m pytest
- name: Coveralls
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COVERALLS_SERVICE_NAME: github
run: |
coveralls
poetry run coveralls
5 changes: 2 additions & 3 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
The MIT License
===============
# The MIT License

Copyright 2013-2019, Dag Brattli, Microsoft Corp., and Contributors.
Copyright 2013-2022, Dag Brattli, Microsoft Corp., and Contributors.

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
3 changes: 0 additions & 3 deletions MANIFEST.in

This file was deleted.

Loading

0 comments on commit 05d3a8c

Please sign in to comment.