fix: adapt torchrun to dynamic GPU count #4
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: metax_tests | |
| on: | |
| push: | |
| branches: ["main"] | |
| pull_request: | |
| branches: ["main"] | |
| workflow_dispatch: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}-${{ github.actor }} | |
| cancel-in-progress: true | |
| jobs: | |
| run_tests: | |
| # 关键修改:告诉 common 工作流去读取 .github/configs/metax.yml | |
| uses: ./.github/workflows/all_tests_common.yml | |
| with: | |
| platform: metax | |
| all_tests: | |
| needs: run_tests | |
| runs-on: ubuntu-latest | |
| if: always() | |
| steps: | |
| - name: Verify workflow status | |
| run: | | |
| if [ "${{ needs.run_tests.result }}" != "success" ]; then | |
| echo "❌ Metax Tests workflow failed" | |
| exit 1 | |
| fi | |
| echo "✅ All Metax tests passed!" |