From 8c84deac40efc6391c3d5d1d17c82cba5f02b319 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 11:13:19 -0700 Subject: [PATCH 01/26] test workflow run --- .../build-test-linux-aarch64-jetpack.yml | 5 +- .github/workflows/build-test-linux-x86_64.yml | 652 +++++++++--------- 2 files changed, 329 insertions(+), 328 deletions(-) diff --git a/.github/workflows/build-test-linux-aarch64-jetpack.yml b/.github/workflows/build-test-linux-aarch64-jetpack.yml index 29b6fea881..8dac98f731 100644 --- a/.github/workflows/build-test-linux-aarch64-jetpack.yml +++ b/.github/workflows/build-test-linux-aarch64-jetpack.yml @@ -19,7 +19,7 @@ on: jobs: generate-matrix: - if: ${{ github.event.workflow_run.conclusion == 'success' }} + #if: ${{ github.event.workflow_run.conclusion == 'success' }} uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main with: package-type: wheel @@ -46,7 +46,8 @@ jobs: env: LIMIT_PR_BUILDS: ${{ github.event_name == 'pull_request' && !contains(github.event.pull_request.labels.*.name, 'ciflow/binaries/all') }} run: | - set -eou pipefail + set -x + echo '${{ github.event.workflow_run.conclusion }}' echo "LIMIT_PR_BUILDS=${LIMIT_PR_BUILDS}" echo '${{ github.event_name }}' echo '${{ github.event.ref}}' diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index b04dce73a2..1a6048bcb3 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -45,349 +45,349 @@ jobs: echo "${MATRIX_BLOB}" echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" - build: - needs: filter-matrix - permissions: - id-token: write - contents: read - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - pre-script: packaging/pre_build_script.sh - env-var-script: packaging/env_vars.txt - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - package-name: torch_tensorrt - name: Build torch-tensorrt whl package - uses: pytorch/test-infra/.github/workflows/build_wheels_linux.yml@main - with: - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - env-var-script: ${{ matrix.env-var-script }} - post-script: ${{ matrix.post-script }} - package-name: ${{ matrix.package-name }} - smoke-test-script: ${{ matrix.smoke-test-script }} - trigger-event: ${{ github.event_name }} + # build: + # needs: filter-matrix + # permissions: + # id-token: write + # contents: read + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # pre-script: packaging/pre_build_script.sh + # env-var-script: packaging/env_vars.txt + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # package-name: torch_tensorrt + # name: Build torch-tensorrt whl package + # uses: pytorch/test-infra/.github/workflows/build_wheels_linux.yml@main + # with: + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # env-var-script: ${{ matrix.env-var-script }} + # post-script: ${{ matrix.post-script }} + # package-name: ${{ matrix.package-name }} + # smoke-test-script: ${{ matrix.smoke-test-script }} + # trigger-event: ${{ github.event_name }} - tests-py-fail-fast: - name: Test fail fast [Python] - needs: [filter-matrix, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-critical-fail-fast - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH - pushd . - python -m pip install -r tests/py/requirements.txt - cov_param="--cov=torch_tensorrt --cov-report= --cov-config=pyproject.toml" + # tests-py-fail-fast: + # name: Test fail fast [Python] + # needs: [filter-matrix, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-critical-fail-fast + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH + # pushd . + # python -m pip install -r tests/py/requirements.txt + # cov_param="--cov=torch_tensorrt --cov-report= --cov-config=pyproject.toml" - # test dynamo backend - python -m pytest -m critical ${cov_param} -n 4 tests/py/dynamo/backend/ + # # test dynamo backend + # python -m pytest -m critical ${cov_param} -n 4 tests/py/dynamo/backend/ - # test dynamo models - python -m pytest -m critical ${cov_param} -ra --cov-append --ir dynamo tests/py/dynamo/models/ + # # test dynamo models + # python -m pytest -m critical ${cov_param} -ra --cov-append --ir dynamo tests/py/dynamo/models/ - # test dynamo automatic plugin - python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/automatic_plugin/ + # # test dynamo automatic plugin + # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/automatic_plugin/ - # test dynamo partitioning - python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/partitioning/ + # # test dynamo partitioning + # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/partitioning/ - # test dynamo lowering - python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/lowering/ + # # test dynamo lowering + # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/lowering/ - # test dynamo runtime - python -m pytest ${cov_param} --cov-append tests/py/dynamo/runtime/test_000_* - python -m pytest -m critical ${cov_param} --cov-append --ignore tests/py/dynamo/runtime/test_000_* tests/py/dynamo/runtime/ + # # test dynamo runtime + # python -m pytest ${cov_param} --cov-append tests/py/dynamo/runtime/test_000_* + # python -m pytest -m critical ${cov_param} --cov-append --ignore tests/py/dynamo/runtime/test_000_* tests/py/dynamo/runtime/ - # test core - python -m pytest -m critical ${cov_param} --cov-append tests/py/core/ + # # test core + # python -m pytest -m critical ${cov_param} --cov-append tests/py/core/ - coverage report --fail-under=20 + # coverage report --fail-under=20 - tests-py-torchscript-fe: - name: Test torchscript frontend [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-torchscript-fe - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH - pushd . - cd tests/modules - python hub.py - popd - pushd . - cd tests/py/ts - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ - popd + # tests-py-torchscript-fe: + # name: Test torchscript frontend [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-torchscript-fe + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH + # pushd . + # cd tests/modules + # python hub.py + # popd + # pushd . + # cd tests/py/ts + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ + # popd - tests-py-dynamo-converters: - name: Test dynamo converters [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-dynamo-converters - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin_with_attrs.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_flashinfer_rmsnorm.py - popd + # tests-py-dynamo-converters: + # name: Test dynamo converters [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-dynamo-converters + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin_with_attrs.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_flashinfer_rmsnorm.py + # popd - tests-py-dynamo-fe: - name: Test dynamo frontend [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-dynamo-fe - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ - popd + # tests-py-dynamo-fe: + # name: Test dynamo frontend [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-dynamo-fe + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ + # popd - tests-py-dynamo-serde: - name: Test dynamo export serde [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-dynamo-serde - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py - popd + # tests-py-dynamo-serde: + # name: Test dynamo export serde [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-dynamo-serde + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py + # popd - tests-py-torch-compile-be: - name: Test torch compile backend [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-torch-compile-be - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py - popd + # tests-py-torch-compile-be: + # name: Test torch compile backend [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-torch-compile-be + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py + # popd - tests-py-dynamo-core: - name: Test dynamo core [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-dynamo-core - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ - popd + # tests-py-dynamo-core: + # name: Test dynamo core [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-dynamo-core + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ + # popd - tests-py-dynamo-cudagraphs: - name: Test dynamo cudagraphs [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-dynamo-cudagraphs - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - nvidia-smi - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py || true - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py || true - popd + # tests-py-dynamo-cudagraphs: + # name: Test dynamo cudagraphs [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-dynamo-cudagraphs + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # nvidia-smi + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py || true + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py || true + # popd - tests-py-core: - name: Test core [Python] - needs: [filter-matrix, build, tests-py-fail-fast] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - pre-script: packaging/pre_build_script.sh - post-script: packaging/post_build_script.sh - smoke-test-script: packaging/smoke_test_script.sh - uses: ./.github/workflows/linux-test.yml - with: - job-name: tests-py-core - repository: "pytorch/tensorrt" - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - pre-script: ${{ matrix.pre-script }} - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py/core - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . - popd + # tests-py-core: + # name: Test core [Python] + # needs: [filter-matrix, build, tests-py-fail-fast] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # pre-script: packaging/pre_build_script.sh + # post-script: packaging/post_build_script.sh + # smoke-test-script: packaging/smoke_test_script.sh + # uses: ./.github/workflows/linux-test.yml + # with: + # job-name: tests-py-core + # repository: "pytorch/tensorrt" + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + # pre-script: ${{ matrix.pre-script }} + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py/core + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . + # popd concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} From ed7316babb3a2f75633a3186671c8ce1fc14608a Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 11:47:27 -0700 Subject: [PATCH 02/26] add test all workflow --- .github/workflows/build-test-all.yml | 54 +++ .github/workflows/build-test-linux-x86_64.yml | 2 +- .github/workflows/build-test-windows.yml | 450 +++++++++--------- 3 files changed, 280 insertions(+), 226 deletions(-) create mode 100644 .github/workflows/build-test-all.yml diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml new file mode 100644 index 0000000000..938c110ad3 --- /dev/null +++ b/.github/workflows/build-test-all.yml @@ -0,0 +1,54 @@ +name: Lan test workflow main + +on: + pull_request: + push: + branches: + - main + - nightly + - release/* + tags: + # NOTE: Binary build pipelines should only get triggered on release candidate builds + # Release candidate tags look like: v1.11.0-rc1 + - v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+ + workflow_dispatch: + +jobs: + generate-matrix: + uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main + with: + package-type: wheel + os: linux + test-infra-repository: pytorch/test-infra + test-infra-ref: main + with-rocm: false + with-cpu: false + + filter-matrix: + needs: [generate-matrix] + outputs: + matrix: ${{ steps.generate.outputs.matrix }} + runs-on: ubuntu-latest + steps: + - uses: actions/setup-python@v5 + with: + python-version: '3.11' + - uses: actions/checkout@v4 + with: + repository: pytorch/tensorrt + - name: Generate matrix + id: generate + run: | + set -eou pipefail + MATRIX_BLOB=${{ toJSON(needs.generate-matrix.outputs.matrix) }} + MATRIX_BLOB="$(python3 .github/scripts/filter-matrix.py --matrix "${MATRIX_BLOB}")" + echo "${MATRIX_BLOB}" + echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" + + trigger-linux-test: + needs: [filter-matrix] + uses: ./.github/workflows/build-test-linux-x86_64.yml + + trigger-windows-test: + needs: [filter-matrix] + uses: ./.github/workflows/build-test-windows.yml diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 1a6048bcb3..54caad68a9 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -1,4 +1,4 @@ -name: Build and test Linux x86_64 wheels +name: Lan test workflow x86_64 wheels on: pull_request: diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index b7cb143a50..1000417514 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -1,4 +1,4 @@ -name: Build and test Windows wheels +name: Lan test Windows wheels on: #pull_request: @@ -90,237 +90,237 @@ jobs: trigger-event: ${{ github.event_name }} timeout: 120 - tests-py-torchscript-fe: - name: Test torchscript frontend [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-torchscript-fe - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/modules - python hub.py - popd - pushd . - cd tests/py/ts - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ - popd + # tests-py-torchscript-fe: + # name: Test torchscript frontend [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-torchscript-fe + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/modules + # python hub.py + # popd + # pushd . + # cd tests/py/ts + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ + # popd - tests-py-dynamo-converters: - name: Test dynamo converters [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-dynamo-converters - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ - popd + # tests-py-dynamo-converters: + # name: Test dynamo converters [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-dynamo-converters + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ + # popd - tests-py-dynamo-fe: - name: Test dynamo frontend [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-dynamo-fe - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ - popd + # tests-py-dynamo-fe: + # name: Test dynamo frontend [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-dynamo-fe + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ + # popd - tests-py-dynamo-serde: - name: Test dynamo export serde [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-dynamo-serde - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py - popd + # tests-py-dynamo-serde: + # name: Test dynamo export serde [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-dynamo-serde + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py + # popd - tests-py-torch-compile-be: - name: Test torch compile backend [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-torch-compile-be - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py - popd + # tests-py-torch-compile-be: + # name: Test torch compile backend [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-torch-compile-be + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py + # popd - tests-py-dynamo-core: - name: Test dynamo core [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-dynamo-core - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ - popd + # tests-py-dynamo-core: + # name: Test dynamo core [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-dynamo-core + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ + # popd - tests-py-dynamo-cudagraphs: - name: Test dynamo cudagraphs [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-dynamo-cudagraphs - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py - python -m pip install -r requirements.txt - cd dynamo - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py - python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py - popd + # tests-py-dynamo-cudagraphs: + # name: Test dynamo cudagraphs [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-dynamo-cudagraphs + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py + # popd - tests-py-core: - name: Test core [Python] - needs: [substitute-runner, build] - strategy: - fail-fast: false - matrix: - include: - - repository: pytorch/tensorrt - package-name: torch_tensorrt - uses: ./.github/workflows/windows-test.yml - with: - job-name: tests-py-core - repository: ${{ matrix.repository }} - ref: "" - test-infra-repository: pytorch/test-infra - test-infra-ref: main - build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - pre-script: packaging/driver_upgrade.bat - script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - pushd . - cd tests/py/core - python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . - popd + # tests-py-core: + # name: Test core [Python] + # needs: [substitute-runner, build] + # strategy: + # fail-fast: false + # matrix: + # include: + # - repository: pytorch/tensorrt + # package-name: torch_tensorrt + # uses: ./.github/workflows/windows-test.yml + # with: + # job-name: tests-py-core + # repository: ${{ matrix.repository }} + # ref: "" + # test-infra-repository: pytorch/test-infra + # test-infra-ref: main + # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + # pre-script: packaging/driver_upgrade.bat + # script: | + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py/core + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . + # popd concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} From f1a6f1f0deb686b36d5e57b49aa327d8a588ba69 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 13:58:40 -0700 Subject: [PATCH 03/26] test --- .github/workflows/build-test-linux-x86_64.yml | 3 ++- .github/workflows/build-test-windows.yml | 5 +---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 54caad68a9..bade277723 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -1,7 +1,8 @@ name: Lan test workflow x86_64 wheels on: - pull_request: + #pull_request: + workflow_call: push: branches: - main diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 1000417514..cfd207eaf6 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -2,10 +2,7 @@ name: Lan test Windows wheels on: #pull_request: - workflow_run: - workflows: ["Build and test Linux x86_64 wheels"] - types: - - completed + workflow_call: push: branches: - main From 89b75d9bac606f931f3e9eb08d70833df5711bf3 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:05:42 -0700 Subject: [PATCH 04/26] test --- .github/workflows/build-test-all.yml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 938c110ad3..3c1ca32335 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -13,6 +13,11 @@ on: - v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+ workflow_dispatch: +permissions: + id-token: write + contents: read + packages: write + jobs: generate-matrix: uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main @@ -47,8 +52,16 @@ jobs: trigger-linux-test: needs: [filter-matrix] + permissions: + id-token: write + contents: read + packages: write uses: ./.github/workflows/build-test-linux-x86_64.yml trigger-windows-test: needs: [filter-matrix] + permissions: + id-token: write + contents: read + packages: write uses: ./.github/workflows/build-test-windows.yml From f609ebba8c44d7980ea0c9b20be92310c53c0792 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:12:44 -0700 Subject: [PATCH 05/26] test --- .github/workflows/build-test-all.yml | 12 ++++++++++++ .github/workflows/build-test-windows.yml | 1 + 2 files changed, 13 insertions(+) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 3c1ca32335..0ccbbd8b19 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -65,3 +65,15 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-windows.yml + + wait-all-jobs: + needs: [trigger-linux-test, trigger-windows-test] + runs-on: ubuntu-latest + steps: + - name: Wait for all jobs to complete + run: | + echo "Waiting for all jobs to complete..." + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + cancel-in-progress: true \ No newline at end of file diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index cfd207eaf6..ab4651aa4a 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -3,6 +3,7 @@ name: Lan test Windows wheels on: #pull_request: workflow_call: + inputs: push: branches: - main From 37d22da78d0d4b3584acf40260e60960d4abc1a4 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:14:29 -0700 Subject: [PATCH 06/26] test --- .github/workflows/build-test-windows.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index ab4651aa4a..cfd207eaf6 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -3,7 +3,6 @@ name: Lan test Windows wheels on: #pull_request: workflow_call: - inputs: push: branches: - main From 05b67cbaee576956a730b37b65a868f5f7c505e2 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:19:44 -0700 Subject: [PATCH 07/26] test --- .github/workflows/build-test-linux-x86_64.yml | 2 +- .github/workflows/build-test-windows.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index bade277723..fdf03215b2 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -391,5 +391,5 @@ jobs: # popd concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + group: ${{ github.workflow }}-linux-x86_64-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} cancel-in-progress: true diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index cfd207eaf6..cb7c23eb08 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -320,5 +320,5 @@ jobs: # popd concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + group: ${{ github.workflow }}-windows-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} cancel-in-progress: true From 12ecf4735f5e6f70ce2d165eb5c19c777efc675a Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:27:54 -0700 Subject: [PATCH 08/26] test --- .github/workflows/build-test-all.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 0ccbbd8b19..01deb28420 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -52,6 +52,7 @@ jobs: trigger-linux-test: needs: [filter-matrix] + if: always() permissions: id-token: write contents: read @@ -60,6 +61,7 @@ jobs: trigger-windows-test: needs: [filter-matrix] + if: always() permissions: id-token: write contents: read From 180606a35fa9d95184991c448097156fe783bad6 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:34:03 -0700 Subject: [PATCH 09/26] test --- .github/workflows/build-test-all.yml | 2 +- .github/workflows/build-test-linux-x86_64.yml | 2 +- .github/workflows/build-test-windows.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 01deb28420..8c1c6d5f3d 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -78,4 +78,4 @@ jobs: concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} - cancel-in-progress: true \ No newline at end of file + cancel-in-progress: false \ No newline at end of file diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index fdf03215b2..bfa2d06aee 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -392,4 +392,4 @@ jobs: concurrency: group: ${{ github.workflow }}-linux-x86_64-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} - cancel-in-progress: true + cancel-in-progress: false diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index cb7c23eb08..551da73505 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -321,4 +321,4 @@ jobs: concurrency: group: ${{ github.workflow }}-windows-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} - cancel-in-progress: true + cancel-in-progress: false From 3312d4b62fa173088f9e039d94e85f8a79eca8d7 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:34:28 -0700 Subject: [PATCH 10/26] test --- .github/workflows/test_a.yml | 32 ++++++++++++++++++++++++++++++++ .github/workflows/test_b.yml | 16 ++++++++++++++++ .github/workflows/test_c.yml | 16 ++++++++++++++++ 3 files changed, 64 insertions(+) create mode 100644 .github/workflows/test_a.yml create mode 100644 .github/workflows/test_b.yml create mode 100644 .github/workflows/test_c.yml diff --git a/.github/workflows/test_a.yml b/.github/workflows/test_a.yml new file mode 100644 index 0000000000..3923d10a0c --- /dev/null +++ b/.github/workflows/test_a.yml @@ -0,0 +1,32 @@ +name: Lan test a + +on: + pull_request: + +jobs: + pre-test: + runs-on: ubuntu-latest + steps: + - name: Pre-test + run: | + echo "Pre-test" + echo "${{ github.workflow }}-a-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }}" + + call-b: + uses: ./.github/workflows/workflow-b.yml + + call-c: + uses: ./.github/workflows/workflow-c.yml + + wait-all-jobs: + needs: [call-b, call-c] + runs-on: ubuntu-latest + steps: + - name: Wait for all jobs to complete + run: | + echo "Waiting for all jobs to complete..." + +concurrency: + group: ${{ github.workflow }}-a-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + cancel-in-progress: true + diff --git a/.github/workflows/test_b.yml b/.github/workflows/test_b.yml new file mode 100644 index 0000000000..933da1174c --- /dev/null +++ b/.github/workflows/test_b.yml @@ -0,0 +1,16 @@ +name: Lan test b + +on: + workflow_call: + +jobs: + test-b: + runs-on: ubuntu-latest + steps: + - name: Test b + run: | + echo "Test b" + +concurrency: + group: ${{ github.workflow }}-b-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + cancel-in-progress: true \ No newline at end of file diff --git a/.github/workflows/test_c.yml b/.github/workflows/test_c.yml new file mode 100644 index 0000000000..d9d2286f9c --- /dev/null +++ b/.github/workflows/test_c.yml @@ -0,0 +1,16 @@ +name: Lan test c + +on: + workflow_call: + +jobs: + test-b: + runs-on: ubuntu-latest + steps: + - name: Test c + run: | + echo "Test c" + +concurrency: + group: ${{ github.workflow }}-c-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + cancel-in-progress: true From 341b4d9420ad59d54f5c6385eab008524c4aecda Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 14:36:02 -0700 Subject: [PATCH 11/26] test --- .github/workflows/test_a.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_a.yml b/.github/workflows/test_a.yml index 3923d10a0c..54082ff3d8 100644 --- a/.github/workflows/test_a.yml +++ b/.github/workflows/test_a.yml @@ -13,10 +13,10 @@ jobs: echo "${{ github.workflow }}-a-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }}" call-b: - uses: ./.github/workflows/workflow-b.yml + uses: ./.github/workflows/test_b.yml call-c: - uses: ./.github/workflows/workflow-c.yml + uses: ./.github/workflows/test_c.yml wait-all-jobs: needs: [call-b, call-c] From c643ff7d0b84369b36e91b5aec25cef301a427f8 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 15:54:33 -0700 Subject: [PATCH 12/26] test --- .github/workflows/build-test-all.yml | 19 +++++++++++++++++-- .github/workflows/test_a.yml | 10 ++++++---- .github/workflows/test_b.yml | 4 ++-- .github/workflows/test_c.yml | 4 ++-- 4 files changed, 27 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 8c1c6d5f3d..e65995e61e 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -50,9 +50,23 @@ jobs: echo "${MATRIX_BLOB}" echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" - trigger-linux-test: + fail-fast-test: needs: [filter-matrix] if: always() + permissions: + id-token: write + contents: read + packages: write + runs-on: ubuntu-latest + steps: + - name: Fail fast test + run: | + echo "Fail fast test" + + trigger-linux-test: + needs: [fail-fast-test] + if: always() + name: build-test on linux-x86_64 permissions: id-token: write contents: read @@ -60,8 +74,9 @@ jobs: uses: ./.github/workflows/build-test-linux-x86_64.yml trigger-windows-test: - needs: [filter-matrix] + needs: [fail-fast-test] if: always() + name: build-test on windows permissions: id-token: write contents: read diff --git a/.github/workflows/test_a.yml b/.github/workflows/test_a.yml index 54082ff3d8..9488a501c8 100644 --- a/.github/workflows/test_a.yml +++ b/.github/workflows/test_a.yml @@ -12,19 +12,21 @@ jobs: echo "Pre-test" echo "${{ github.workflow }}-a-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }}" - call-b: + call-linux-x86_64: + needs: pre-test uses: ./.github/workflows/test_b.yml - call-c: + call-windows: + needs: pre-test uses: ./.github/workflows/test_c.yml wait-all-jobs: - needs: [call-b, call-c] + needs: [call-linux-x86_64, call-windows] runs-on: ubuntu-latest steps: - name: Wait for all jobs to complete run: | - echo "Waiting for all jobs to complete..." + echo "Waiting for all jobs to complete... ${{ github.workflow }} " concurrency: group: ${{ github.workflow }}-a-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} diff --git a/.github/workflows/test_b.yml b/.github/workflows/test_b.yml index 933da1174c..263665819c 100644 --- a/.github/workflows/test_b.yml +++ b/.github/workflows/test_b.yml @@ -4,12 +4,12 @@ on: workflow_call: jobs: - test-b: + test: runs-on: ubuntu-latest steps: - name: Test b run: | - echo "Test b" + echo "Test b ${github.workflow}" concurrency: group: ${{ github.workflow }}-b-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} diff --git a/.github/workflows/test_c.yml b/.github/workflows/test_c.yml index d9d2286f9c..c0d4d3ab01 100644 --- a/.github/workflows/test_c.yml +++ b/.github/workflows/test_c.yml @@ -4,12 +4,12 @@ on: workflow_call: jobs: - test-b: + test: runs-on: ubuntu-latest steps: - name: Test c run: | - echo "Test c" + echo "Test c ${github.workflow} " concurrency: group: ${{ github.workflow }}-c-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} From 703faf3d5d04eb4fe538fc530c8362d04f863d8f Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:04:20 -0700 Subject: [PATCH 13/26] test --- .github/workflows/test_b.yml | 2 +- .github/workflows/test_c.yml | 2 +- .github/workflows/test_d.yml | 20 ++++++++++++++++++++ 3 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/test_d.yml diff --git a/.github/workflows/test_b.yml b/.github/workflows/test_b.yml index 263665819c..b0e6b89299 100644 --- a/.github/workflows/test_b.yml +++ b/.github/workflows/test_b.yml @@ -9,7 +9,7 @@ jobs: steps: - name: Test b run: | - echo "Test b ${github.workflow}" + echo "Test b ${{ github.workflow }}" concurrency: group: ${{ github.workflow }}-b-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} diff --git a/.github/workflows/test_c.yml b/.github/workflows/test_c.yml index c0d4d3ab01..24b4590402 100644 --- a/.github/workflows/test_c.yml +++ b/.github/workflows/test_c.yml @@ -9,7 +9,7 @@ jobs: steps: - name: Test c run: | - echo "Test c ${github.workflow} " + echo "Test c ${{ github.workflow }} " concurrency: group: ${{ github.workflow }}-c-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} diff --git a/.github/workflows/test_d.yml b/.github/workflows/test_d.yml new file mode 100644 index 0000000000..ddb2e5137a --- /dev/null +++ b/.github/workflows/test_d.yml @@ -0,0 +1,20 @@ +name: Lan test d + +on: + workflow_run: + workflows: ["Lan test a"] + types: + - completed + +jobs: + test: + runs-on: ubuntu-latest + steps: + - name: Test c + run: | + echo "Test c ${{ github.workflow }} " + echo "Test a github.event.workflow_run.conclusion ${{ github.event.workflow_run.conclusion }}" + +concurrency: + group: ${{ github.workflow }}-c-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + cancel-in-progress: true From b88313d30f06d00aacd2d76100833bb6a60ab9a1 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:13:15 -0700 Subject: [PATCH 14/26] test --- .github/workflows/build-test-windows.yml | 16 +++++++++------- .github/workflows/test_c.yml | 5 +++++ 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 551da73505..203dfffed1 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -15,7 +15,8 @@ on: workflow_dispatch: jobs: - generate-matrix: + generate-windows-matrix: + name: generate-windows-matrix if: ${{ github.event.workflow_run.conclusion == 'success' }} uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main with: @@ -26,8 +27,9 @@ jobs: with-rocm: false with-cpu: false - filter-matrix: - needs: [generate-matrix] + filter-windows-matrix: + name: filter-windows-matrix + needs: [generate-windows-matrix] outputs: matrix: ${{ steps.generate.outputs.matrix }} runs-on: ubuntu-latest @@ -42,13 +44,13 @@ jobs: id: generate run: | set -eou pipefail - MATRIX_BLOB=${{ toJSON(needs.generate-matrix.outputs.matrix) }} + MATRIX_BLOB=${{ toJSON(needs.generate-windows-matrix.outputs.matrix) }} MATRIX_BLOB="$(python3 .github/scripts/filter-matrix.py --matrix "${MATRIX_BLOB}")" echo "${MATRIX_BLOB}" echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" substitute-runner: - needs: filter-matrix + needs: filter-windows-matrix outputs: matrix: ${{ steps.substitute.outputs.matrix }} runs-on: ubuntu-latest @@ -58,7 +60,7 @@ jobs: run: | echo matrix="$(echo '${{ needs.filter-matrix.outputs.matrix }}' | sed -e 's/windows.g4dn.xlarge/windows.g5.4xlarge.nvidia.gpu/g')" >> ${GITHUB_OUTPUT} - build: + build-windows: needs: substitute-runner permissions: id-token: write @@ -321,4 +323,4 @@ jobs: concurrency: group: ${{ github.workflow }}-windows-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} - cancel-in-progress: false + cancel-in-progress: true diff --git a/.github/workflows/test_c.yml b/.github/workflows/test_c.yml index 24b4590402..b0773d53c7 100644 --- a/.github/workflows/test_c.yml +++ b/.github/workflows/test_c.yml @@ -2,6 +2,11 @@ name: Lan test c on: workflow_call: + inputs: + job-name: + required: true + type: string + default: "test-c" jobs: test: From d225d93451491539fcdd7cc68039f02b2bf3fa1d Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:20:40 -0700 Subject: [PATCH 15/26] test --- .github/workflows/test_c.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test_c.yml b/.github/workflows/test_c.yml index b0773d53c7..27998b2ebf 100644 --- a/.github/workflows/test_c.yml +++ b/.github/workflows/test_c.yml @@ -4,7 +4,7 @@ on: workflow_call: inputs: job-name: - required: true + required: false type: string default: "test-c" From 75d51b93126daf7d650f7c230979e3fe350826c2 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:26:46 -0700 Subject: [PATCH 16/26] test --- .github/workflows/build-test-all.yml | 4 ++++ .github/workflows/build-test-linux-x86_64.yml | 13 +++++++++---- .github/workflows/build-test-windows.yml | 1 + 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index e65995e61e..2e12885af8 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -72,6 +72,8 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-linux-x86_64.yml + with: + job-name: build-test-all-linux-x86_64 trigger-windows-test: needs: [fail-fast-test] @@ -82,6 +84,8 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-windows.yml + with: + job-name: build-test-all-windows wait-all-jobs: needs: [trigger-linux-test, trigger-windows-test] diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index bfa2d06aee..50e0553efd 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -3,6 +3,10 @@ name: Lan test workflow x86_64 wheels on: #pull_request: workflow_call: + inputs: + job-name: + required: true + default: "build-test-linux-x86_64" push: branches: - main @@ -15,7 +19,7 @@ on: workflow_dispatch: jobs: - generate-matrix: + generate-linux-x86_64-matrix: uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main with: package-type: wheel @@ -25,8 +29,8 @@ jobs: with-rocm: false with-cpu: false - filter-matrix: - needs: [generate-matrix] + filter-linux-x86_64-matrix: + needs: [generate-linux-x86_64-matrix] outputs: matrix: ${{ steps.generate.outputs.matrix }} runs-on: ubuntu-latest @@ -41,9 +45,10 @@ jobs: id: generate run: | set -eou pipefail - MATRIX_BLOB=${{ toJSON(needs.generate-matrix.outputs.matrix) }} + MATRIX_BLOB=${{ toJSON(needs.generate-linux-x86_64-matrix.outputs.matrix) }} MATRIX_BLOB="$(python3 .github/scripts/filter-matrix.py --matrix "${MATRIX_BLOB}")" echo "${MATRIX_BLOB}" + echo "${{ github.workflow }}-linux-x86_64-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }}" echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" # build: diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 203dfffed1..b13d90577b 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -44,6 +44,7 @@ jobs: id: generate run: | set -eou pipefail + echo "${{ github.workflow }}-windows-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }}" MATRIX_BLOB=${{ toJSON(needs.generate-windows-matrix.outputs.matrix) }} MATRIX_BLOB="$(python3 .github/scripts/filter-matrix.py --matrix "${MATRIX_BLOB}")" echo "${MATRIX_BLOB}" From 5d2ac80373a6df257317426038bc04dcb0623757 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:31:42 -0700 Subject: [PATCH 17/26] test --- .github/workflows/build-test-linux-x86_64.yml | 1 + .github/workflows/build-test-windows.yml | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 50e0553efd..5e050913e2 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -6,6 +6,7 @@ on: inputs: job-name: required: true + type: string default: "build-test-linux-x86_64" push: branches: diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index b13d90577b..e1244bd7ea 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -3,6 +3,11 @@ name: Lan test Windows wheels on: #pull_request: workflow_call: + inputs: + job-name: + required: true + type: string + default: "build-test-windows" push: branches: - main From c7e8385305543e5487afb12ca2bb36f7f4b9a93b Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:33:49 -0700 Subject: [PATCH 18/26] test --- .github/workflows/build-test-windows.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index e1244bd7ea..4ce27b5706 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -22,7 +22,6 @@ on: jobs: generate-windows-matrix: name: generate-windows-matrix - if: ${{ github.event.workflow_run.conclusion == 'success' }} uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main with: package-type: wheel From 47ec2a8190d3fc0dd65f0d7204a5128fa39cc3b2 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:42:27 -0700 Subject: [PATCH 19/26] test --- .github/workflows/build-test-all.yml | 10 +-- .github/workflows/build-test-linux-x86_64.yml | 63 +++++++++---------- .github/workflows/build-test-windows.yml | 7 +-- 3 files changed, 36 insertions(+), 44 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 2e12885af8..7565ccf198 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -65,6 +65,8 @@ jobs: trigger-linux-test: needs: [fail-fast-test] + strategy: + fail-fast: false if: always() name: build-test on linux-x86_64 permissions: @@ -72,11 +74,11 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-linux-x86_64.yml - with: - job-name: build-test-all-linux-x86_64 trigger-windows-test: needs: [fail-fast-test] + strategy: + fail-fast: false if: always() name: build-test on windows permissions: @@ -84,12 +86,12 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-windows.yml - with: - job-name: build-test-all-windows wait-all-jobs: needs: [trigger-linux-test, trigger-windows-test] runs-on: ubuntu-latest + strategy: + fail-fast: false steps: - name: Wait for all jobs to complete run: | diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 5e050913e2..871a3b89f8 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -3,11 +3,6 @@ name: Lan test workflow x86_64 wheels on: #pull_request: workflow_call: - inputs: - job-name: - required: true - type: string - default: "build-test-linux-x86_64" push: branches: - main @@ -52,35 +47,35 @@ jobs: echo "${{ github.workflow }}-linux-x86_64-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }}" echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" - # build: - # needs: filter-matrix - # permissions: - # id-token: write - # contents: read - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # pre-script: packaging/pre_build_script.sh - # env-var-script: packaging/env_vars.txt - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # package-name: torch_tensorrt - # name: Build torch-tensorrt whl package - # uses: pytorch/test-infra/.github/workflows/build_wheels_linux.yml@main - # with: - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # env-var-script: ${{ matrix.env-var-script }} - # post-script: ${{ matrix.post-script }} - # package-name: ${{ matrix.package-name }} - # smoke-test-script: ${{ matrix.smoke-test-script }} - # trigger-event: ${{ github.event_name }} + build: + needs: filter-matrix + permissions: + id-token: write + contents: read + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + pre-script: packaging/pre_build_script.sh + env-var-script: packaging/env_vars.txt + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + package-name: torch_tensorrt + name: Build torch-tensorrt whl package + uses: pytorch/test-infra/.github/workflows/build_wheels_linux.yml@main + with: + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + env-var-script: ${{ matrix.env-var-script }} + post-script: ${{ matrix.post-script }} + package-name: ${{ matrix.package-name }} + smoke-test-script: ${{ matrix.smoke-test-script }} + trigger-event: ${{ github.event_name }} # tests-py-fail-fast: # name: Test fail fast [Python] diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 4ce27b5706..6b8e520057 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -3,11 +3,6 @@ name: Lan test Windows wheels on: #pull_request: workflow_call: - inputs: - job-name: - required: true - type: string - default: "build-test-windows" push: branches: - main @@ -65,7 +60,7 @@ jobs: run: | echo matrix="$(echo '${{ needs.filter-matrix.outputs.matrix }}' | sed -e 's/windows.g4dn.xlarge/windows.g5.4xlarge.nvidia.gpu/g')" >> ${GITHUB_OUTPUT} - build-windows: + build: needs: substitute-runner permissions: id-token: write From 94bfebe370dbf168f3aaf81e82bd8ebaae490b7c Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Fri, 6 Jun 2025 16:44:27 -0700 Subject: [PATCH 20/26] test --- .github/workflows/build-test-linux-x86_64.yml | 2 +- .github/workflows/build-test-windows.yml | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 871a3b89f8..becc2f14e4 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -25,7 +25,7 @@ jobs: with-rocm: false with-cpu: false - filter-linux-x86_64-matrix: + filter-matrix: needs: [generate-linux-x86_64-matrix] outputs: matrix: ${{ steps.generate.outputs.matrix }} diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 6b8e520057..6396204fa4 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -26,8 +26,7 @@ jobs: with-rocm: false with-cpu: false - filter-windows-matrix: - name: filter-windows-matrix + filter-matrix: needs: [generate-windows-matrix] outputs: matrix: ${{ steps.generate.outputs.matrix }} @@ -50,7 +49,7 @@ jobs: echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" substitute-runner: - needs: filter-windows-matrix + needs: filter-matrix outputs: matrix: ${{ steps.substitute.outputs.matrix }} runs-on: ubuntu-latest From e66c53f883d02cfb4e73d472c34429afb8b34d73 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Sun, 8 Jun 2025 10:17:03 -0700 Subject: [PATCH 21/26] test --- .github/workflows/build-test-all.yml | 42 +--- .../workflows/build-test-linux-aarch64.yml | 4 - .github/workflows/build-test-linux-x86_64.yml | 223 +++++++++--------- .github/workflows/build-test-windows.yml | 63 ++--- .github/workflows/test_a.yml | 2 +- 5 files changed, 158 insertions(+), 176 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 8c1c6d5f3d..45da8db712 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -19,39 +19,17 @@ permissions: packages: write jobs: - generate-matrix: - uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main + trigger-fail-fast-test: + permissions: + id-token: write + contents: read + packages: write + uses: ./.github/workflows/build-test-linux-x86_64.yml with: - package-type: wheel - os: linux - test-infra-repository: pytorch/test-infra - test-infra-ref: main - with-rocm: false - with-cpu: false - - filter-matrix: - needs: [generate-matrix] - outputs: - matrix: ${{ steps.generate.outputs.matrix }} - runs-on: ubuntu-latest - steps: - - uses: actions/setup-python@v5 - with: - python-version: '3.11' - - uses: actions/checkout@v4 - with: - repository: pytorch/tensorrt - - name: Generate matrix - id: generate - run: | - set -eou pipefail - MATRIX_BLOB=${{ toJSON(needs.generate-matrix.outputs.matrix) }} - MATRIX_BLOB="$(python3 .github/scripts/filter-matrix.py --matrix "${MATRIX_BLOB}")" - echo "${MATRIX_BLOB}" - echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" - + fail-fast: true + trigger-linux-test: - needs: [filter-matrix] + needs: [trigger-fail-fast-test] if: always() permissions: id-token: write @@ -60,7 +38,7 @@ jobs: uses: ./.github/workflows/build-test-linux-x86_64.yml trigger-windows-test: - needs: [filter-matrix] + needs: [trigger-fail-fast-test] if: always() permissions: id-token: write diff --git a/.github/workflows/build-test-linux-aarch64.yml b/.github/workflows/build-test-linux-aarch64.yml index 4ffbe31b66..e58af13ae7 100644 --- a/.github/workflows/build-test-linux-aarch64.yml +++ b/.github/workflows/build-test-linux-aarch64.yml @@ -2,10 +2,6 @@ name: Build and test Linux aarch64 wheels on: #pull_request: - workflow_run: - workflows: ["Build and test Linux x86_64 wheels"] - types: - - completed push: branches: - main diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index bfa2d06aee..787b4c2396 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -3,6 +3,10 @@ name: Lan test workflow x86_64 wheels on: #pull_request: workflow_call: + inputs: + fail-fast: + required: false + default: "false" push: branches: - main @@ -46,124 +50,127 @@ jobs: echo "${MATRIX_BLOB}" echo "matrix=${MATRIX_BLOB}" >> "${GITHUB_OUTPUT}" - # build: - # needs: filter-matrix - # permissions: - # id-token: write - # contents: read - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # pre-script: packaging/pre_build_script.sh - # env-var-script: packaging/env_vars.txt - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # package-name: torch_tensorrt - # name: Build torch-tensorrt whl package - # uses: pytorch/test-infra/.github/workflows/build_wheels_linux.yml@main - # with: - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # env-var-script: ${{ matrix.env-var-script }} - # post-script: ${{ matrix.post-script }} - # package-name: ${{ matrix.package-name }} - # smoke-test-script: ${{ matrix.smoke-test-script }} - # trigger-event: ${{ github.event_name }} + build: + needs: filter-matrix + permissions: + id-token: write + contents: read + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + pre-script: packaging/pre_build_script.sh + env-var-script: packaging/env_vars.txt + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + package-name: torch_tensorrt + name: Build torch-tensorrt whl package + uses: pytorch/test-infra/.github/workflows/build_wheels_linux.yml@main + with: + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + env-var-script: ${{ matrix.env-var-script }} + post-script: ${{ matrix.post-script }} + package-name: ${{ matrix.package-name }} + smoke-test-script: ${{ matrix.smoke-test-script }} + trigger-event: ${{ github.event_name }} - # tests-py-fail-fast: - # name: Test fail fast [Python] - # needs: [filter-matrix, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-critical-fail-fast - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH - # pushd . - # python -m pip install -r tests/py/requirements.txt - # cov_param="--cov=torch_tensorrt --cov-report= --cov-config=pyproject.toml" + tests-py-fail-fast: + name: Test fail fast [Python] + if: inputs.fail-fast == 'true' + needs: [filter-matrix, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-critical-fail-fast + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + export USE_HOST_DEPS=1 + export CI_BUILD=1 + export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH + pushd . + python -m pip install -r tests/py/requirements.txt + cov_param="--cov=torch_tensorrt --cov-report= --cov-config=pyproject.toml" - # # test dynamo backend - # python -m pytest -m critical ${cov_param} -n 4 tests/py/dynamo/backend/ + # test dynamo backend + python -m pytest -m critical ${cov_param} -n 4 tests/py/dynamo/backend/ - # # test dynamo models - # python -m pytest -m critical ${cov_param} -ra --cov-append --ir dynamo tests/py/dynamo/models/ + # test dynamo models + python -m pytest -m critical ${cov_param} -ra --cov-append --ir dynamo tests/py/dynamo/models/ - # # test dynamo automatic plugin - # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/automatic_plugin/ + # test dynamo automatic plugin + python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/automatic_plugin/ - # # test dynamo partitioning - # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/partitioning/ + # test dynamo partitioning + python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/partitioning/ - # # test dynamo lowering - # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/lowering/ + # test dynamo lowering + python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/lowering/ - # # test dynamo runtime - # python -m pytest ${cov_param} --cov-append tests/py/dynamo/runtime/test_000_* - # python -m pytest -m critical ${cov_param} --cov-append --ignore tests/py/dynamo/runtime/test_000_* tests/py/dynamo/runtime/ + # test dynamo runtime + python -m pytest ${cov_param} --cov-append tests/py/dynamo/runtime/test_000_* + python -m pytest -m critical ${cov_param} --cov-append --ignore tests/py/dynamo/runtime/test_000_* tests/py/dynamo/runtime/ - # # test core - # python -m pytest -m critical ${cov_param} --cov-append tests/py/core/ + # test core + python -m pytest -m critical ${cov_param} --cov-append tests/py/core/ - # coverage report --fail-under=20 + coverage report --fail-under=20 - # tests-py-torchscript-fe: - # name: Test torchscript frontend [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-torchscript-fe - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH - # pushd . - # cd tests/modules - # python hub.py - # popd - # pushd . - # cd tests/py/ts - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ - # popd + tests-py-torchscript-fe: + name: Test torchscript frontend [Python] + needs: [filter-matrix, build] + if: inputs.fail-fast == 'false' + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-torchscript-fe + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH + # pushd . + # cd tests/modules + # python hub.py + # popd + # pushd . + # cd tests/py/ts + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ + # popd # tests-py-dynamo-converters: # name: Test dynamo converters [Python] diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 551da73505..975289bb7b 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -87,37 +87,38 @@ jobs: trigger-event: ${{ github.event_name }} timeout: 120 - # tests-py-torchscript-fe: - # name: Test torchscript frontend [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-torchscript-fe - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/modules - # python hub.py - # popd - # pushd . - # cd tests/py/ts - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ - # popd + tests-py-torchscript-fe: + name: Test torchscript frontend [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-torchscript-fe + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/modules + # python hub.py + # popd + # pushd . + # cd tests/py/ts + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_api_test_results.xml api/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_models_test_results.xml models/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ + # popd # tests-py-dynamo-converters: # name: Test dynamo converters [Python] diff --git a/.github/workflows/test_a.yml b/.github/workflows/test_a.yml index 54082ff3d8..cb73ce72aa 100644 --- a/.github/workflows/test_a.yml +++ b/.github/workflows/test_a.yml @@ -1,7 +1,7 @@ name: Lan test a on: - pull_request: + #pull_request: jobs: pre-test: From d161bcb70f00694b0e140b7e0b2e84d597461ff9 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Sun, 8 Jun 2025 10:36:41 -0700 Subject: [PATCH 22/26] test --- .github/workflows/build-test-all.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index fb37b5fbc9..f4ec001f75 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -29,7 +29,7 @@ jobs: fail-fast: true trigger-linux-test: - needs: [fail-fast-test] + needs: [trigger-fail-fast-test] strategy: fail-fast: false if: always() From 9fb5d64fa9adf9509963d012eeee50e796be5c61 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Sun, 8 Jun 2025 10:42:10 -0700 Subject: [PATCH 23/26] test --- .github/workflows/build-test-all.yml | 8 +++++++- .github/workflows/build-test-linux-x86_64.yml | 10 ++++++---- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index f4ec001f75..1276bca5d5 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -20,13 +20,15 @@ permissions: jobs: trigger-fail-fast-test: + strategy: + fail-fast: false permissions: id-token: write contents: read packages: write uses: ./.github/workflows/build-test-linux-x86_64.yml with: - fail-fast: true + run-fail-fast-test-set: true trigger-linux-test: needs: [trigger-fail-fast-test] @@ -39,10 +41,14 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-linux-x86_64.yml + with: + run-fail-fast-test-set: false trigger-windows-test: needs: [trigger-fail-fast-test] if: always() + strategy: + fail-fast: false name: build-test on windows permissions: id-token: write diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index ab5badb808..854538b252 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -4,9 +4,11 @@ on: #pull_request: workflow_call: inputs: - fail-fast: + run-fail-fast-test-set: + description: "Fail fast test set flag" required: false - default: "false" + type: boolean + default: false push: branches: - main @@ -83,7 +85,7 @@ jobs: tests-py-fail-fast: name: Test fail fast [Python] - if: inputs.fail-fast == 'true' + if: inputs.run-fail-fast-test-set == true needs: [filter-matrix, build] strategy: fail-fast: false @@ -138,7 +140,7 @@ jobs: tests-py-torchscript-fe: name: Test torchscript frontend [Python] needs: [filter-matrix, build] - if: inputs.fail-fast == 'false' + if: inputs.run-fail-fast-test-set == false strategy: fail-fast: false matrix: From 23344ca360cee0dd8cb28a0099ba9235134499f5 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Sun, 8 Jun 2025 11:35:49 -0700 Subject: [PATCH 24/26] test --- .github/workflows/build-test-all.yml | 2 -- .github/workflows/build-test-linux-x86_64.yml | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 1276bca5d5..4d6b50cc00 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -34,7 +34,6 @@ jobs: needs: [trigger-fail-fast-test] strategy: fail-fast: false - if: always() name: build-test on linux-x86_64 permissions: id-token: write @@ -46,7 +45,6 @@ jobs: trigger-windows-test: needs: [trigger-fail-fast-test] - if: always() strategy: fail-fast: false name: build-test on windows diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 854538b252..da598baa15 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -85,7 +85,7 @@ jobs: tests-py-fail-fast: name: Test fail fast [Python] - if: inputs.run-fail-fast-test-set == true + if: ${{ inputs.run-fail-fast-test-set == true }} needs: [filter-matrix, build] strategy: fail-fast: false @@ -140,7 +140,7 @@ jobs: tests-py-torchscript-fe: name: Test torchscript frontend [Python] needs: [filter-matrix, build] - if: inputs.run-fail-fast-test-set == false + if: ${{ inputs.run-fail-fast-test-set == false }} strategy: fail-fast: false matrix: From aac238ae47ec434c6633b7f907ceb36a2749acd8 Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Mon, 9 Jun 2025 07:38:41 -0700 Subject: [PATCH 25/26] test --- .github/workflows/build-test-linux-x86_64.yml | 488 +++++++++--------- .github/workflows/build-test-windows.yml | 393 +++++++------- 2 files changed, 448 insertions(+), 433 deletions(-) diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index da598baa15..01165de4c6 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -106,36 +106,37 @@ jobs: build-matrix: ${{ needs.filter-matrix.outputs.matrix }} pre-script: ${{ matrix.pre-script }} script: | - export USE_HOST_DEPS=1 - export CI_BUILD=1 - export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH - pushd . - python -m pip install -r tests/py/requirements.txt - cov_param="--cov=torch_tensorrt --cov-report= --cov-config=pyproject.toml" + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # export LD_LIBRARY_PATH=/usr/lib64:$LD_LIBRARY_PATH + # pushd . + # python -m pip install -r tests/py/requirements.txt + # cov_param="--cov=torch_tensorrt --cov-report= --cov-config=pyproject.toml" - # test dynamo backend - python -m pytest -m critical ${cov_param} -n 4 tests/py/dynamo/backend/ + # # test dynamo backend + # python -m pytest -m critical ${cov_param} -n 4 tests/py/dynamo/backend/ - # test dynamo models - python -m pytest -m critical ${cov_param} -ra --cov-append --ir dynamo tests/py/dynamo/models/ + # # test dynamo models + # python -m pytest -m critical ${cov_param} -ra --cov-append --ir dynamo tests/py/dynamo/models/ - # test dynamo automatic plugin - python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/automatic_plugin/ + # # test dynamo automatic plugin + # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/automatic_plugin/ - # test dynamo partitioning - python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/partitioning/ + # # test dynamo partitioning + # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/partitioning/ - # test dynamo lowering - python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/lowering/ + # # test dynamo lowering + # python -m pytest -m critical ${cov_param} --cov-append tests/py/dynamo/lowering/ - # test dynamo runtime - python -m pytest ${cov_param} --cov-append tests/py/dynamo/runtime/test_000_* - python -m pytest -m critical ${cov_param} --cov-append --ignore tests/py/dynamo/runtime/test_000_* tests/py/dynamo/runtime/ + # # test dynamo runtime + # python -m pytest ${cov_param} --cov-append tests/py/dynamo/runtime/test_000_* + # python -m pytest -m critical ${cov_param} --cov-append --ignore tests/py/dynamo/runtime/test_000_* tests/py/dynamo/runtime/ - # test core - python -m pytest -m critical ${cov_param} --cov-append tests/py/core/ + # # test core + # python -m pytest -m critical ${cov_param} --cov-append tests/py/core/ - coverage report --fail-under=20 + # coverage report --fail-under=20 tests-py-torchscript-fe: name: Test torchscript frontend [Python] @@ -175,230 +176,237 @@ jobs: # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ # popd - # tests-py-dynamo-converters: - # name: Test dynamo converters [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-dynamo-converters - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin_with_attrs.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_flashinfer_rmsnorm.py - # popd + tests-py-dynamo-converters: + name: Test dynamo converters [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-dynamo-converters + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_automatic_plugin_with_attrs.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml automatic_plugin/test_flashinfer_rmsnorm.py + # popd - # tests-py-dynamo-fe: - # name: Test dynamo frontend [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-dynamo-fe - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ - # popd + tests-py-dynamo-fe: + name: Test dynamo frontend [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-dynamo-fe + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ + # popd - # tests-py-dynamo-serde: - # name: Test dynamo export serde [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-dynamo-serde - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py - # popd + tests-py-dynamo-serde: + name: Test dynamo export serde [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-dynamo-serde + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py + # popd - # tests-py-torch-compile-be: - # name: Test torch compile backend [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-torch-compile-be - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py - # popd + tests-py-torch-compile-be: + name: Test torch compile backend [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-torch-compile-be + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py + # popd - # tests-py-dynamo-core: - # name: Test dynamo core [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-dynamo-core - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ - # popd + tests-py-dynamo-core: + name: Test dynamo core [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-dynamo-core + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ + # popd - # tests-py-dynamo-cudagraphs: - # name: Test dynamo cudagraphs [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-dynamo-cudagraphs - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # nvidia-smi - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py || true - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py || true - # popd + tests-py-dynamo-cudagraphs: + name: Test dynamo cudagraphs [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-dynamo-cudagraphs + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # nvidia-smi + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py || true + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py || true + # popd - # tests-py-core: - # name: Test core [Python] - # needs: [filter-matrix, build, tests-py-fail-fast] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # pre-script: packaging/pre_build_script.sh - # post-script: packaging/post_build_script.sh - # smoke-test-script: packaging/smoke_test_script.sh - # uses: ./.github/workflows/linux-test.yml - # with: - # job-name: tests-py-core - # repository: "pytorch/tensorrt" - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.filter-matrix.outputs.matrix }} - # pre-script: ${{ matrix.pre-script }} - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py/core - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . - # popd + tests-py-core: + name: Test core [Python] + needs: [filter-matrix, build, tests-py-fail-fast] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + pre-script: packaging/pre_build_script.sh + post-script: packaging/post_build_script.sh + smoke-test-script: packaging/smoke_test_script.sh + uses: ./.github/workflows/linux-test.yml + with: + job-name: tests-py-core + repository: "pytorch/tensorrt" + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.filter-matrix.outputs.matrix }} + pre-script: ${{ matrix.pre-script }} + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py/core + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . + # popd concurrency: group: ${{ github.workflow }}-linux-x86_64-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 8ea685f86d..4349571dc3 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -121,205 +121,212 @@ jobs: # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/ts_integrations_test_results.xml integrations/ # popd - # tests-py-dynamo-converters: - # name: Test dynamo converters [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-dynamo-converters - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ - # popd + tests-py-dynamo-converters: + name: Test dynamo converters [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-dynamo-converters + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 4 conversion/ + # popd - # tests-py-dynamo-fe: - # name: Test dynamo frontend [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-dynamo-fe - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ - # popd + tests-py-dynamo-fe: + name: Test dynamo frontend [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-dynamo-fe + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/ + # popd - # tests-py-dynamo-serde: - # name: Test dynamo export serde [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-dynamo-serde - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py - # popd + tests-py-dynamo-serde: + name: Test dynamo export serde [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-dynamo-serde + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/export_serde_test_results.xml --ir dynamo models/test_export_serde.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/reexport_test_results.xml --ir dynamo models/test_reexport.py + # popd - # tests-py-torch-compile-be: - # name: Test torch compile backend [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-torch-compile-be - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py - # popd + tests-py-torch-compile-be: + name: Test torch compile backend [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-torch-compile-be + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_complete_be_e2e_test_results.xml --ir torch_compile models/test_models.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_dyn_models_export.xml --ir torch_compile models/test_dyn_models.py + # popd - # tests-py-dynamo-core: - # name: Test dynamo core [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-dynamo-core - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ - # popd + tests-py-dynamo-core: + name: Test dynamo core [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-dynamo-core + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml --ignore runtime/test_002_cudagraphs_py.py --ignore runtime/test_002_cudagraphs_cpp.py runtime/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ + # popd - # tests-py-dynamo-cudagraphs: - # name: Test dynamo cudagraphs [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-dynamo-cudagraphs - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py - # python -m pip install -r requirements.txt - # cd dynamo - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py - # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py - # popd + tests-py-dynamo-cudagraphs: + name: Test dynamo cudagraphs [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-dynamo-cudagraphs + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py + # python -m pip install -r requirements.txt + # cd dynamo + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_cpp_test_results.xml runtime/test_002_cudagraphs_cpp.py + # python -m pytest -ra --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_cudagraphs_py_test_results.xml runtime/test_002_cudagraphs_py.py + # popd - # tests-py-core: - # name: Test core [Python] - # needs: [substitute-runner, build] - # strategy: - # fail-fast: false - # matrix: - # include: - # - repository: pytorch/tensorrt - # package-name: torch_tensorrt - # uses: ./.github/workflows/windows-test.yml - # with: - # job-name: tests-py-core - # repository: ${{ matrix.repository }} - # ref: "" - # test-infra-repository: pytorch/test-infra - # test-infra-ref: main - # build-matrix: ${{ needs.substitute-runner.outputs.matrix }} - # pre-script: packaging/driver_upgrade.bat - # script: | - # export USE_HOST_DEPS=1 - # export CI_BUILD=1 - # pushd . - # cd tests/py/core - # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . - # popd + tests-py-core: + name: Test core [Python] + needs: [substitute-runner, build] + strategy: + fail-fast: false + matrix: + include: + - repository: pytorch/tensorrt + package-name: torch_tensorrt + uses: ./.github/workflows/windows-test.yml + with: + job-name: tests-py-core + repository: ${{ matrix.repository }} + ref: "" + test-infra-repository: pytorch/test-infra + test-infra-ref: main + build-matrix: ${{ needs.substitute-runner.outputs.matrix }} + pre-script: packaging/driver_upgrade.bat + script: | + echo "test" + # export USE_HOST_DEPS=1 + # export CI_BUILD=1 + # pushd . + # cd tests/py/core + # python -m pytest -ra -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_core_test_results.xml . + # popd concurrency: group: ${{ github.workflow }}-windows-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} From 772ff931d5ab31636de4b98599c7bfb0e65fa04c Mon Sep 17 00:00:00 2001 From: lanluo-nvidia Date: Mon, 9 Jun 2025 09:47:44 -0700 Subject: [PATCH 26/26] test --- .github/workflows/build-test-all.yml | 7 +++++-- .github/workflows/build-test-linux-x86_64.yml | 7 ++++++- .github/workflows/build-test-windows.yml | 6 ++++++ 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-test-all.yml b/.github/workflows/build-test-all.yml index 4d6b50cc00..892ef9f24d 100644 --- a/.github/workflows/build-test-all.yml +++ b/.github/workflows/build-test-all.yml @@ -42,6 +42,7 @@ jobs: uses: ./.github/workflows/build-test-linux-x86_64.yml with: run-fail-fast-test-set: false + job-name: trigger-linux-test trigger-windows-test: needs: [trigger-fail-fast-test] @@ -53,6 +54,8 @@ jobs: contents: read packages: write uses: ./.github/workflows/build-test-windows.yml + with: + job-name: trigger-windows-test wait-all-jobs: needs: [trigger-linux-test, trigger-windows-test] @@ -65,5 +68,5 @@ jobs: echo "Waiting for all jobs to complete..." concurrency: - group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} - cancel-in-progress: false \ No newline at end of file + group: ${{ github.workflow }}-all-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} + cancel-in-progress: true \ No newline at end of file diff --git a/.github/workflows/build-test-linux-x86_64.yml b/.github/workflows/build-test-linux-x86_64.yml index 01165de4c6..6c6186a013 100644 --- a/.github/workflows/build-test-linux-x86_64.yml +++ b/.github/workflows/build-test-linux-x86_64.yml @@ -9,6 +9,11 @@ on: required: false type: boolean default: false + job-name: + description: "Job name" + required: false + type: string + default: "build-test-linux-x86_64" push: branches: - main @@ -410,4 +415,4 @@ jobs: concurrency: group: ${{ github.workflow }}-linux-x86_64-${{ github.event.pull_request.number || github.ref_name }}-${{ inputs.repository }}-${{ github.event_name == 'workflow_dispatch' }}-${{ inputs.job-name }} - cancel-in-progress: false + cancel-in-progress: true diff --git a/.github/workflows/build-test-windows.yml b/.github/workflows/build-test-windows.yml index 4349571dc3..4496e04208 100644 --- a/.github/workflows/build-test-windows.yml +++ b/.github/workflows/build-test-windows.yml @@ -3,6 +3,12 @@ name: Lan test Windows wheels on: #pull_request: workflow_call: + inputs: + job-name: + description: "Job name" + required: false + type: string + default: "build-test-windows" push: branches: - main