Skip to content

fix: E702 semicolon statements in video_mask_editor.py; bump 1.27.4 #8

fix: E702 semicolon statements in video_mask_editor.py; bump 1.27.4

fix: E702 semicolon statements in video_mask_editor.py; bump 1.27.4 #8

Workflow file for this run

name: Publish to Comfy Registry
on:
push:
tags: ["v*.*.*"]
workflow_dispatch:
inputs:
dry_run:
description: "Validate without publishing"
required: false
default: "false"
type: choice
options: ["false", "true"]
concurrency:
group: publish-${{ github.ref }}
cancel-in-progress: false
permissions:
contents: write
issues: write
env:
# Opt into Node.js 24 for actions to silence the Node 20 deprecation warning.
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"
jobs:
publish:
name: Publish to Comfy Registry
runs-on: ubuntu-latest
if: github.repository_owner == 'Code2Collapse'
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
cache: pip
- name: Install validation deps
run: pip install --upgrade pip tomli
- name: Validate pyproject for Comfy
shell: bash
run: |
python - <<'PY'
try:
import tomllib
except ModuleNotFoundError:
import tomli as tomllib
d = tomllib.load(open("pyproject.toml", "rb"))
p = d.get("project", {})
assert p.get("name"), "[project].name required"
assert p.get("version"), "[project].version required"
assert p.get("description"), "[project].description required"
tc = d.get("tool", {}).get("comfy", {})
assert tc.get("PublisherId"), "[tool.comfy].PublisherId required"
assert tc.get("DisplayName"), "[tool.comfy].DisplayName required"
print(f"OK: {p['name']} v{p['version']} (publisher={tc['PublisherId']})")
PY
- name: Generate changelog
id: changelog
shell: bash
run: |
prev=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || git rev-list --max-parents=0 HEAD | head -n1)
{
echo "log<<__END__"
git log --pretty='- %s (%h)' "${prev}..HEAD"
echo "__END__"
} >> "$GITHUB_OUTPUT"
- name: Publish (dry-run)
if: github.event.inputs.dry_run == 'true'
run: echo "DRY RUN - would publish $(grep '^version' pyproject.toml)"
- name: Publish to Comfy Registry
if: github.event.inputs.dry_run != 'true'
uses: Comfy-Org/publish-node-action@v1
with:
personal_access_token: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
- name: Create GitHub Release
if: startsWith(github.ref, 'refs/tags/') && github.event.inputs.dry_run != 'true'
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
name: Release ${{ github.ref_name }}
body: |
## Changes
${{ steps.changelog.outputs.log }}
generate_release_notes: true
- name: Open issue on failure
if: failure()
uses: actions/github-script@v7
with:
script: |
await github.rest.issues.create({
owner: context.repo.owner,
repo: context.repo.repo,
title: `Publish failed for ${context.ref}`,
body: `Workflow run: ${context.serverUrl}/${context.repo.owner}/${context.repo.repo}/actions/runs/${context.runId}`,
labels: ['ci-failure', 'publish']
});