-
Notifications
You must be signed in to change notification settings - Fork 429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[OSS CI] Introduce periodic.yml #4348
Changes from 2 commits
0731293
35b45e9
3aaa5c1
32d51d5
75170cc
0473c8c
29da380
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: periodic | ||
|
||
on: | ||
schedule: | ||
# We have several schedules so jobs can check github.event.schedule to activate only for a fraction of the runs. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I guess you copy this schedule from PyTorch periodic. That workflow has several parts that need to be run with different schedules. ET doesn't need that here, so let's keep only one schedule. PyTorch periodic workflow originally started with every 4 hours, maybe that's a good start or it could be a longer period depending on how frequent a new commit lands in ET trunk https://hud.pytorch.org/hud/pytorch/executorch/main |
||
# Also run less frequently on weekends. | ||
- cron: 45 0,8,16 * * 1-5 | ||
- cron: 45 4 * * 0,6 | ||
- cron: 29 8 * * * # about 1:29am PDT, for mem leak check and rerun disabled tests | ||
push: | ||
tags: | ||
- ciflow/periodic/* | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You'll need to add this into https://github.com/pytorch/executorch/blob/main/.github/pytorch-probot.yml so that the bot can recognize this new tag |
||
branches: | ||
- release/* | ||
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ github.ref_type == 'branch' && github.sha }}-${{ github.event_name == 'workflow_dispatch' }}-${{ github.event_name == 'schedule' }}-${{ github.event.schedule }} | ||
cancel-in-progress: true | ||
|
||
permissions: read-all | ||
|
||
jobs: | ||
gather-models: | ||
runs-on: ubuntu-22.04 | ||
outputs: | ||
models: ${{ steps.gather-models.outputs.models }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
submodules: 'false' | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.10' | ||
- name: Extract the list of models to test | ||
id: gather-models | ||
run: | | ||
set -eux | ||
|
||
PYTHONPATH="${PWD}" python .ci/scripts/gather_test_models.py --event "${GITHUB_EVENT_NAME}" | ||
|
||
test-models-linux: | ||
name: test-models-linux | ||
uses: pytorch/test-infra/.github/workflows/linux_job.yml@main | ||
needs: gather-models | ||
strategy: | ||
matrix: ${{ fromJSON(needs.gather-models.outputs.models) }} | ||
fail-fast: false | ||
with: | ||
runner: ${{ matrix.runner }} | ||
docker-image: executorch-ubuntu-22.04-clang12 | ||
submodules: 'true' | ||
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }} | ||
timeout: ${{ matrix.timeout }} | ||
script: | | ||
# The generic Linux job chooses to use base env, not the one setup by the image | ||
CONDA_ENV=$(conda env list --json | jq -r ".envs | .[-1]") | ||
conda activate "${CONDA_ENV}" | ||
|
||
MODEL_NAME=${{ matrix.model }} | ||
BUILD_TOOL=${{ matrix.build-tool }} | ||
BACKEND=${{ matrix.backend }} | ||
DEMO_BACKEND_DELEGATION=${{ matrix.demo_backend_delegation }} | ||
|
||
PYTHON_EXECUTABLE=python bash .ci/scripts/setup-linux.sh "${BUILD_TOOL}" | ||
# Build and test ExecuTorch | ||
PYTHON_EXECUTABLE=python bash .ci/scripts/test.sh "${MODEL_NAME}" "${BUILD_TOOL}" "${BACKEND}" "${DEMO_BACKEND_DELEGATION}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You might want to add
here just to test the workflow once, then remove the
pull_request
trigger after before landing.ciflow/periodic
won't work on this PR till it's land (chicken and egg issue)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Triggering it one-off