ci: run the Python SDK test suites on pull requests - #1418
Open
inahus99 wants to merge 1 commit into
Open
Conversation
The Python packages ship real test suites that nothing executes. `ci.yml` only covers TypeScript (Bun, turbo check-types, Biome), and the publish-*-python workflows publish to PyPI without running any tests, so these packages are released on the strength of local runs alone. Adds a path-filtered workflow covering the three packages whose suites currently pass: - agent-framework-python installs the package and runs pytest (54 tests) - cartesia-sdk-python and pipecat-sdk-python stub their heavy runtime dependencies at import time, so they run under unittest against the sources with nothing installed Python 3.10 is the lowest version these packages declare, so a change that only works on a newer interpreter fails here. `fail-fast` is disabled so one package failing still reports the others. openai-sdk-python is deliberately left out: its suite cannot be collected against current supermemory, which is issue supermemoryai#1235. It should be added here once that is fixed.
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.
Closes #1417.
What and why
The Python packages ship real test suites that nothing executes.
ci.ymlcovers only TypeScript (Bun,turbo run check-types, Biome), and the fourpublish-*-python.ymlworkflows publish to PyPI without running any tests. These packages are released on the strength of local runs alone.That gap is already live:
openai-sdk-pythonis broken onmainright now — its suite cannot be collected against the currentsupermemoryrelease (ImportError: cannot import name 'MemoryAddResponse'), which is #1235. Existing tests would have caught it at the breaking commit.The workflow
Path-filtered, so it only fires on PRs touching these packages or the workflow itself. Matrix over the three packages whose suites currently pass:
agent-framework-pythonpip install -e . pytest pytest-asyncio, thenpytestcartesia-sdk-pythonPYTHONPATH=src python -m unittest, no installpipecat-sdk-pythonPYTHONPATH=src python -m unittest, no installThe latter two stub their heavy runtime dependencies (
cartesia-line,pipecat-ai,loguru) at import time, so they need nothing installed and finish in well under a second. Onlyagent-framework-pythonpays an install cost.Two deliberate choices:
requires-python = ">=3.10", andagent-framework-coreagrees), so a change that only works on a newer interpreter fails here rather than at a user's install.fail-fast: false, so one package failing still reports the others instead of masking them.What is not included
openai-sdk-pythonis deliberately left out, because adding it would land this workflow red. It should be added as a fourth matrix entry once #1235 is fixed — that is a one-line change to this file, and I'm happy to follow up with it.Verification
All three commands run green against current
main: 54 passing foragent-framework-python, 1 each forcartesia-sdk-pythonandpipecat-sdk-python.Since this PR touches
.github/workflows/ci-python.yml, which is in its own path filter, the workflow runs against itself here — the checks on this PR are the real verification rather than my local runs.One note on scope: this only wires up the suites that exist.
cartesia-sdk-pythonandpipecat-sdk-pythonhave a single test each, so a green check on those means very little coverage today. Getting them running is the prerequisite for that being worth improving.