Skip to content

build(deps): bump github.com/pion/webrtc/v4 from 4.0.12 to 4.2.17 in /examples/webrtc-control #2640

build(deps): bump github.com/pion/webrtc/v4 from 4.0.12 to 4.2.17 in /examples/webrtc-control

build(deps): bump github.com/pion/webrtc/v4 from 4.0.12 to 4.2.17 in /examples/webrtc-control #2640

Workflow file for this run

name: CI
on:
pull_request:
# No docs-only bypasses: full CI must run even when a PR changes only markdown files.
paths:
- '**'
push:
branches:
- master
# Keep push behavior aligned with PRs: run CI for every changed file type.
paths:
- '**'
permissions:
contents: read
env:
LIBOPUS_VERSION: "1.6.1"
GOPUS_DISABLE_OPUSDEC: "0"
GOPUS_DISABLE_OPUSENC: "1"
GOLANGCI_LINT_VERSION: "v1.64.8"
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
changes:
name: detect-change-scope
runs-on: ubuntu-latest
outputs:
docs_only: ${{ steps.scope.outputs.docs_only }}
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Detect markdown-only change set
id: scope
shell: bash
run: |
set -euo pipefail
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
base="${{ github.event.pull_request.base.sha }}"
head="${{ github.event.pull_request.head.sha }}"
else
base="${{ github.event.before }}"
head="${{ github.sha }}"
fi
# New branch pushes use an all-zero "before" SHA.
if [[ "$base" == "0000000000000000000000000000000000000000" ]]; then
base="$(git rev-list --max-parents=0 "$head" | tail -n 1)"
fi
git diff --name-only "$base" "$head" | tee /tmp/changed_files.txt
if [[ ! -s /tmp/changed_files.txt ]]; then
docs_only=true
elif awk 'BEGIN { docs=1 } $0 !~ /\.md$/ { docs=0 } END { exit docs ? 0 : 1 }' /tmp/changed_files.txt; then
docs_only=true
else
docs_only=false
fi
echo "docs_only=$docs_only" >> "$GITHUB_OUTPUT"
echo "docs_only=$docs_only"
lint-static-analysis:
name: lint-static-analysis
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run docs contract
run: make test-doc-contract
- name: Run libopus type parity guard
run: make test-type-parity
- name: PGO profile validity smoke
run: make pgo-validate
- name: Install golangci-lint
run: |
GOWORK=off go install github.com/golangci/golangci-lint/cmd/golangci-lint@${GOLANGCI_LINT_VERSION}
echo "$(go env GOPATH)/bin" >> "$GITHUB_PATH"
- name: Run lint/static analysis
run: make lint
lint-tag-matrix:
name: lint-tag-matrix
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Install golangci-lint
run: |
GOWORK=off go install github.com/golangci/golangci-lint/cmd/golangci-lint@${GOLANGCI_LINT_VERSION}
echo "$(go env GOPATH)/bin" >> "$GITHUB_PATH"
- name: Run lint/static analysis across optional-feature tag builds
run: make test-lint-tags
test-linux-fast:
name: test-linux-fast
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run fast package sweep
run: make test-fast
test-linux-parity:
name: test-linux-parity
needs:
- changes
# Full libopus quality parity is the slowest regular Linux gate. PRs get
# the fast package sweep plus focused optional-surface gates; protected
# branch pushes keep the full quality gate.
if: github.event_name == 'push'
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Install codec tools (if missing)
run: |
if command -v ffmpeg >/dev/null 2>&1 && command -v opusdec >/dev/null 2>&1; then
echo "ffmpeg and opusdec already present; skipping apt install"
exit 0
fi
sudo apt-get update
sudo apt-get install -y --no-install-recommends ffmpeg opus-tools
- name: Run focused libopus quality gate
run: |
make fixtures-gen-platform
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 make test-quality
test-linux-conformance:
name: test-linux-conformance
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Install codec tools (if missing)
run: |
if command -v ffmpeg >/dev/null 2>&1 && command -v opusdec >/dev/null 2>&1; then
echo "ffmpeg and opusdec already present; skipping apt install"
exit 0
fi
sudo apt-get update
sudo apt-get install -y --no-install-recommends ffmpeg opus-tools
- name: Run opus_demo end-to-end conformance gate
run: make test-conformance
# Native same-arch (linux/amd64) precision guard. Regenerate the libopus
# reference fixtures from the libopus just built on this runner so the
# encoder precision guard compares gopus against an amd64 libopus built
# with this runner's own toolchain. This mirrors the macOS and
# ubuntu-arm64 native-fixture jobs and gives linux/amd64 a PR-time native
# precision guard (the pinned-Docker provenance job covers it on push).
- name: Generate native libopus fixtures
run: make fixtures-gen-platform
- name: Run native encoder precision guard (same-arch reference)
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=exhaustive GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^TestEncoderCompliancePrecisionGuard$' \
-count=1 -timeout=20m
test-linux-race:
name: test-linux-race
needs:
- changes
# Race sweeps are expensive and duplicate broad PR coverage. Keep them on
# protected-branch pushes where they still guard integration into master.
if: github.event_name == 'push'
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Install codec tools (if missing)
run: |
if command -v ffmpeg >/dev/null 2>&1 && command -v opusdec >/dev/null 2>&1; then
echo "ffmpeg and opusdec already present; skipping apt install"
exit 0
fi
sudo apt-get update
sudo apt-get install -y --no-install-recommends ffmpeg opus-tools
- name: Run race sweep
run: |
make ensure-libopus
make test-race
test-linux-provenance:
name: test-linux-provenance
needs:
- changes
# The provenance lane builds a pinned Docker environment and performs
# exhaustive fixture-honesty checks. Keep it on protected-branch pushes,
# while PR CI uses the faster parity/race/feature-tag gates below.
if: github.event_name == 'push'
runs-on: ubuntu-latest
timeout-minutes: 45
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Cache Docker buildx layers
uses: actions/cache@v5
with:
path: .docker-cache/buildx-linux-amd64
key: buildx-exhaustive-${{ runner.os }}-${{ runner.arch }}-${{ hashFiles('Dockerfile.ci', 'go.mod', 'go.sum', 'Makefile') }}
restore-keys: |
buildx-exhaustive-${{ runner.os }}-${{ runner.arch }}-
- name: Verify and generate linux/amd64 libopus fixtures (pinned Docker env)
run: |
make docker-test-exhaustive fixtures-gen-linux-amd64
- name: Reset Docker-owned libopus mount point
run: |
sudo rm -rf tmp_check
mkdir -p tmp_check
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run encoder variant provenance audit
run: make test-provenance
test-linux-flake:
name: test-linux-flake
needs:
- changes
# Shuffle+repeat flake detection is valuable but not needed on every PR
# attempt; run it once code lands on the protected branch.
if: github.event_name == 'push'
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Install codec tools (if missing)
run: |
if command -v ffmpeg >/dev/null 2>&1 && command -v opusdec >/dev/null 2>&1; then
echo "ffmpeg and opusdec already present; skipping apt install"
exit 0
fi
sudo apt-get update
sudo apt-get install -y --no-install-recommends ffmpeg opus-tools
- name: Run parity flake detector (shuffle+repeat, no skips allowed)
run: |
set -euo pipefail
make ensure-libopus
json_out="$(mktemp)"
# Keep this lane on the default parity gate surface only. Exactness
# tests intentionally self-skip unless explicitly enabled.
GOPUS_TEST_TIER=parity GOPUS_STRICT_LIBOPUS_REF=1 go test ./testvectors \
-run 'TestDecoderParityLibopusMatrix|TestEncoderComplianceSummary' \
-shuffle=on \
-count=3 \
-json | tee "$json_out"
if grep -q '"Action":"skip"' "$json_out"; then
echo "Unexpected skip detected in critical parity flake lane:"
grep '"Action":"skip"' "$json_out"
exit 1
fi
test-linux-fuzz-smoke:
name: test-linux-fuzz-smoke
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run fuzz smoke gate
run: make test-fuzz-smoke
test-linux-consumer-smoke:
name: test-linux-consumer-smoke
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run external-consumer smoke gate
run: make test-consumer-smoke
test-linux-examples-smoke:
name: test-linux-examples-smoke
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run examples smoke gate
run: make test-examples-smoke
test-linux-dnn-blob-parity:
name: test-linux-dnn-blob-parity
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-dnn-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run default DNN blob parity gate
run: make test-dnn-blob-parity
test-linux-extra-controls:
name: test-linux-extra-controls
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run extra-controls quarantine gate
run: make test-extra-controls-tag
test-linux-dred-tag:
name: test-linux-dred-tag
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run supported DRED feature-tag gate
run: make test-dred-tag
test-linux-qext-parity:
name: test-linux-qext-parity
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned QEXT libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}-qext
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-qext-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run supported QEXT feature-tag parity gate
run: make test-qext-parity
test-linux-custom-parity:
name: test-linux-custom-parity
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 25
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned custom-modes libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}-custom-scalar
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-custom-scalar-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run Opus Custom --enable-custom-modes C-oracle parity gate
run: make test-custom-parity
test-linux-corpus-quality:
name: test-linux-corpus-quality
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 25
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run extended corpus signal-quality parity gate
run: make test-corpus-quality
test-linux-extra-controls-parity:
name: test-linux-extra-controls-parity
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Run extra-controls parity sweep
run: make test-extra-controls-parity
- name: Note parity status
if: always()
run: echo "Required DRED extra-controls parity seams are part of the aggregate Linux correctness gate."
test-linux-build-config-matrix:
name: test-linux-build-config-matrix
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned scalar libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}-scalar
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-scalar-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run build-config matrix gate (purego ./...)
run: make test-build-config-matrix
test-linux-core-oracles:
name: test-linux-core-oracles
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run core float libopus C-oracle parity gate
run: make test-core-oracles-parity
test-linux-fixedpoint-parity:
name: test-linux-fixedpoint-parity
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 25
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned fixed-point libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}-fixed
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-fixed-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Run fixed-point libopus C-oracle parity gate
run: make test-fixedpoint-parity
test-linux:
name: test-linux
if: always()
needs:
- changes
- test-linux-fast
- test-linux-parity
- test-linux-race
- test-linux-provenance
- test-linux-flake
- test-linux-fuzz-smoke
- test-linux-consumer-smoke
- test-linux-examples-smoke
- test-linux-dnn-blob-parity
- test-linux-dred-tag
- test-linux-qext-parity
- test-linux-custom-parity
- test-linux-corpus-quality
- test-linux-extra-controls
- test-linux-extra-controls-parity
- test-linux-build-config-matrix
- test-linux-core-oracles
- test-linux-fixedpoint-parity
runs-on: ubuntu-latest
steps:
- name: Validate Linux gates
run: |
echo "test-linux-fast: ${{ needs.test-linux-fast.result }}"
echo "test-linux-parity: ${{ needs.test-linux-parity.result }} (required on push)"
echo "test-linux-race: ${{ needs.test-linux-race.result }} (required on push)"
echo "test-linux-provenance: ${{ needs.test-linux-provenance.result }} (required on push)"
echo "test-linux-flake: ${{ needs.test-linux-flake.result }} (required on push)"
echo "test-linux-fuzz-smoke: ${{ needs.test-linux-fuzz-smoke.result }}"
echo "test-linux-consumer-smoke: ${{ needs.test-linux-consumer-smoke.result }}"
echo "test-linux-examples-smoke: ${{ needs.test-linux-examples-smoke.result }}"
echo "test-linux-dnn-blob-parity: ${{ needs.test-linux-dnn-blob-parity.result }}"
echo "test-linux-dred-tag: ${{ needs.test-linux-dred-tag.result }}"
echo "test-linux-qext-parity: ${{ needs.test-linux-qext-parity.result }}"
echo "test-linux-custom-parity: ${{ needs.test-linux-custom-parity.result }}"
echo "test-linux-corpus-quality: ${{ needs.test-linux-corpus-quality.result }}"
echo "test-linux-extra-controls: ${{ needs.test-linux-extra-controls.result }}"
echo "test-linux-extra-controls-parity: ${{ needs.test-linux-extra-controls-parity.result }}"
echo "test-linux-build-config-matrix: ${{ needs.test-linux-build-config-matrix.result }}"
echo "test-linux-core-oracles: ${{ needs.test-linux-core-oracles.result }}"
echo "test-linux-fixedpoint-parity: ${{ needs.test-linux-fixedpoint-parity.result }}"
if [ "${{ needs.test-linux-fast.result }}" != "success" ]; then
exit 1
fi
if [ "${{ github.event_name }}" = "push" ] && [ "${{ needs.test-linux-parity.result }}" != "success" ]; then
exit 1
fi
if [ "${{ github.event_name }}" = "push" ] && [ "${{ needs.test-linux-race.result }}" != "success" ]; then
exit 1
fi
if [ "${{ github.event_name }}" = "push" ] && [ "${{ needs.test-linux-provenance.result }}" != "success" ]; then
exit 1
fi
if [ "${{ github.event_name }}" = "push" ] && [ "${{ needs.test-linux-flake.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-fuzz-smoke.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-consumer-smoke.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-examples-smoke.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-dnn-blob-parity.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-dred-tag.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-qext-parity.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-custom-parity.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-corpus-quality.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-extra-controls.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-extra-controls-parity.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-build-config-matrix.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-core-oracles.result }}" != "success" ]; then
exit 1
fi
if [ "${{ needs.test-linux-fixedpoint-parity.result }}" != "success" ]; then
exit 1
fi
perf-linux:
name: perf-linux
needs:
- changes
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Enforce benchmark guardrails
run: make bench-guard
- name: Enforce libopus-relative benchmark guardrails
run: make bench-libopus-guard
test-macos:
name: test-macos
needs:
- changes
runs-on: macos-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Cache pinned fixed-point libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}-fixed
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-fixed-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Cache pinned custom-modes libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}-custom-scalar
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-custom-scalar-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Install codec tools (if missing)
run: |
if command -v ffmpeg >/dev/null 2>&1 && command -v opusdec >/dev/null 2>&1; then
echo "ffmpeg and opusdec already present; skipping brew install"
exit 0
fi
brew install ffmpeg opus-tools
- name: Bootstrap pinned libopus
run: make ensure-libopus
- name: Run core float libopus C-oracle parity gate
run: make test-core-oracles-parity
- name: Run supported DRED feature-tag C-oracle parity gate
run: make test-dred-tag
- name: Run fixed-point libopus C-oracle parity gate
run: make test-fixedpoint-parity
- name: Run Opus Custom --enable-custom-modes C-oracle parity gate
run: make test-custom-parity
- name: Run extended corpus signal-quality parity gate
run: make test-corpus-quality
- name: Generate native libopus fixtures
run: make fixtures-gen-platform
- name: Run native decoder fixture parity smoke
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=parity GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^(TestDecoderParityLibopusMatrix|TestDecoderLossParityLibopusFixture)$' \
-count=1 -timeout=10m
- name: Run native encoder fixture parity smoke
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=exhaustive GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^(TestEncoderCompliancePacketsFixtureCoverage|TestEncoderCompliancePacketsFixtureHonestyWithOpusDemo|TestEncoderCompliancePrecisionGuard|TestEncoderVariantsFixtureCoverage|TestEncoderVariantsFixtureSignalHash|TestEncoderVariantsFixtureHonestyWithOpusDemo)$' \
-count=1 -timeout=20m
- name: Run test suite
run: GOPUS_TEST_TIER=fast GOPUS_LIBOPUS_ORACLE=0 go test ./... -count=1 -timeout=25m
test-linux-arm64-fixtures:
name: test-linux-arm64-fixtures
needs:
- changes
runs-on: ubuntu-24.04-arm
timeout-minutes: 35
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Install codec tools (if missing)
run: |
if command -v ffmpeg >/dev/null 2>&1 && command -v opusdec >/dev/null 2>&1; then
echo "ffmpeg and opusdec already present; skipping apt install"
exit 0
fi
sudo apt-get update
sudo apt-get install -y --no-install-recommends ffmpeg opus-tools
- name: Bootstrap pinned libopus
run: make ensure-libopus
- name: Generate native libopus fixtures
run: make fixtures-gen-platform
- name: Run native decoder fixture parity smoke
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=parity GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^(TestDecoderParityLibopusMatrix|TestDecoderLossParityLibopusFixture)$' \
-count=1 -timeout=10m
- name: Run native encoder fixture parity smoke
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=exhaustive GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^(TestEncoderCompliancePacketsFixtureCoverage|TestEncoderCompliancePacketsFixtureHonestyWithOpusDemo|TestEncoderCompliancePrecisionGuard|TestEncoderVariantsFixtureCoverage|TestEncoderVariantsFixtureSignalHash|TestEncoderVariantsFixtureHonestyWithOpusDemo)$' \
-count=1 -timeout=20m
test-windows:
name: test-windows
needs:
- changes
runs-on: windows-latest
timeout-minutes: 45
env:
GOPUS_DISABLE_OPUSDEC: "1"
GOPUS_DISABLE_OPUSENC: "1"
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
cache: true
- name: Cache pinned libopus build
uses: actions/cache@v5
with:
path: |
tmp_check/opus-${{ env.LIBOPUS_VERSION }}
tmp_check/opus-${{ env.LIBOPUS_VERSION }}.tar.gz
key: libopus-${{ runner.os }}-${{ runner.arch }}-${{ env.LIBOPUS_VERSION }}-${{ hashFiles('tools/ensure_libopus.sh') }}
- name: Setup MSYS2 build tools
uses: msys2/setup-msys2@v2
with:
update: true
cache: false
path-type: inherit
install: >-
make
mingw-w64-x86_64-gcc
- name: Install ffmpeg
shell: pwsh
run: |
if (Get-Command ffmpeg -ErrorAction SilentlyContinue) {
Write-Host "ffmpeg already present; skipping chocolatey install"
exit 0
}
$installed = $false
for ($attempt = 1; $attempt -le 3; $attempt++) {
Write-Host "Installing ffmpeg via chocolatey (attempt $attempt/3)"
choco install -y ffmpeg
if ($LASTEXITCODE -eq 0 -and (Get-Command ffmpeg -ErrorAction SilentlyContinue)) {
$installed = $true
break
}
Start-Sleep -Seconds 20
}
if (-not $installed -and -not (Get-Command ffmpeg -ErrorAction SilentlyContinue)) {
Write-Warning "ffmpeg install unavailable (network/choco issue); continuing to test step."
Write-Warning "Windows test lane will still fail if ffmpeg is actually required."
}
exit 0
- name: Bootstrap pinned libopus
shell: msys2 {0}
run: make ensure-libopus
- name: Run core float libopus C-oracle parity gate
shell: msys2 {0}
run: make test-core-oracles-parity
# The tagged DRED/QEXT and fixed-point libopus C-oracle sweeps stay on the
# Linux and macOS lanes. They drive a large bash focus-gate matrix that is
# impractical to keep green under the MSYS2/mingw toolchain; the Windows
# lane still gates the core float C-oracle parity above plus the
# gopus_libopus_oracle decoder/encoder fixture parity below, all built
# against the native libopus C reference.
- name: Generate native libopus fixtures
shell: msys2 {0}
run: make fixtures-gen-platform
- name: Run native decoder fixture parity smoke
shell: msys2 {0}
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=parity GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^(TestDecoderParityLibopusMatrix|TestDecoderLossParityLibopusFixture)$' \
-count=1 -timeout=10m
- name: Run native encoder fixture parity smoke
shell: msys2 {0}
run: |
GOPUS_REQUIRE_PLATFORM_FIXTURES=1 GOPUS_TEST_TIER=exhaustive GOPUS_STRICT_LIBOPUS_REF=1 \
go test -tags gopus_libopus_oracle ./testvectors \
-run '^(TestEncoderCompliancePacketsFixtureCoverage|TestEncoderCompliancePacketsFixtureHonestyWithOpusDemo|TestEncoderCompliancePrecisionGuard|TestEncoderVariantsFixtureCoverage|TestEncoderVariantsFixtureSignalHash|TestEncoderVariantsFixtureHonestyWithOpusDemo)$' \
-count=1 -timeout=20m
- name: Run test suite
shell: msys2 {0}
run: GOPUS_TEST_TIER=fast GOPUS_LIBOPUS_ORACLE=0 go test ./... -count=1 -timeout=25m