Skip to content

Commit

Permalink
Merge branch 'develop' into dependabot/pip/transformers-4.36.0
Browse files Browse the repository at this point in the history
  • Loading branch information
mdbenito authored Apr 3, 2024
2 parents 902a258 + 49739ff commit f9a2e28
Show file tree
Hide file tree
Showing 142 changed files with 7,811 additions and 72,304 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.8.1.dev0
current_version = 0.8.2.dev0
commit = False
tag = False
allow_dirty = False
Expand Down
3 changes: 3 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
notebooks/*.ipynb -linguist-detectable
*.png filter=lfs diff=lfs merge=lfs -text
*.svg filter=lfs diff=lfs merge=lfs -text
logo.svg -filter=lfs -diff=lfs -merge=lfs text
2 changes: 1 addition & 1 deletion .github/actions/python/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ runs:
using: "composite"
steps:
- name: Set up Python ${{ inputs.python_version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ inputs.python_version }}
cache: 'pip'
Expand Down
22 changes: 15 additions & 7 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@ jobs:
name: Lint code and check type hints
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Setup Python 3.8
uses: ./.github/actions/python
with:
python_version: 3.8
- uses: actions/cache@v3
- uses: actions/cache@v4
with:
path: ~/.cache/pre-commit
key: pre-commit-${{ env.pythonLocation }}-${{ hashFiles('.pre-commit-config.yaml') }}
Expand All @@ -43,19 +43,21 @@ jobs:
run: |
MYPY_VERSION=$(mypy --version | sed 's/[^0-9.]*\([0-9.]*\).*/\1/')
echo "key=mypy-$MYPY_VERSION-${{ env.pythonLocation }}" >> $GITHUB_OUTPUT
- uses: actions/cache@v3
- uses: actions/cache@v4
with:
path: .mypy_cache
key: ${{ steps.generate-mypy-cache-key.outputs.key }}
- name: Check Type Hints
run: mypy src/

docs:
name: Build Docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
lfs: true
- name: Setup Python 3.8
uses: ./.github/actions/python
with:
Expand All @@ -66,11 +68,12 @@ jobs:
pandoc-version: ${{ env.PANDOC_VERSION }}
- name: Build Docs
run: mkdocs build

group-tests:
strategy:
fail-fast: false
matrix:
python_version: ["3.8", "3.9", "3.10"]
python_version: ["3.8", "3.9", "3.10", "3.11"]
group_number: [1, 2, 3, 4]
name: Run Tests - Python ${{ matrix.python_version }} - Group ${{ matrix.group_number }}
uses: ./.github/workflows/run-tests-workflow.yaml
Expand All @@ -79,15 +82,17 @@ jobs:
group_number: ${{ matrix.group_number }}
python_version: ${{ matrix.python_version }}
needs: [code-quality]

notebook-tests:
strategy:
matrix:
python_version: ["3.8", "3.9", "3.10"]
python_version: ["3.8", "3.9", "3.10", "3.11"]
name: Run Notebook tests - Python ${{ matrix.python_version }}
uses: ./.github/workflows/run-notebook-tests-workflow.yaml
with:
python_version: ${{ matrix.python_version }}
needs: [code-quality]

push-docs-and-release-testpypi:
name: Push Docs and maybe release Package to TestPyPI
runs-on: ubuntu-latest
Expand All @@ -96,7 +101,10 @@ jobs:
concurrency:
group: publish
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
lfs: true
- name: Setup Python 3.8
uses: ./.github/actions/python
with:
Expand Down
11 changes: 8 additions & 3 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish Python Package to PyPI
name: Publish package and docs

on:
release:
Expand Down Expand Up @@ -28,12 +28,17 @@ jobs:
steps:
- name: Checking out last commit in release
if: ${{ github.event_name != 'workflow_dispatch' }}
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
lfs: true
fetch-depth: 0
- name: Checking out last commit for tag ${{ inputs.tag_name }}
uses: actions/checkout@v3
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: actions/checkout@v4
with:
ref: ${{ inputs.tag_name }}
lfs: true
fetch-depth: 0
- name: Fail if running locally
if: ${{ env.ACT }} # skip during local actions testing
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/run-notebook-tests-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ jobs:
run-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Python ${{ inputs.python_version }}
uses: ./.github/actions/python
with:
python_version: ${{ inputs.python_version }}
- name: Cache Tox Directory for Tests
uses: actions/cache@v3
uses: actions/cache@v4
with:
key: tox-${{ runner.os }}-${{ github.ref }}-${{ hashFiles('tox.ini', 'requirements.txt') }}-${{ inputs.python_version }}
path: .tox
Expand Down
12 changes: 9 additions & 3 deletions .github/workflows/run-tests-workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,28 @@ on:
type: string
required: true


env:
PY_COLORS: 1

jobs:
run-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
with:
large-packages: false
docker-images: false
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Python ${{ inputs.python_version }}
uses: ./.github/actions/python
with:
python_version: ${{ inputs.python_version }}
- name: Cache Tox Directory for Tests
uses: actions/cache@v3
uses: actions/cache@v4
with:
key: tox-${{ runner.os }}-${{ github.ref }}-${{ hashFiles('tox.ini', 'requirements.txt') }}-${{ inputs.python_version }}
path: .tox
Expand All @@ -40,7 +46,7 @@ jobs:
- name: Test Group ${{ inputs.group_number }}
run: tox -e tests -- --slow-tests --splits ${{ inputs.split_size }} --group ${{ inputs.group_number }}
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/stale.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v6
- uses: actions/stale@v9
with:
only-labels: 'awaiting-reply'
days-before-stale: 30
Expand Down
Loading

0 comments on commit f9a2e28

Please sign in to comment.