Skip to content
Draft
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
12 changes: 9 additions & 3 deletions .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,15 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
# Before anything runs Python, so no __pycache__ moves the hash. The save
# step below reuses this key rather than hashing again.
# step below reuses this key rather than hashing again. The hash does not
# see the runner's packages (fonts, Chromium's libraries): bump the version
# when they change what a clip looks like (v2: CJK fonts).
- name: Restore this shard
id: cache
uses: actions/cache/restore@v4
with:
path: media-shard
key: composer-media-v1-${{ matrix.shard }}of${{ strategy.job-total }}-${{ hashFiles('src/open_apps/**', 'config/**', 'scripts/render_composer_media.py', 'uv.lock') }}
key: composer-media-v2-${{ matrix.shard }}of${{ strategy.job-total }}-${{ hashFiles('src/open_apps/**', 'config/**', 'scripts/render_composer_media.py', 'uv.lock') }}
- name: Set up Python 3.11
if: steps.cache.outputs.cache-hit != 'true'
uses: actions/setup-python@v5
Expand All @@ -60,14 +62,18 @@ jobs:
uv sync
# As in test_playground.yml: not `--with-deps`, since Playwright 1.44
# predates 24.04 and asks apt for pre-t64 names (libasound2).
# fonts-droid-fallback because the runner has no CJK font, and without one
# Chromium draws every character of the Mandarin language pack as a box.
# Droid Sans Fallback is the CJK font our cluster's compute nodes have, so
# a clip shows Mandarin as the agents there see it.
- name: Install Chromium for Playwright
if: steps.cache.outputs.cache-hit != 'true'
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends \
libasound2t64 libatk1.0-0t64 libatk-bridge2.0-0t64 libcups2t64 \
libgbm1 libnss3 libxcomposite1 libxdamage1 libxfixes3 libxrandr2 \
libxkbcommon0 libpango-1.0-0 libcairo2
libxkbcommon0 libpango-1.0-0 libcairo2 fonts-droid-fallback
uv run playwright install chromium
# The manifest is checkpointed after every clip, so a shard that fails or
# hits the time limit still uploads what it rendered.
Expand Down
Loading