Repository navigation
Workspaces phase 2j: what the fifth review of phase 2 found (#277) - #328
Merged
Merged
Conversation
- Slack roles from before 1.6 carry over for an agent of the default workspace only. Another workspace's admin sets their integration's signing secret, so they could name a legacy admin's Slack id and get a user with the admin role. - A streamed model answer is read guarded too (_GuardedStream): gemini and vertex_ai through LiteLLM, codestral and predibase send the request on the first read, after acompletion() returned. - create_agent and update_agent, run by an agent outside the default workspace, refuse platform-only features (features_added) and names with a code folder; every workspace checks is_agent_name. - A rename (update or rollback) moves the agent's rows to the new name (agent_cleanup.rename_agent_rows): links, settings, ratings, credentials, memory and conversations on both runtimes; ADK sessions are copied, their events moved, the old sessions deleted. - Ratings of an agent with no config count as the default workspace's, as in 1.x; the replay picker reads the spans that record mate.workspace.id. - may_run_code and the outbound checks share outbound.workspace_of_run; /gdrive/mcp uses pat_auth.is_platform_admin; type hints.
…side Default (#277) Rows an agent renamed under 1.x left under its old name belong to the default workspace. An agent of another workspace may not take such a name (DashboardServer._name_unavailable, agent_cleanup.left_behind): agent create and rename, import, clone, template import and sync, and the create_agent tool say "this name is taken". Ratings don't count (the eval pages keep them to their project), nor a trace that records its workspace; the default workspace takes the name as in 1.x.
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.
The fifth security review of phase 2 (
cb8a218..e194602, 2a–2i) found the paths below. Each new test inTestFifthReviewOfPhase2fails without its fix.Fixed
_carry_over_rolescopied every role of the legacyslack_<U>user,adminincluded, into the agent's workspace, whichever it was. Another workspace's admin sets the signing secret of their own integration, so they could sign an event naming a legacy admin's Slack id and get a user with the admin role. Roles now carry over only for an agent of the default workspace, where the old id lived; 1.x is unchanged. The 2h test now runs on workspace A.acompletion()has returned and the guard is off:gemini/andvertex_aithrough LiteLLM, codestral, predibase. LangGraph always streams.GuardedCompletionsnow returns a_GuardedStreamwhose__anext__/__next__also run guarded. LiteLLM callbacks would inherit the guard, but MATE registers none.create_agentandupdate_agentneed the admin role, but an agent outside the default workspace follows its workspace admin's instruction. A platform admin testing it could have been led to write${SECRET}into an MCP header. For an agent outside the default workspace:update_agentrefuses platform-only features (features_added);create_agentrefuses a name with a folder inagents/;is_agent_name.agent_cleanup.rename_agent_rows(agent update and rollback) moves every rowdelete_agent_rowswould remove, plus the ratings, to the new name. It first deletes rows a former agent left under the new name.mate.workspace.id, so the 2i check sees them.may_run_codeand the outbound checks shareoutbound.workspace_of_run./gdrive/mcpusespat_auth.is_platform_admin, which counts the built-in account.Not changed
delete_agent_rowsstill keeps logs, as decided for 1.6.Rows left by 1.x renames
Rows an agent renamed under 1.x left under its old name belong to the default workspace. An agent of another workspace may not take such a name (
DashboardServer._name_unavailable,agent_cleanup.left_behind).create_agenttool.Tests
test_client_contract.py: 12/12, unchanged.gen_docs.py --check: OK.Docs
Updated:
docs/dev/auth-and-access.md;docs/user/slack.md,agents.md;documents/design/2.0-plan.md.Listed by drift but still accurate:
docs/user/evals.md,sessions-and-traces.md,trace-replay.md: what the pages show, as described.docs/user/personal-access-tokens.md,docs/dev/openai-api-and-mcp.md,openai-compatibility.md:is_platform_adminis the same rule, moved into a function.docs/dev/mcp-servers.md: the 2i sentence on/gdrive/mcpholds.docs/user/triggers.md,docs/dev/trigger-engine.md,alerts.md,template-format.md: only type hints and the update helper changed.