diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml new file mode 100644 index 00000000..b1a4fe7b --- /dev/null +++ b/.github/workflows/main.yaml @@ -0,0 +1,40 @@ +name: CI + +on: + push: + branches: "*" + pull_request: + branches: master + +jobs: + test: + name: ${{ matrix.CONDA_ENV }}-pytest + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + CONDA_ENV: [py37, py38, py37z] + steps: + - name: APT + run: sudo apt-get install liblzo2-dev libsnappy-dev + + - name: Checkout + uses: actions/checkout@v2 + + - name: Setup Miniconda + uses: conda-incubator/setup-miniconda@v2 + with: + auto-update-conda: true + auto-activate-base: false + activate-environment: test_env + environment-file: ci/environment-${{ matrix.CONDA_ENV }}.yml + + - name: pip-install + shell: bash -l {0} + run: | + pip install -e . --no-deps + + - name: Run Tests + shell: bash -l {0} + run: | + pytest --verbose --cov=fastparquet diff --git a/.github/workflows/pypipublish.yaml b/.github/workflows/pypipublish.yaml new file mode 100644 index 00000000..7cd5ba58 --- /dev/null +++ b/.github/workflows/pypipublish.yaml @@ -0,0 +1,26 @@ +name: Upload Python Package + +on: + release: + types: [created] + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: "3.x" + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install setuptools setuptools-scm wheel twine + - name: Build and publish + env: + TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} + TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} + run: | + python setup.py sdist bdist_wheel + twine upload dist/* diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 4fbf3d7a..00000000 --- a/.travis.yml +++ /dev/null @@ -1,27 +0,0 @@ -dist: bionic -sudo: false -language: python - -addons: - apt: - packages: - - liblzo2-dev - - libsnappy-dev - -python: - - 3.6 - - 3.7 - - 3.8 - -matrix: - include: - - python: 3.7 - env: TOXENV=alternate-zstd - -install: - - pip install tox tox-travis - -script: tox - -notifications: - email: false diff --git a/ci/environment-py37.yml b/ci/environment-py37.yml new file mode 100644 index 00000000..b82a1ff7 --- /dev/null +++ b/ci/environment-py37.yml @@ -0,0 +1,23 @@ +name: test_env +channels: + - conda-forge + - defaults +dependencies: + - python=3.7 + - brotli + - bson + - lz4 + - lzo + - snappy + - zstandard + - pytest + - numba + - cython + - pandas + - dask + - pytest-cov + - thrift + - numpy + - packaging + - six + - python-snappy diff --git a/ci/environment-py37z.yml b/ci/environment-py37z.yml new file mode 100644 index 00000000..754cfb7b --- /dev/null +++ b/ci/environment-py37z.yml @@ -0,0 +1,23 @@ +name: test_env +channels: + - conda-forge + - defaults +dependencies: + - python=3.7 + - brotli + - bson + - lz4 + - lzo + - snappy + - zstd + - pytest + - numba + - cython + - pandas + - dask + - pytest-cov + - thrift + - numpy + - packaging + - six + - python-snappy diff --git a/ci/environment-py38.yml b/ci/environment-py38.yml new file mode 100644 index 00000000..02d9bdeb --- /dev/null +++ b/ci/environment-py38.yml @@ -0,0 +1,23 @@ +name: test_env +channels: + - conda-forge + - defaults +dependencies: + - python=3.8 + - brotli + - bson + - lz4 + - lzo + - snappy + - zstandard + - pytest + - numba + - cython + - pandas + - dask + - pytest-cov + - thrift + - numpy + - packaging + - six + - python-snappy diff --git a/tox.ini b/tox.ini deleted file mode 100644 index 779c25ee..00000000 --- a/tox.ini +++ /dev/null @@ -1,22 +0,0 @@ -[tox] -envlist = py36, py37, py38, alternate-zstd -usedevelop = true -skip_missing_interpreters = true - -[toxenv] -deps = - -e {toxinidir}[brotli,bson,lz4,lzo,snappy,zstandard] - pytest -passenv = * -commands = pytest {posargs:fastparquet/test} - -[testenv:alternate-zstd] -basepython = python3.7 -deps = - -e {toxinidir}[brotli,bson,lz4,lzo,snappy,zstd] - pytest -commands = pytest {posargs:fastparquet/test} - -[pytest] -addopts = -vv -filterwarnings = always::DeprecationWarning