ci(python): run the agent-spec and claude-agent-sdk test suites - #2646
Open
BenTaylorDev wants to merge 1 commit into
Open
ci(python): run the agent-spec and claude-agent-sdk test suites#2646BenTaylorDev wants to merge 1 commit into
BenTaylorDev wants to merge 1 commit into
Conversation
unit-python-sdk.yml had a lane per python integration except these two. Both ship a tests/ directory (49 and 110 tests) and declare [tool.ag-ui.scripts] test, but nothing ran them: the generic `python` job only covers sdks/python, and the two packages appeared in `paths:` solely so the `lockfiles` job would verify their committed locks. A change to either package could go green without one of its tests executing. Adds a lane for each, copied from the langroid one, with pytest as the runner because both suites use pytest fixtures and pytest-asyncio. Drops the `paths:` comment that recorded the gap. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
| # in CI. Five of the 13 are stale today, which is why closing this needs its own | ||
| # change: freezing them as-is turns dojo-e2e red, and relocking all 13 | ||
| # pulls in dependency churn well beyond a toolchain pin. | ||
| agent-spec-python: |
| - name: Detect fork PR | ||
| id: fork-check | ||
| run: | | ||
| if [[ "${{ github.event_name }}" == "pull_request" && \ |
| id: fork-check | ||
| run: | | ||
| if [[ "${{ github.event_name }}" == "pull_request" && \ | ||
| "${GITHUB_EVENT_PULL_REQUEST_HEAD_REPO_FULL_NAME}" != "${{ github.repository }}" ]]; then |
| # reads as though the guard itself is broken, which is precisely the misleading | ||
| # signal action.yml's header argues against. | ||
| if: ${{ !cancelled() && steps.checkout.outcome == 'success' }} | ||
| uses: ./.github/actions/assert-lockfiles-unchanged |
| if: ${{ !cancelled() && steps.checkout.outcome == 'success' }} | ||
| uses: ./.github/actions/assert-lockfiles-unchanged | ||
|
|
||
| claude-agent-sdk-python: |
| - name: Detect fork PR | ||
| id: fork-check | ||
| run: | | ||
| if [[ "${{ github.event_name }}" == "pull_request" && \ |
| id: fork-check | ||
| run: | | ||
| if [[ "${{ github.event_name }}" == "pull_request" && \ | ||
| "${GITHUB_EVENT_PULL_REQUEST_HEAD_REPO_FULL_NAME}" != "${{ github.repository }}" ]]; then |
| # reads as though the guard itself is broken, which is precisely the misleading | ||
| # signal action.yml's header argues against. | ||
| if: ${{ !cancelled() && steps.checkout.outcome == 'success' }} | ||
| uses: ./.github/actions/assert-lockfiles-unchanged |
Contributor
Python Preview PackagesVersion
Install with uvAdd the TestPyPI index to your [[tool.uv.index]]
name = "testpypi"
url = "https://test.pypi.org/simple/"
explicit = trueThen install the packages you need: # Core SDK
uv add 'ag-ui-protocol==0.0.0.dev1788543641' --index testpypi
# Integrations (each already depends on the matching ag-ui-protocol preview)
uv add 'ag-ui-langgraph==0.0.0.dev1788543641' --index testpypi
uv add 'ag-ui-crewai==0.0.0.dev1788543641' --index testpypi
# NOTE: ag-ui-agent-spec depends on pyagentspec (git-only, not on PyPI).
# You will need to install pyagentspec separately from its git repo.
uv add 'ag-ui-agent-spec==0.0.0.dev1788543641' --index testpypi
uv add 'ag_ui_adk==0.0.0.dev1788543641' --index testpypi
uv add 'ag_ui_strands==0.0.0.dev1788543641' --index testpypiInstall with pippip install \
--index-url https://test.pypi.org/simple/ \
--extra-index-url https://pypi.org/simple/ \
ag-ui-protocol==0.0.0.dev1788543641
Commit: d215f3c |
@ag-ui/a2a-middleware
@ag-ui/a2ui-middleware
@ag-ui/event-throttle-middleware
@ag-ui/mcp-apps-middleware
@ag-ui/mcp-middleware
@ag-ui/a2a
@ag-ui/adk
@ag-ui/ag2
@ag-ui/agno
@ag-ui/aws-strands
@ag-ui/claude-agent-sdk
@ag-ui/claude-managed-agents
@ag-ui/crewai
@ag-ui/langchain
@ag-ui/langgraph
@ag-ui/llamaindex
@ag-ui/mastra
@ag-ui/pydantic-ai
@ag-ui/vercel-ai-sdk
@ag-ui/watsonx
@ag-ui/a2ui-toolkit
create-ag-ui-app
@ag-ui/client
@ag-ui/core
@ag-ui/encoder
@ag-ui/proto
commit: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to the CI coverage note in #2645.
Problem
unit-python-sdk.ymlhas a lane per python integration — langgraph, watsonx, adk-middleware, aws-strands, langroid, crew-ai, claude-managed-agents — except two.integrations/agent-spec/pythonandintegrations/claude-agent-sdk/pythonship atests/directory (49 and 110 tests today) and declare[tool.ag-ui.scripts] test = "python -m pytest", but nothing ran them:pythonjob only runssdks/python;paths:solely so thelockfilesjob would verify their committed locks, which the comment there recorded: "agent-spec and claude-agent-sdk have no test lane, but they ship committed lockfiles that thelockfilesjob below verifies."So a change to either package could go green with none of its tests executing.
Change
One lane per package, copied verbatim from the
langroid-pythonlane — same pinnedactions/checkout,setup-uvandactions/cacherefs, same fork-PR cache-key prefix, sameuv sync --locked, sameassert-lockfiles-unchangedguard. The runner ispython -m pytest tests/ -vrather thanunittest discover, because both suites use pytest fixtures andpytest-asyncio; this matches thecrewai-pythonandclaude-managed-agents-pythonlanes.The
paths:comment recording the gap is removed. The two path entries stay, so the new lanes trigger on changes to either package.Testing
Ran the exact CI commands locally in a clean worktree at
origin/main:--locked(not--frozen) is what the other lanes use, and it passes for both, so neither lock is stale.git statusstayed clean afterwards, so neither install rewrites a lockfile and theassert-lockfiles-unchangedguard has nothing to trip on.Workflow checks that cover this file, run locally:
The pin script's counts include the two invocations this PR adds.
Note for a maintainer
The two new checks,
agent-spec-pythonandclaude-agent-sdk-python, are not in branch protection's required list. They will report on PRs but not block until someone adds them.🤖 Generated with Claude Code