Fix scoped session agent resolution#141
Merged
dubh3124 merged 2 commits intoJun 27, 2026
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
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.
Summary
GET /agents/{name}but rejected byPOST /sessionswithInvalid or unknown agent.effective_scopeinto sessionagent_namevalidation for both session creation and session update.POST /sessions, andPATCH /sessions/{id}.Root Cause
GET /agents/{name}resolved agents with request scope, butPOST /sessionsandPATCH /sessions/{id}calledconfig_store.is_valid_primary(agent_name)without scope. Scoped API-created agents therefore looked absent to session validation even though the agent API could read them.Validation
UV_CACHE_DIR=/tmp/uv-cache uv sync --all-extras --dev— passedUV_CACHE_DIR=/tmp/uv-cache uv run pytest tests/unit/test_rest_api.py::TestScopedSessionAgentName -q— passedUV_CACHE_DIR=/tmp/uv-cache uv run pytest tests/unit -q— 785 passed, 4 skippedUV_CACHE_DIR=/tmp/uv-cache uv run ruff check .— passedUV_CACHE_DIR=/tmp/uv-cache uv run mypy .— passedUV_CACHE_DIR=/tmp/uv-cache uv run mkdocs build --strict— passedgit diff --check— passedRelease Note
This is not included in the existing
v0.11.0-rc.2tag. It is marked as Unreleased until the next RC/final release tag is cut.