Files
elizaos--eliza/.github/workflows/test-packaging.yml
T
wehub-resource-sync 426e9eeabd
Benchmark Bridge Tests / benchmark (bunx @biomejs/biome check packages/lifeops-bench/src, benchmark-lint) (push) Waiting to run
Benchmark Bridge Tests / benchmark (bunx vitest run --config packages/lifeops-bench/vitest.config.ts --root packages/lifeops-bench --passWithNoTests, benchmark-tests) (push) Waiting to run
Build Agent Image / build-and-push (push) Waiting to run
Chat shell gestures / Chat shell gesture + parity e2e (push) Waiting to run
ci / test (push) Waiting to run
ci / lint-and-format (push) Waiting to run
ci / build (push) Waiting to run
ci / dev-startup (push) Waiting to run
Cloud Gateway Discord / Test (push) Waiting to run
Cloud Gateway Webhook / Test (push) Waiting to run
Cloud Tests / lint-and-types (push) Waiting to run
Cloud Tests / unit-tests (push) Waiting to run
Cloud Tests / integration-tests (push) Waiting to run
Cloud Tests / e2e-tests (push) Blocked by required conditions
CodeQL Advanced / Analyze (javascript-typescript) (push) Waiting to run
Deploy Apps Worker (Product 2) / Determine environment (push) Waiting to run
Deploy Apps Worker (Product 2) / Deploy apps worker to apps-control host (${{ needs.determine-env.outputs.environment }}) (push) Blocked by required conditions
Deploy Eliza Provisioning Worker / Determine environment (push) Waiting to run
Deploy Eliza Provisioning Worker / Deploy worker to Hetzner host (${{ needs.determine-env.outputs.environment }} @ ${{ needs.determine-env.outputs.deployment_sha }}) (push) Blocked by required conditions
Dev Smoke / Classify changed paths (push) Waiting to run
Dev Smoke / bun run dev onboarding chat (push) Blocked by required conditions
Dev Smoke / Vite HMR dependency-level smoke (push) Blocked by required conditions
Electrobun Submodule Guard / electrobun gitlink is fetchable (push) Waiting to run
gitleaks / gitleaks (push) Waiting to run
Markdown Links / Relative Markdown Links (push) Waiting to run
Publish @elizaos/example-code / check_npm (push) Waiting to run
Publish @elizaos/example-code / publish_npm (push) Blocked by required conditions
Publish @elizaos/plugin-elizacloud / verify_version (push) Waiting to run
Publish @elizaos/plugin-elizacloud / publish_npm (push) Blocked by required conditions
Quality (Extended) / Homepage Build (PR smoke) (push) Waiting to run
Quality (Extended) / Comment-only diff guard (push) Waiting to run
Quality (Extended) / Format + Type Safety Ratchet (push) Waiting to run
Quality (Extended) / Develop Gate (secret scan + UI determinism) (push) Waiting to run
Quality (Extended) / Develop Gate (lint) (push) Waiting to run
Sandbox Live Smoke / Sandbox live smoke (push) Waiting to run
Snap Build & Test / Build Snap (amd64) (push) Waiting to run
Snap Build & Test / Build Snap (arm64) (push) Waiting to run
supply-chain / sbom (push) Waiting to run
supply-chain / vulnerability-scan (push) Waiting to run
Build, Push & Deploy to Phala Cloud / build-and-push (push) Waiting to run
Test Packaging / Validate Packaging Configs (push) Waiting to run
Test Packaging / PyPI on Python ${{ matrix.python }} (push) Waiting to run
Test Packaging / Pack & Test JS Tarballs (push) Waiting to run
Test Packaging / elizaos CLI global-install smoke (node + bun) (push) Waiting to run
UI Fixture E2E / ui-fixture-e2e (push) Waiting to run
UI Fixture E2E / fixture-e2e (push) Waiting to run
UI Story Gate / story-gate (push) Waiting to run
vault-ci / test (macos-latest) (push) Waiting to run
vault-ci / test (ubuntu-latest) (push) Waiting to run
vault-ci / test (windows-latest) (push) Waiting to run
vault-ci / app-core wiring tests (push) Waiting to run
verify-patches / verify patches/CHECKSUMS.sha256 (push) Waiting to run
Voice Benchmark Smoke / voice-emotion fixture smoke (push) Waiting to run
Voice Benchmark Smoke / voiceagentbench fixture smoke (push) Waiting to run
Voice Benchmark Smoke / voicebench-quality unit smoke (push) Waiting to run
Voice Benchmark Smoke / voicebench TypeScript unit (no audio) (push) Waiting to run
Voice Benchmark Smoke / voice bench smoke summary (push) Blocked by required conditions
Windows CI / windows ([bun run --cwd packages/app-core test bun run --cwd packages/elizaos test bun run --cwd packages/cloud/shared test], app-and-cli) (push) Waiting to run
Windows CI / windows ([bun run --cwd packages/scenario-runner test bun run --cwd packages/vault test bun run --cwd packages/security test bun run --cwd plugins/plugin-coding-tools test], framework-packages) (push) Waiting to run
Windows CI / windows ([bun run --cwd plugins/plugin-elizacloud test bun run --cwd plugins/plugin-discord test bun run --cwd plugins/plugin-anthropic test bun run --cwd plugins/plugin-openai test bun run --cwd plugins/plugin-app-control test bun run --cwd plugins/pl… (push) Waiting to run
Windows CI / windows ([node packages/scripts/run-turbo.mjs run build --filter=@elizaos/core --filter=@elizaos/shared --filter=@elizaos/agent --concurrency=4 node packages/scripts/run-bash-linux-only.mjs scripts/verify-riscv64-buildpaths.sh node packages/scripts/run… (push) Waiting to run
Windows CI / windows ([node packages/scripts/run-turbo.mjs run typecheck --filter=@elizaos/core --filter=@elizaos/shared --filter=@elizaos/cloud-shared --concurrency=4 bun run --cwd packages/core test bun run --cwd packages/shared test], core-runtime, 75) (push) Waiting to run
Test Packaging / Build & Test PyPI Package (push) Waiting to run
Voice Workbench / headless workbench (mocked backends) (push) Has been cancelled
Voice Workbench / real acoustic lane (nightly, provisioned only) (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:43:05 +08:00

313 lines
11 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
name: Test Packaging
on:
pull_request:
branches: [main]
paths:
- 'packages/app-core/packaging/**'
- 'packages/core/**'
- 'plugins/*/typescript/**'
- 'packages/app-core/scripts/pack-upstreams.mjs'
- 'packages/elizaos/**'
- '.github/workflows/publish-packages.yml'
- '.github/workflows/test-packaging.yml'
push:
branches: [main]
paths:
- 'packages/app-core/packaging/**'
- 'packages/core/**'
- 'plugins/*/typescript/**'
- 'packages/elizaos/**'
workflow_dispatch:
concurrency:
group: test-packaging-${{ github.ref }}
cancel-in-progress: true
# Default to least privilege. Override per-job where needed.
permissions:
contents: read
jobs:
validate:
name: Validate Packaging Configs
runs-on: ${{ fromJSON(vars.HETZNER_FLEET_ONLINE == 'false' && '["ubuntu-24.04"]' || '["self-hosted","hetzner-robot"]') }}
steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5
with:
# Packaging validation checks source packaging metadata only; native
# inference submodules are validated by dedicated native workflows.
submodules: false
- name: Setup Python
uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1
with:
python-version: "3.14"
- name: Setup Node.js
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version: "24"
check-latest: false
- name: Install validation dependencies
run: pip install pyyaml build twine
- name: Run packaging validation suite
run: bash packages/app-core/packaging/test-packaging.sh
build-pypi:
name: Build & Test PyPI Package
runs-on: ${{ fromJSON(vars.HETZNER_FLEET_ONLINE == 'false' && '["ubuntu-24.04"]' || '["self-hosted","hetzner-robot"]') }}
steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5
with:
# PyPI packaging does not need native inference submodules.
submodules: false
- name: Check for PyPI package directory
id: pypi_check
run: |
if [[ -d packages/app-core/packaging/pypi ]]; then
echo "present=true" >> "$GITHUB_OUTPUT"
else
echo "present=false" >> "$GITHUB_OUTPUT"
echo "::notice::packages/app-core/packaging/pypi not present in this branch — skipping PyPI build"
fi
- name: Setup Python
if: steps.pypi_check.outputs.present == 'true'
uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1
with:
python-version: "3.14"
- name: Setup Node.js
if: steps.pypi_check.outputs.present == 'true'
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version: "24"
check-latest: false
- name: Build
if: steps.pypi_check.outputs.present == 'true'
working-directory: packages/app-core/packaging/pypi
run: |
pip install build
python -m build
- name: Check dist
if: steps.pypi_check.outputs.present == 'true'
working-directory: packages/app-core/packaging/pypi
run: |
pip install twine
twine check dist/*
- name: Install and test
if: steps.pypi_check.outputs.present == 'true'
working-directory: packages/app-core/packaging/pypi
run: |
pip install dist/*.whl
# Module import test
python -c "
import elizaos_app
print(f'elizaos_app {elizaos_app.__version__}')
assert elizaos_app.__version__
assert hasattr(elizaos_app, 'run')
assert hasattr(elizaos_app, 'ensure_runtime')
assert hasattr(elizaos_app, 'get_version')
"
# Loader unit tests
python -c "
from elizaos_app.loader import (
_parse_version,
_find_node,
_get_node_version,
_check_node,
ElizaOSAppError,
NodeNotFoundError,
RuntimeInstallError,
)
# Version parsing
assert _parse_version('v22.12.0') == (22, 12, 0)
assert _parse_version('v18.0.0') == (18, 0, 0)
assert _parse_version('v1.2.3-nightly') == (1, 2, 3)
assert _parse_version('not-a-version') is None
assert _parse_version('') is None
# Node detection (Node.js is installed in this runner)
node = _find_node()
assert node, 'Node not found on PATH'
ver = _get_node_version(node)
assert ver and ver >= (22, 0, 0), f'Node version too old: {ver}'
checked = _check_node()
assert checked == node
# Exception hierarchy
assert issubclass(NodeNotFoundError, ElizaOSAppError)
assert issubclass(RuntimeInstallError, ElizaOSAppError)
print('All loader unit tests passed')
"
# CLI entry point exists
which elizaos-app
build-pypi-matrix:
name: PyPI on Python ${{ matrix.python }}
runs-on: ${{ fromJSON(vars.HETZNER_FLEET_ONLINE == 'false' && '["ubuntu-24.04"]' || '["self-hosted","hetzner-robot"]') }}
strategy:
matrix:
# PRs run a single Python version; pushes to main/develop run the
# full 3.93.13 matrix. Release publishing re-runs the full matrix.
python: ${{ github.event_name == 'pull_request' && fromJSON('["3.12"]') || fromJSON('["3.9", "3.10", "3.11", "3.12", "3.13"]') }}
steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5
with:
# PyPI packaging does not need native inference submodules.
submodules: false
- name: Check for PyPI package directory
id: pypi_check
run: |
if [[ -d packages/app-core/packaging/pypi ]]; then
echo "present=true" >> "$GITHUB_OUTPUT"
else
echo "present=false" >> "$GITHUB_OUTPUT"
echo "::notice::packages/app-core/packaging/pypi not present in this branch — skipping PyPI matrix build"
fi
- name: Setup Python ${{ matrix.python }}
if: steps.pypi_check.outputs.present == 'true'
uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1
with:
python-version: ${{ matrix.python }}
- name: Setup Node.js
if: steps.pypi_check.outputs.present == 'true'
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version: "24"
check-latest: false
- name: Build and test
if: steps.pypi_check.outputs.present == 'true'
working-directory: packages/app-core/packaging/pypi
run: |
pip install build
python -m build
pip install dist/*.whl
python -c "import elizaos_app; print(f'OK: elizaos_app {elizaos_app.__version__} on Python ${{ matrix.python }}')"
pack-and-test-js:
name: Pack & Test JS Tarballs
runs-on: ${{ fromJSON(vars.HETZNER_FLEET_ONLINE == 'false' && '["ubuntu-24.04"]' || '["self-hosted","hetzner-robot"]') }}
steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5
with:
# JS tarball packaging does not need native inference submodules.
submodules: false
- name: Setup Node.js
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version: "24"
check-latest: false
- name: Setup Bun
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6
with:
bun-version: "canary"
- name: Install dependencies
run: bun install --ignore-scripts
- name: Materialize bun npm package binary
run: if [ -f node_modules/bun/install.js ]; then (cd node_modules/bun && node install.js); fi
- name: Pack upstream tarballs
run: node packages/app-core/scripts/pack-upstreams.mjs
- name: Verify tarball installation
run: |
set -euo pipefail
ARTIFACTS_DIR="artifacts"
tarballs=("$ARTIFACTS_DIR"/*.tgz)
if [ ! -f "${tarballs[0]}" ]; then
echo "::error::No tarballs found in $ARTIFACTS_DIR"
exit 1
fi
TEST_DIR=$(mktemp -d)
ROOT_DIR="$PWD"
install_paths=()
for tarball in "${tarballs[@]}"; do
install_paths+=("$ROOT_DIR/$tarball")
done
cd "$TEST_DIR"
echo '{"name":"tarball-test","private":true,"type":"module"}' > package.json
npm install "${install_paths[@]}" --ignore-scripts 2>&1
for tarball in "${tarballs[@]}"; do
echo "::group::Checking $(basename "$tarball")"
PKG_NAME=$(tar -xOf "$ROOT_DIR/$tarball" package/package.json | node -e "process.stdin.setEncoding('utf8'); let data = ''; process.stdin.on('data', chunk => data += chunk); process.stdin.on('end', () => console.log(JSON.parse(data).name));")
PKG_MANIFEST="node_modules/${PKG_NAME}/package.json"
test -f "$PKG_MANIFEST"
echo "Installed: $PKG_NAME"
echo "::endgroup::"
done
cd "$ROOT_DIR"
node packages/scripts/rm-path-recursive.mjs "$TEST_DIR"
echo "All JS tarballs passed installation test"
- name: Upload tarball artifacts
if: always()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a
with:
name: js-tarballs
path: artifacts/*.tgz
retention-days: 7
elizaos-cli-global-smoke:
name: elizaos CLI global-install smoke (node + bun)
runs-on: ${{ fromJSON(vars.HETZNER_FLEET_ONLINE == 'false' && '["ubuntu-24.04"]' || '["self-hosted","hetzner-robot"]') }}
steps:
- name: Checkout
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5
with:
submodules: false
- name: Setup Node.js
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version: "24"
check-latest: false
- name: Setup Bun
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6
with:
bun-version: "canary"
- name: Install dependencies
run: bun install --ignore-scripts
- name: Materialize bun npm package binary
run: if [ -f node_modules/bun/install.js ]; then (cd node_modules/bun && node install.js); fi
# Static guard for #8000: a bin file must not import a dependency subpath
# that the dependency's exports map forbids.
- name: Lint bin exports (#8000 static guard)
run: bun run --cwd packages/elizaos lint:bin-exports
# End-to-end guard for #8000: npm pack -> global install (sandboxed
# --prefix) under npm and bun, then run the bin under both node and bun.
- name: Packaged smoke (global + local install, node + bun)
run: bun run --cwd packages/elizaos test:packaged