Skip to content

Updated libraries (and the CI for python3.12) #11

Updated libraries (and the CI for python3.12)

Updated libraries (and the CI for python3.12) #11

name: Build & Tests - Words'n Fun 3.10
on:
push:
branches:
- 'main'
- 'release/v*'
paths-ignore:
- 'version.txt'
- '.github/workflows/**'
- '*.md'
- 'LICENSE'
- 'Makefile'
pull_request:
types: [opened, reopened, edit, synchronize]
branches:
- 'main'
- 'release/v*'
paths-ignore:
- 'version.txt'
- '.github/workflows/**'
- '*.md'
- 'LICENSE'
- 'Makefile'
schedule:
- cron: '0 0 * * 0'
workflow_dispatch:
jobs:
build:
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install package & dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools
python setup.py install
pip install nose==1.3.7 nose-exclude==0.5.0 coverage==5.3
pip install flake8
- name: Lint with flake8
run: |
# Stop the build if there are Python syntax errors or undefined names
flake8 words_n_fun --count --select=E9,F63,F7,F82 --show-source --statistics
# Exit-zero treats all errors as warnings.
flake8 words_n_fun --count --exit-zero --max-complexity=10 --ignore=E501,W503,E266,W605,C901 --statistics
- name: Test WNF
run: nosetests -c nose_setup_coverage.cfg tests
build-spacy:
strategy:
matrix:
python-version: ["3.7", "3.8"]
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install package & dependencies
run: |
python -m pip install --upgrade pip
pip install https://github.com/explosion/spacy-models/releases/download/fr_core_news_sm-3.3.0/fr_core_news_sm-3.3.0-py3-none-any.whl
pip install .[lemmatizer]
pip install nose==1.3.7 nose-exclude==0.5.0 coverage==5.3
pip install flake8
- name: Lint with flake8
run: |
# Stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# Exit-zero treats all errors as warnings.
flake8 . --count --exit-zero --max-complexity=10 --ignore=E501 --statistics
- name: Test WNF
run: nosetests -c nose_setup_coverage.cfg tests
build-local:
strategy:
matrix:
python-version: ["3.7", "3.8"]
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install package & dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
python setup.py develop
- name: Test WNF
run: nosetests -c nose_setup_coverage.cfg tests