diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..5ae6909d --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,35 @@ +name: Build + +on: [push, pull_request] + +jobs: + build: + name: Build + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-python@v2 + with: + python-version: '3.6' + cache: 'pip' + - run: pip install -r requirements.txt + - run: pip install -e . + - run: flake8 kuyruk/ + - run: mypy kuyruk/ + - run: cp test_config_github_actions.py /tmp/kuyruk_config.py + - uses: mer-team/rabbitmq-mng-action@v1.2 + with: + RABBITMQ_TAG: '3-management-alpine' + - run: pytest -v --cov=kuyruk --cov-report xml tests/ + - run: coverage combine + - run: coveralls --service=github + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - run: echo ${{github.ref_name}} + - run: echo ${{github.ref_name}} > VERSION + - name: Publish package + if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') + uses: pypa/gh-action-pypi-publish@release/v1 + with: + user: __token__ + password: ${{ secrets.PYPI_API_TOKEN }} diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index ee77e4f0..00000000 --- a/.travis.yml +++ /dev/null @@ -1,29 +0,0 @@ -dist: trusty -language: python -python: 3.5 -install: - - pip install -e . - - pip install -r requirements.txt -before_script: - - cp test_config_travis.py /tmp/kuyruk_config.py -script: - - flake8 kuyruk/ - - mypy kuyruk/ - - pytest -v --cov=kuyruk tests/ -after_success: - - pip install coveralls - - coverage combine - - coveralls -services: - - rabbitmq -before_deploy: - - echo "$TRAVIS_TAG" > VERSION -deploy: - on: - repo: cenkalti/kuyruk - tags: true - skip_cleanup: true - provider: pypi - user: cenkalti - password: - secure: WISXo+4rni+S51yz6YBiv+Nee8L+GEWb10chnAOkqobnk4IV8p87fyH6hlD5WwzdRUJmvnmvgLm8xni0vfGmQOAwfyCFdDMWdXubL74SRLjG0g7cKWzS8GumlgA+1m2tHDYv2fIFOjgrF7KKX3GXhFUlv8ei7RyYd8+ecLV6L/Y= diff --git a/README.rst b/README.rst index d92b28f3..99e85941 100644 --- a/README.rst +++ b/README.rst @@ -19,7 +19,7 @@ Kuyruk is a simple and easy way of distributing tasks to run on servers. It uses `RabbitMQ `_ as message broker and depends on `amqp `_ which is a pure-Python RabbitMQ client library. -Compatible with Python 3.5+. +Compatible with Python 3.6+. Where is the documentation? diff --git a/docs/index.rst b/docs/index.rst index 628cb649..fe1800da 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -14,7 +14,7 @@ Kuyruk is a simple and easy way of distributing tasks to run on servers. It uses `RabbitMQ `_ as message broker and depends on `amqp `_ which is a pure-Python RabbitMQ client library. -Compatible with Python 3.5+. +Compatible with Python 3.6+. All design decisions is based on simplicity. Speed is not first priority. Kuyruk only supports RabbitMQ and does not plan diff --git a/requirements.txt b/requirements.txt index 7a893fa2..8718a7a6 100644 --- a/requirements.txt +++ b/requirements.txt @@ -5,3 +5,5 @@ what==0.5.0 psutil==4.4.2 flake8==3.5.0 mypy==0.570 +coverage==6.1.2 +coveralls==3.3.1 diff --git a/setup.cfg b/setup.cfg index cb834c74..87a77780 100644 --- a/setup.cfg +++ b/setup.cfg @@ -7,7 +7,7 @@ max-line-length = 120 exclude = tests/*,docs/* [mypy] -python_version = 3.5 +python_version = 3.6 platform = linux incremental = True ignore_missing_imports = True diff --git a/setup.py b/setup.py index 0c277bf0..1eda1f1e 100644 --- a/setup.py +++ b/setup.py @@ -40,7 +40,6 @@ def read(*fname: str) -> str: 'License :: OSI Approved :: MIT License', 'Operating System :: OS Independent', 'Programming Language :: Python', - 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'Topic :: Software Development :: Object Brokering', 'Topic :: System :: Distributed Computing', diff --git a/test_config_travis.py b/test_config_github_actions.py similarity index 100% rename from test_config_travis.py rename to test_config_github_actions.py