Split the final metadata-action step into PR, main, and semver-specific blocks so each
event only generates the appropriate tags. This prevents PR runs from pushing
`latest` or semver tags, ensuring the publish job creates multi-arch manifests
only for the tags intended for that event.
Updated the manifest creation and inspection steps to loop over metadata-action's `.tags[]`
directly and use the full tag references as-is. The previous version attempted to prefix
tags with the image name, which produced invalid references (e.g. image:image:tag). Using
the full tags emitted by metadata-action ensures correct manifest creation for PR tags,
SHA tags, semver tags, and latest.
Refactored the reusable Docker publish workflow to generate proper multi-architecture images.
Each platform build now pushes by digest and uploads its digest as an artifact, and a final job
assembles the multi-arch manifest from those digests.
* Sort imports alphabetically in agent loops __init__.py
Fix isort check failure by alphabetically sorting both the import list
and __all__ list to match the expected order.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* run on all prs
* Fix black formatting issues in responses.py and provider.py
Apply black formatting to fix lint check failures:
- Reformat conditional expression in responses.py for better readability
- Break long assert line in provider.py to comply with line length limits
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* Fix prettier formatting issues in markdown and TypeScript files
Apply prettier formatting to blog posts, documentation, and CLI code:
- Format blog markdown files for consistent styling
- Format TypeScript CLI source files
- Format documentation MDX files
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
---------
Co-authored-by: Claude <noreply@anthropic.com>
When bumping cua-computer, we publish both packages. However, since cua-agent
depends on cua-computer, we should publish computer FIRST, then agent. This
ensures the new computer version is available on PyPI before agent (which
depends on it) is published.
Changes:
- Reordered jobs: publish-computer before publish-agent
- Added publish-computer to publish-agent's needs list
- Updated publish-agent condition to use always() with explicit result checks
- When service is cua-agent: publishes immediately
- When service is cua-computer: waits for publish-computer to succeed first
Job execution order:
1. bump-version (bumps versions, pushes to git)
2. publish-computer (only when service == cua-computer)
3. publish-agent (waits for computer if service == cua-computer)
This prevents dependency errors where agent might be published before the
computer version it depends on is available on PyPI.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
This PR addresses two issues:
1. **Fix version detection in pypi-publish-computer workflow**
- Updated to match the pattern from PR #598 for pypi-publish-agent
- Check inputs.version first (works for workflow_call regardless of event_name)
- Add debug output to help troubleshoot version detection issues
- Proper handling of all three trigger types: workflow_call, workflow_dispatch, push
2. **Publish both packages when bumping cua-computer**
- When bumping cua-computer, we bump both cua-computer and cua-agent versions
(since cua-agent depends on cua-computer: "cua-computer>=0.4.0,<0.5.0")
- Updated publish-agent job to trigger for both 'cua-agent' and 'cua-computer' services
- This ensures version consistency between the two packages
**Behavior:**
- When bumping `cua-agent`: publishes cua-agent only
- When bumping `cua-computer`: publishes BOTH cua-computer AND cua-agent
This maintains version consistency and ensures users can install the latest
versions of both packages together without dependency conflicts.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
When bumping cua-computer, the workflow was incorrectly publishing cua-agent
instead of cua-computer to PyPI. This was because the publish-agent job had a
condition that triggered for both cua-agent and cua-computer services.
Changes:
- Added computer_version output to capture the bumped computer version
- Changed publish-agent condition to only trigger for cua-agent service
- Added new publish-computer job that triggers for cua-computer service
- publish-computer job calls pypi-publish-computer.yml workflow
Now when bumping cua-computer:
- Bumps cua-computer version (as before)
- Also bumps cua-agent version to maintain dependency sync (as before)
- Publishes cua-computer to PyPI (fixed!)
- Does NOT publish cua-agent to PyPI (fixed!)
Fixes: https://github.com/trycua/cua/actions/runs/19512484987🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Clean up all debug output added during investigation:
1. bump-version.yml:
- Removed "Verify agent version output" debug step
- Kept essential "Agent version: X.X.X" output
2. pypi-publish-agent.yml:
- Removed extensive "Version Determination Debug" output
- Simplified to show only "Agent version: X.X.X"
- Kept error messages for production debugging
- Removed "Verify prepare job outputs" debug step
3. pypi-reusable-publish.yml:
- Removed all debug output from "Verify version consistency"
- Kept the core version validation logic
- Script errors will still be visible if check fails
All workflows now have clean, production-ready logging while
maintaining the fixes from PR #598.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
The bug: When pypi-publish-agent is called via workflow_call from
bump-version, github.event_name is "workflow_dispatch" (inherited
from parent), NOT "workflow_call". This caused the code to check
github.event.inputs.version (empty) instead of inputs.version (0.4.44).
The fix: Check inputs.version first, before checking event_name.
This works correctly for:
- workflow_call: uses inputs.version
- Tag push: extracts from tag
- workflow_dispatch with version param: uses inputs.version
- workflow_dispatch event UI: uses event.inputs.version
Debug output showed:
- Event name: workflow_dispatch
- Input version: 0.4.44 (correct!)
- Workflow dispatch version: (empty)
- Final VERSION= (bug - used wrong source)
Now it will use inputs.version first, giving VERSION=0.4.44.
Fixes: https://github.com/trycua/cua/actions/runs/19483269380🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Added debug logging at every stage of version passing to identify
where the version parameter is being lost:
1. bump-version job: Verify agent_version output is set correctly
2. pypi-publish-agent prepare job: Show inputs.version and verify
the get-version step output
3. pypi-reusable-publish: Already has debug showing empty version
Debug output will show:
- Event name and workflow trigger type
- Input version values at each stage
- Step output values
- Final version passed to reusable workflow
This will pinpoint exactly where the version parameter becomes empty
in the workflow_call chain.
Related: Previous debug showed "Expected version: " (empty)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Added comprehensive debugging to diagnose why get_pyproject_version.py
is not receiving arguments correctly after git reset.
Changes:
- Added debug output showing current directory, GITHUB_WORKSPACE, and paths
- Changed pyproject.toml path to use absolute path with GITHUB_WORKSPACE
- Added ls commands to verify files exist before running script
- This will help identify if the git reset is affecting path resolution
The error shows the script's usage message, indicating arguments
aren't being passed correctly. The debug output will reveal why.
Related: https://github.com/trycua/cua/actions/runs/19482970320🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Add explicit git fetch and reset after checkout to guarantee
workflows get the most recent main branch commits, including
version bumps pushed by the bump-version workflow.
The issue: When using workflow_call, even with ref: main, GitHub
Actions may use a cached repository state from workflow run start.
This caused version consistency checks to fail because the checkout
didn't include the just-pushed version bump.
Solution: After checkout, explicitly fetch and reset to origin/main
to ensure we have the absolute latest code. Added logging to show
the current commit for debugging.
Fixes: https://github.com/trycua/cua/actions/runs/19482970320🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Ensure publish workflows check out the main branch to get the
latest bumped version after the bump-version workflow pushes changes.
Previously, workflows were checking out the SHA at trigger time,
which didn't include the version bump committed by bump-version job.
This fixes the "Verify version consistency" step failure where the
expected version didn't match the pyproject.toml version.
Related to: https://github.com/trycua/cua/actions/runs/19482814921🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Replace heredoc-based Python script with inline command to fix
exit code 2 error in the "Capture bumped agent version" step.
The heredoc syntax with indented EOF marker was causing issues
in GitHub Actions. Simplified to a single-line Python command.
Fixes: https://github.com/trycua/cua/actions/runs/19482457144🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>