forked from google-deepmind/meltingpot
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update workflows to use composite actions
- Loading branch information
Showing
10 changed files
with
218 additions
and
137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
name: install-examples | ||
|
||
runs: | ||
using: composite | ||
steps: | ||
- name: Install Melting Pot | ||
uses: ./.github/actions/install-meltingpot | ||
- name: Install requirements for examples | ||
shell: bash | ||
run: | | ||
pip -vvv -r examples/requirements.txt | ||
pip list |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: install-meltingpot | ||
|
||
inputs: | ||
python-version: | ||
description: Python version | ||
required: false | ||
default: '3.10' | ||
type: string | ||
|
||
runs: | ||
using: composite | ||
steps: | ||
- name: Install Python dependencies | ||
shell: bash | ||
run: | | ||
pip install --upgrade pip | ||
pip install setuptools | ||
pip -vvv install .[dev] | ||
pip list |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: pylint-examples | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-examples.yml' | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pylint-examples.yml' | ||
- '.pylintrc' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-examples.yml' | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pylint-examples.yml' | ||
- '.pylintrc' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: read-all | ||
|
||
jobs: | ||
pylint: | ||
name: Lint Melting Pot | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
steps: | ||
- name: Checkout Melting Pot | ||
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 | ||
- name: Install examples | ||
uses: ./.github/actions/install-examples | ||
- name: Run PyLint on examples | ||
run: pylint --errors-only examples |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
name: pylint-meltingpot | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pylint-meltingpot.yml' | ||
- '.pylintrc' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pylint-meltingpot.yml' | ||
- '.pylintrc' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: read-all | ||
|
||
jobs: | ||
pylint: | ||
name: Lint Melting Pot | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- name: Checkout Melting Pot | ||
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 | ||
- name: Install Melting Pot | ||
uses: ./.github/actions/install-meltingpot | ||
- name: Run PyLint on Melting Pot | ||
run: pylint --errors-only meltingpot |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: pytype-examples | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-examples.yml' | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pytype-examples.yml' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
- 'pyproject.toml' | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-examples.yml' | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pytype-examples.yml' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
- 'pyproject.toml' | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: read-all | ||
|
||
jobs: | ||
pytype: | ||
name: Typecheck Melting Pot | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- name: Checkout Melting Pot | ||
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 | ||
- name: Install examples | ||
uses: ./.github/actions/install-examples | ||
- name: Run PyType on examples | ||
run: pytype examples |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
name: pytype-meltingpot | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pytype-meltingpot.yml' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
- 'pyproject.toml' | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/actions/install-meltingpot.yml' | ||
- '.github/workflows/pytype-meltingpot.yml' | ||
- 'examples/**' | ||
- 'meltingpot/**' | ||
- 'pyproject.toml' | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | ||
cancel-in-progress: true | ||
|
||
permissions: read-all | ||
|
||
jobs: | ||
pytype: | ||
name: Typecheck Melting Pot | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- name: Checkout Melting Pot | ||
uses: actions/checkout@8f4b7f84864484a7bf31766abe9204da3cbe65b3 | ||
- name: Install Melting Pot | ||
uses: ./.github/actions/install-meltingpot | ||
- name: Run PyType on Melting Pot | ||
run: pytype meltingpot |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.