Files
AnyImage/.github/workflows/release.yml
nan 2b3c0194a6
Some checks failed
Test / test (push) Failing after 46m18s
Add comprehensive tests for ONNX models and server jobs
- Introduced tests for the Moge3 ONNX model, including input validation, inference, and caching mechanisms.
- Added tests for ONNX runtime configurations and session management.
- Implemented tests for image upscaling functionality using ONNX models, ensuring proper handling of alpha channels and memory management.
- Created tests for panorama generation, verifying depth and visibility metrics.
- Developed tests for prediction artifacts, ensuring correct depth and normal data handling.
- Added server job tests for background removal and depth plane geometry generation, validating input handling and output correctness.
- Included environment tests to ensure proper dependency management and CI configurations.
2026-09-19 19:24:07 +08:00

71 lines
1.8 KiB
YAML

name: Release
on:
push:
tags:
# Publish on any tag starting with a `v`, e.g., v1.0.1
- "v*"
permissions:
contents: write
jobs:
check_version:
name: Check Version
runs-on: ubuntu-latest
outputs:
version: ${{ steps.read_version.outputs.version }}
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
python-version: "3.11"
- name: Check tag matches project version
id: read_version
run: |
version="$(uv run python -c "import tomllib; print(tomllib.load(open('pyproject.toml', 'rb'))['project']['version'])")"
if [ "v$version" != "$GITHUB_REF_NAME" ]; then
echo "Tag $GITHUB_REF_NAME does not match pyproject.toml version $version" >&2
exit 1
fi
echo "version=$version" >> "$GITHUB_OUTPUT"
build_extensions:
name: Build Extensions
needs: check_version
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Install uv
uses: astral-sh/setup-uv@v7
with:
python-version: "3.11"
- name: Run tests
run: uv run --group blender pytest tests/anyimage tests/tools
- name: Pack extensions
run: uv run pack
- name: Check extension archives
run: |
for platform in windows-x64 macos-arm64 linux-x64; do
archive="dist/AnyImage.v${{ needs.check_version.outputs.version }}.${platform}.zip"
if [ ! -f "$archive" ]; then
echo "Missing archive: $archive" >&2
exit 1
fi
done
- name: Publish release
uses: https://gitea.com/actions/gitea-release-action@v1.3.6
with:
files: |-
dist/*.zip