[API Compatibility] migrate workflows to github actions#889
Open
Manfredss wants to merge 41 commits into
Open
Conversation
…chine can't reach baidu internal network
8228c91 to
693c398
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Docs
[CI] Add GitHub Actions CI suite + PR
/re-runactionSummary
Introduces the full GitHub Actions CI for PaConvert under
.github/workflows/plus a reusable composite action under
.github/actions/. This covers codestyle, API consistency, install/packaging, and CPU / GPU / distributed unit
tests, and adds a comment-driven workflow re-run mechanism for PRs.
Workflows added (
.github/workflows/)codestyle.ymlpre-commitubuntu-24.04)pre-commit run --all-files(pre-commit 2.17.0)consistency.ymlCommon API Consistency Checkubuntu-24.04)tools/consistency/consistency_check.py; uploads log on failureInstall_check.ymlubuntu-24.04)sdist bdist_wheel), installs it, runspaconvert -V/--run_checkUnittest_check.ymlubuntu-24.04)--lfretry; uploadspytest.logon failureUnittest_check_gpu.ymlgroup: PaConvert)Unittest_check_distribute.ymlgroup: PaConvert)run_and_compare.pyCUDA_VISIBLE_DEVICES=0,1,--nproc_per_node=2)Modeltest_check.ymlgroup: PaConvert)/workspace/torch_project, runstools/modeltest/modeltest_check.pyrerun.ymlubuntu-latest* CPU jobs currently run on
ubuntu-24.04with a# TODO: replace with the actual self-hosted CPU runner group nameplaceholder — see Follow-ups.Composite action added (
.github/actions/rerun-workflow/)action.yml— composite actionRerun workflow; inputsGITHUB_TOKEN,OWNER,REPO,PR_ID,JOB_NAME.rerun.sh— resolves the PR head SHA via the GitHub REST API and eitherre-runs all failed jobs (
rerun-failed-jobs) or a specific job by name.Comment-driven re-run
On a PR, the PR author can comment to re-trigger checks:
/re-run all-failed·codestyle·consistency·install-check·
cpu-unittest·gpu-unittest·distributed-unittest·model-test(Guarded by
github.event.comment.user.login == github.event.issue.user.login.)Design notes
pull_request+pushtomaster,develop,release/**,with
paths-ignorefor**/*.md,docs/**,LICENSE,.gitignore,.pre-commit-config.yaml.cancel-in-progress: true.permissions: contents: readeverywhere;rerun.ymladditionally gets
actions: write.--timeout/--retries;GPU torch/torchvision pulled as pinned cu118 wheels from
paddle-paconvert.bj.bcebos.com; pytest retried (--reruns=3, then--lf);failure logs/artifacts uploaded with 14-day retention.
Self-hosted runner prerequisites
PaConvertonline (it currently contains thepaddle-gpurunner).
/workspace/torch_projecton the runner.Follow-ups
self-hosted CPU runner group (replace the
ubuntu-24.04placeholders).schedulecron once the runners are validated.Test plan
gpu-unittest,distributed-unittest,modeltestare picked up by thePaConvertgroup and complete./re-run <job>comment re-triggers the targeted job(s).PR APIs