Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
106 changes: 91 additions & 15 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,18 @@ on:
# Cron runs at 16:00 UTC which corresponds to 09:00 AM PT
- cron: "0 16 * * 1"

env:
# ilammy/msvc-dev-cmd has no Node 24 release; opt it (and any other
# holdouts) into Node 24 ahead of GitHub's June 2026 forced switch.
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true

jobs:
prepare-matrix:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5

- name: Setup Matrix
id: set-matrix
Expand Down Expand Up @@ -51,12 +56,14 @@ jobs:
with:
cmakeVersion: "~3.26.0"

- uses: actions/checkout@v4
- uses: actions/checkout@v5
- uses: ilammy/msvc-dev-cmd@v1
- name: Setup Python
uses: actions/setup-python@v5
uses: actions/setup-python@v6
with:
python-version: "3.10.11"
cache: "pip"
cache-dependency-path: scripts/requirements.txt
id: setup-python

- name: Install Ninja (Cross-platform)
Expand Down Expand Up @@ -138,7 +145,7 @@ jobs:

- name: Download FBX SDK Artifact
if: matrix.config == 'FBX' || matrix.config == 'ALL'
uses: actions/download-artifact@v4
uses: actions/download-artifact@v7
with:
name: ${{ runner.os }}-FBX-SDK
path: ${{ github.workspace }}/FBXSDK
Expand Down Expand Up @@ -240,7 +247,7 @@ jobs:
done

- name: Install test requirements
run: pip install -r scripts/requirements.txt
run: pip install --retries 5 --timeout 300 -r scripts/requirements.txt

- name: Run tests and inspect dependencies
shell: bash
Expand All @@ -264,14 +271,83 @@ jobs:
echo "BUILD_STATUS_STRING=Failed" >> $GITHUB_ENV
echo "BUILD_STATUS_COLOR=red" >> $GITHUB_ENV

- name: Update Badge
if: always()
uses: schneegans/dynamic-badges-action@v1.7.0
- name: Record badge status
if: ${{ !cancelled() }}
shell: bash
env:
BADGE_NAME: ${{ matrix.os }}-${{ matrix.usd_version }}-${{ matrix.config }}
run: |
mkdir -p badge-status
jq -nc \
--arg filename "${BADGE_NAME}.json" \
--arg badge_label "${BADGE_NAME}" \
--arg message "${BUILD_STATUS_STRING:-Failed}" \
--arg color "${BUILD_STATUS_COLOR:-red}" \
'{filename: $filename, "label": $badge_label, message: $message, color: $color}' \
> "badge-status/${BADGE_NAME}.json"

- name: Upload badge status
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v6
with:
auth: ${{ secrets.GIST_SECRET }}
gistID: 264643f3d2acacc5369a0ba70854dfb6
filename: ${{ matrix.os }}-${{ matrix.usd_version }}-${{ matrix.config }}.json
label: ${{ matrix.os }}-${{ matrix.usd_version }}-${{ matrix.config }}
message: ${{ env.BUILD_STATUS_STRING }}
color: "${{ env.BUILD_STATUS_COLOR }}"
forceUpdate: true
name: badge-${{ matrix.os }}-${{ matrix.usd_version }}-${{ matrix.config }}
path: badge-status/
retention-days: 1

update-badges:
needs: build
if: ${{ !cancelled() }}
runs-on: ubuntu-latest
steps:
- name: Download all badge statuses
uses: actions/download-artifact@v7
with:
pattern: badge-*
path: badges
merge-multiple: true

- name: Update gist badges
env:
GIST_SECRET: ${{ secrets.GIST_SECRET }}
GIST_ID: 264643f3d2acacc5369a0ba70854dfb6
shell: bash
run: |
shopt -s nullglob
files=(badges/*.json)
if [ ${#files[@]} -eq 0 ]; then
echo "No badge status files found; nothing to update."
exit 0
fi
echo "Bundling ${#files[@]} badges into a single PATCH..."

# Build a single {files: {name: {content: ...}, ...}} payload.
payload=$(jq -nc \
'reduce inputs as $b ({files: {}};
.files[$b.filename] = {
content: ({schemaVersion: 1, label: $b.label, message: $b.message, color: $b.color} | tostring)
})' \
"${files[@]}")

# Retry on 409 (gist git conflict), 403 (secondary rate limit), and transient 5xx.
for attempt in 1 2 3 4 5 6; do
code=$(curl -sS -o /tmp/gist-resp -w "%{http_code}" \
-X PATCH \
-H "Authorization: token ${GIST_SECRET}" \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
-H "Content-Type: application/json" \
--data-binary "$payload" \
"https://api.github.com/gists/${GIST_ID}")
if [ "$code" = "200" ]; then
echo "OK updated ${#files[@]} badges in one call"
exit 0
fi
echo "Attempt $attempt failed (HTTP $code)"
cat /tmp/gist-resp || true
echo
if [ "$attempt" -eq 6 ]; then
echo "Giving up after $attempt attempts."
exit 1
fi
sleep $((attempt * 5))
done
4 changes: 2 additions & 2 deletions .github/workflows/create-usd-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:

- name: Set up Python
if: env.exists == 'false'
uses: actions/setup-python@v5
uses: actions/setup-python@v6
with:
python-version: "3.10.11"
id: setup-python
Expand Down Expand Up @@ -186,7 +186,7 @@ jobs:
if ("${{runner.os}}" -eq "Linux") {
$abi_arg = "--use-cxx11-abi 0"
}
$python_cmd = "python $file `${{ github.workspace }}/usd_build` --onetbb --no-examples --draco --openimageio --no-materialx --tools --build-variant release $abi_arg $generator"
$python_cmd = "python $file `${{ github.workspace }}/usd_build` --onetbb --no-examples --draco --openimageio --tools --build-variant release $abi_arg $generator"
Invoke-Expression $python_cmd

- name: Remove Specific Folders Unix
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/fbx-sdk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
uses: actions/checkout@v5

- name: Download SDKs
run: |
Expand All @@ -20,19 +20,19 @@ jobs:
curl -L -o fbx202037_fbxsdk_gcc_linux.tar.gz -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36" "https://damassets.autodesk.net/content/dam/autodesk/www/files/fbx202037_fbxsdk_gcc_linux.tar.gz"
- name: Upload SDK for Windows
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: Windows-FBX-SDK
path: fbx202037_fbxsdk_vs2022_win.exe

- name: Upload SDK for macOS
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: macOS-FBX-SDK
path: fbx202037_fbxsdk_clang_mac.pkg.tgz

- name: Upload SDK for Linux
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v6
with:
name: Linux-FBX-SDK
path: fbx202037_fbxsdk_gcc_linux.tar.gz
Loading