Skip to content

feat(projects): record the pull requests a project member opens - #6922

Merged
enyst merged 253 commits into
mainfrom
claude/project-thread-mcp0in
Nov 21, 2026
Merged

enyst merged 253 commits into
mainfrom
claude/project-thread-mcp0in

Conversation

@enyst

@enyst enyst commented Nov 17, 2026 •

Copy link
Copy Markdown
Member

HUMAN:
In a different tab on the right side, this is what could be, as inspiration. wdyt?


AGENT:

Requested by Engel · project thread

The server side of the Projects sidebar and Project tab in Canvas (OpenHands/OpenHands#19810, stacked on OpenHands/OpenHands#19495): each project conversation lists the pull requests its agent opened.

Why

In a project, the user needs to see which pull requests each conversation opened without opening each one. The board listing reads only the conversation catalog, so this has to be a tag the server writes as events arrive.

Summary

  • The turn tracker (project_turns.py) reports PullRequestsOpened(refs) when a tool call that opens a pull request returns. A call counts when it runs gh pr create in a shell command or is a tool named create_pull_request (the GitHub MCP server's). The URL is read from that call's own result, so viewing other PRs does not count.
  • The board (project_board.py) adds the refs to a prs tag on project members, while Projects is on: comma-separated owner/repo#number, oldest first, each once, the oldest dropping off when the list outgrows a tag value. It is server-owned (RESERVED_TAG_KEYS) and kept across turns.
  • GET /api/projects/{id}/conversations returns it as pull_requests: [{owner, repo, number}], and the TypeScript ProjectsClient types follow. PR state and checks stay on GET /api/git/repositories/{owner}/{repo}/pull-requests/{number}.

No event-log reads: the tracker only sees events as they are published and remembers PR-opening call ids until their result arrives.

Issue Number

Part of #6637 (Projects in the Agent Server).

How to Test

uv run pytest tests/agent_server/test_project_board.py tests/agent_server/test_project_cards.py tests/agent_server/test_projects_router.py
uv run ruff check openhands-agent-server && uv run pyright openhands-agent-server/openhands/agent_server/project_turns.py openhands-agent-server/openhands/agent_server/project_board.py
  • test_project_board.py: the tracker's PullRequestsOpened signal; PRs recorded from gh pr create results only (a gh pr view URL is not), duplicates once, non-members untouched, a full tag drops the oldest, prs is reserved.
  • test_projects_router.py: the board returns parsed pull_requests, skipping malformed refs.

Live: an Agent Server from this branch with Canvas OpenHands/OpenHands#19810 and DeepSeek. A coordinator started three workers, and gh pr create results (a demo stub printing real PR URLs) showed up as PR chips with state from the real GitHub API. Screenshots are in OpenHands/OpenHands#19810 under .pr/projects-panel/.


Generated by Claude Code


🐳 Agent Server images for this PR — GHCR package, pull/run commands, and all pushed tags (click to expand)

• GHCR package: https://github.com/OpenHands/agent-sdk/pkgs/container/agent-server

Variants & Base Images

Variant Architectures Base Image Docs / Tags
java amd64, arm64 eclipse-temurin:17-jdk Link
python-slim amd64, arm64 python-node-runtime Link
python-minimal amd64, arm64 python-node-runtime Link
python amd64, arm64 python-node-runtime Link
golang amd64, arm64 golang:1.21-bookworm Link

Pull (multi-arch manifest)

# Each variant is a multi-arch manifest supporting both amd64 and arm64
docker pull ghcr.io/openhands/agent-server:57cdee9-python

Run

docker run -it --rm \
  -p 8000:8000 \
  --name agent-server-57cdee9-python \
  ghcr.io/openhands/agent-server:57cdee9-python

All tags pushed for this build

ghcr.io/openhands/agent-server:57cdee9-golang-amd64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-golang-amd64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-golang-amd64
ghcr.io/openhands/agent-server:57cdee9-golang_tag_1.21-bookworm-amd64
ghcr.io/openhands/agent-server:57cdee9-golang-arm64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-golang-arm64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-golang-arm64
ghcr.io/openhands/agent-server:57cdee9-golang_tag_1.21-bookworm-arm64
ghcr.io/openhands/agent-server:57cdee9-java-amd64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-java-amd64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-java-amd64
ghcr.io/openhands/agent-server:57cdee9-eclipse-temurin_tag_17-jdk-amd64
ghcr.io/openhands/agent-server:57cdee9-java-arm64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-java-arm64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-java-arm64
ghcr.io/openhands/agent-server:57cdee9-eclipse-temurin_tag_17-jdk-arm64
ghcr.io/openhands/agent-server:57cdee9-python-amd64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-amd64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-amd64
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-amd64
ghcr.io/openhands/agent-server:57cdee9-python-arm64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-arm64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-arm64
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-arm64
ghcr.io/openhands/agent-server:57cdee9-python-minimal-amd64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-minimal-amd64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-minimal-amd64
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-minimal-amd64
ghcr.io/openhands/agent-server:57cdee9-python-minimal-arm64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-minimal-arm64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-minimal-arm64
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-minimal-arm64
ghcr.io/openhands/agent-server:57cdee9-python-slim-amd64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-slim-amd64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-slim-amd64
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-slim-amd64
ghcr.io/openhands/agent-server:57cdee9-python-slim-arm64
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-slim-arm64
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-slim-arm64
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-slim-arm64
ghcr.io/openhands/agent-server:57cdee9-golang
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-golang
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-golang
ghcr.io/openhands/agent-server:57cdee9-golang_tag_1.21-bookworm
ghcr.io/openhands/agent-server:57cdee9-java
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-java
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-java
ghcr.io/openhands/agent-server:57cdee9-eclipse-temurin_tag_17-jdk
ghcr.io/openhands/agent-server:57cdee9-python-minimal
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-minimal
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-minimal
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-minimal
ghcr.io/openhands/agent-server:57cdee9-python-slim
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python-slim
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python-slim
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime-slim
ghcr.io/openhands/agent-server:57cdee9-python
ghcr.io/openhands/agent-server:57cdee9ad21bffd12508e95f3237ecf427078aab-python
ghcr.io/openhands/agent-server:claude-project-thread-mcp0in-python
ghcr.io/openhands/agent-server:57cdee9-python-node-runtime

About Multi-Architecture Support

  • Each variant tag (e.g., 57cdee9-python) is a multi-arch manifest supporting both amd64 and arm64
  • Docker automatically pulls the correct architecture for your platform
  • Individual architecture tags (e.g., 57cdee9-python-amd64) are also available if needed

claude added 30 commits November 7, 2026 15:19
A finished run tags its conversation with how the agent's last message
ended (turn=asked|answered) and, when the critic scored it at least 0.9,
resolved=auto. A new user message removes both. The project threads list
uses them for needs_input and resolved groups and reports automation_id.
Children no longer copy their parent's resolved/turn tags.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Projects keep artifacts, the files they produce or are given that do not
belong in a source repository, under the persistence dir. Routes list,
upload, download and delete them, and copy a file from a member
conversation's workspace (paths, symlinks included, must stay inside it).
The save_project_artifact tool lets an agent save its deliverables there.
Deleting a project deletes its artifacts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Open workspace files without following a final symlink or blocking on a
FIFO, in a worker thread, and check the opened file again. Match artifact
names in full (no trailing newline), refuse trailing dots or spaces,
Windows device names and names differing only in case, and serialize
saves and deletes per project. Refuse an oversized upload before copying
it. List a running thread as working even if it is still tagged resolved,
and skip tag writes a user message does not need.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
A Stop hook that denies stopping on a plain message makes the agent go
on to a finish that may not repeat its question. Once the agent stops on
a question, keep turn=asked until the next user message.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
The Resolve button can mark conversations outside a project too, so a
new user message clears resolved/turn wherever they are set. Recording
outcomes stays limited to project members.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
GET /api/conversations/{id} took tags from base_state.json, which a
running conversation saves only when its run releases the state lock, so
a tag PATCH (for example resolving a running thread) stayed invisible
until the run ended. Read tags from meta.json, which the PATCH writes
first and the catalog already uses.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
…-xwkk9b

# Conflicts:
#	.agents/skills/verify-agent-server/references/feature-map/README.md
OpenHands calls these conversations. Routes move to
/api/projects/{id}/conversations, the list field is `conversations`, the
models are ProjectConversation*, and the coordinator tools are
list_project_conversations and message_project_conversation.
THREAD_STATE_TAG_KEYS becomes BOARD_TAG_KEYS and ThreadOutcomeSubscriber
becomes ConversationOutcomeSubscriber.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
A message one project conversation sends another (the coordinator's
message_project_conversation, or POST .../messages with
sender_conversation_id) now records sender="conversation:<id hex>" and
opens with a line telling the receiving agent who sent it and that it
approves nothing on the person's behalf. A child started by a project
member gets a system-prompt note naming the conversation that started it,
and its task message records that parent as sender.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
A ReactionEvent (target_event_id, emoji, removed, source) records an emoji
on a message; it never reaches the LLM. Agents react with the new react and
unreact tools (openhands.tools.reaction), which default to the person's
latest message. The executor only reads the log: the observation carries
the reaction and the agent records the event right after it on its own
thread, through a new Observation.follow_up_events() hook, so it is safe
with parallel tool calls. People react through
POST /api/conversations/{id}/reactions (LocalConversation.react), which
defaults to the agent's latest message or finish and never runs the agent.
Emoji come from a fixed set of shortcodes. New feature-map family F37.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
- A user message that arrives while a finished run's outcome is still being
  written now queues a reopen behind it, so a stale turn/resolved=auto no
  longer lands after the person wrote again (reproduced by
  test_a_user_message_before_the_outcome_is_saved_still_reopens).
- A child gets guidance naming its own parent: inherited guidance is
  removed first, also when the parent has left its project.
- Titles in the sender header and guidance are flattened to one line
  without quotes or brackets.
- Reaction targets come from the active branch.
- execute_tool records an observation's follow-up events, and rerun_actions
  logs them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
A ReactionEvent (target_event_id, emoji, removed, source) records an emoji
on a message; it never reaches the LLM. Agents react with the new react and
unreact tools (openhands.tools.reaction), which default to the person's
latest message. The executor only reads the log: the observation carries
the reaction and the agent records the event right after it on its own
thread, through a new Observation.follow_up_events() hook, so it is safe
with parallel tool calls. People react through
POST /api/conversations/{id}/reactions (LocalConversation.react), which
defaults to the agent's latest message or finish and never runs the agent.
Emoji come from a fixed set of shortcodes. New feature-map family F37.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
… on every tool path

Reaction part of de324a9 from #6602.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
…s the first

A feature flag is a yes/no switch the user sets for themselves, stored in
PersistedSettings.features and read when a conversation starts.
GET /api/settings/features lists the known features with their state, and
PATCH /api/settings/features/{key} {enabled} turns one on or off; unknown
keys are 404. The registry is openhands.agent_server.features.

The first flag, conversation_reactions (off by default), gives every new
OpenHands-agent conversation the react and unreact tools through a new
finalize(feature_tools=...) parameter (ACP agents are left alone), and
lets POST /api/conversations/{id}/reactions through; while it is off that
route answers 409. Feature map F37 covers both.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
ReactionEvent / ReactionEmoji types with isReactionEvent,
ConversationClient.react(), and SettingsClient.listFeatures() /
updateFeature() with the FeatureFlag type.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
- Coordinator tools say to delegate by default. When a member finishes a
  turn the coordinator started, the coordinator gets the member's final
  message as one update (project_wake.notify_coordinator). Turns the person
  starts in a member do not wake it, and an answered update starts no round.
- read_project_conversation and GET /api/projects/{id}/conversations/{cid}/messages
  give the coordinator a member's latest messages on demand.
- POST /api/conversations/{id}/events takes optional sender_conversation_id
  (records the sender and a "Sent by" line; a sender in a project only reaches
  its project) and refuse_pending_confirmation (409 instead of approving).
  With run it reports the run outcome. The project-only messages route is
  gone; message_project_conversation now uses the generic route.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Artifacts move from <persistence dir>/project-artifacts/<id>/ to
<persistence dir>/projects/<id>/artifacts/, so later project files (such as
memory) sit beside them. Deleting a project removes its whole folder. The
records stay in projects.json.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
- Asks: when a project conversation stops on a question, the server saves
  that question, in one line of at most 200 characters, as the `ask` tag.
  The board reports it while `turn` is `asked`; a new user message clears
  it, and children do not copy it. list_project_conversations shows it.
- Memory: MEMORY.md and lowercase .md topic files under
  <persistence dir>/projects/<id>/memory/, with GET/PUT/DELETE routes. Each
  write names the revision it was based on; a stale one is 409 with the
  current file to merge. read_project_memory and update_project_memory let
  agents keep it, and a child a project member starts gets MEMORY.md in its
  first message, marked as data.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
The react tool told the agent to unreact once it had answered, so a
"react with eyes first, then answer" request left no reaction: the
agent reacted and took it off just before its answer. A reaction now
stays until it no longer fits or the person asks. F37.tool asks in plain
words and checks that the one agent reaction is still on.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
Each message the person writes in a project conversation is copied to the
project's coordinator ("[Message from the person in ..."), and so is the
member's final reply to that turn ("[Reply in ..."). Both are saved without
running the coordinator and record the member as sender; they are for its
awareness, and running it on each would tempt it to forward them back.
The board ignores these copies, so they neither reopen the coordinator nor
start a turn. Turns the coordinator started still wake it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
- execute_tool records a tool's follow-up events without re-taking the
  state lock when the run loop holds it for the step (as switch_llm does,
  #3485), so a react from a tool worker cannot deadlock.
- The reactions route answers 409 with a clear reason when the settings
  file cannot be read, and the feature list reads settings off the event
  loop.
- Docs say what the flag governs: the agent's tools at conversation start,
  the person's reactions at once; child conversations reuse their
  parent's tools. The persisted-settings history notes the new field.
- react/unreact take an EventID and are not idempotent (each call records
  an event).
- TypeScript client: tests for listFeatures, updateFeature, react and
  isReactionEvent; the endpoint audit lists the new client-ahead calls.
- F37: rest-default accepts the agent's finish or its plain-text answer
  as the default target, and the lock gotcha matches the run loop.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
Since #5796 an MCP entry with neither command nor url is refused when
the config is built, so the invalid-entry case can no longer reach the
runtime. Same one-line change as #6606, so this PR's CI is not red on a
main failure.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
The user-facing feature flags are experimental features: list them with
GET /api/settings/experimental and switch one with PATCH
/api/settings/experimental/{key}. The TypeScript client methods become
listExperimentalFeatures and updateExperimentalFeature. This also keeps
clear of the operator-set Canvas feature policy (OpenHands/OpenHands#18843).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
Modules experimental_features and experimental_features_router, models
ExperimentalFeature / ExperimentalFeatureDefinition /
ExperimentalFeatureUpdate, the persisted field
PersistedSettings.experimental_features, finalize(experimental_feature_tools=...),
and the TypeScript ExperimentalFeature type, so every name says which
flag system it belongs to.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
A Docker runtime's server had its own empty settings, so its conversations
never got the reaction tools and the person's reactions always answered 409.
The host now passes its switches to each container in
OH_RUNTIME_EXPERIMENTAL_FEATURES, which pick the tools of conversations started
there, and checks the live switch itself before forwarding a reaction.

Also wraps three docstring lines over the line limit, and makes the F37
rest-default recipe fall back cleanly when the agent answered with finish.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
execute_tool skipped the state lock while a step held it, so two direct
calls on worker threads could write events at once and leave one off the
active branch. Their events now wait for the step to return and are written
by the run loop, the way the step's own parallel tool calls hand theirs back.
Outside a step it takes the state lock like send_message and react.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJ5sQMXhwgSTG2Ztkt
claude and others added 6 commits November 19, 2026 13:44
Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
The client no longer reserves the coordinator's conversation id, so a
new coordinator can never collide with an existing conversation and
ConversationService needs no reuse_existing switch.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
…a profile

Drop create_conversation and the extra _create_conversation keywords:
start_conversation takes the server's tools, the first message carries
sender_conversation_id, and the title is saved after the start.

A project worker always runs an agent profile; with none to run, the
start is refused (422). start_child_conversation is back to main's
copied child for everyone else.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
A client no longer reserves the coordinator's id, so the server picks
it before the start and the <PROJECT> block says which conversation the
coordinator is: one that calls the API itself can send as itself.

F36 now activates an agent profile: workers start from the predefined
worker profile, built from the active one, and are refused without it.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Remove the pending-confirmation guard from the shared send path:
refuse_pending_confirmation, the held/run outcomes on the send route,
HeldForUser, admission_refusal and the sender special case are gone, so
POST /events and EventService.send_message behave as on main.

Projects keeps two checks of its own: message_worker refuses a worker
waiting for confirmation, and project updates save without running a
coordinator that waits for one, so no agent approves another's actions.

The sender header stays in message_sender where main has it; Projects
adds project_sender_header beside it for the scope check and role.
ASK_USER moves back to main's place in experimental_features.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
… with the user

The live check no longer requires the coordinator to call message_worker:
it may decline on its own, as its prompt says only the user approves.
It still checks the worker keeps waiting and got no new message.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
claude and others added 13 commits November 19, 2026 17:30
…nternally

A project never adopts an existing conversation: coordinator_conversation_id
is gone from POST and PATCH /api/projects. POST starts a new coordinator when
asked, as before.

The coordinator's and worker's prompt, project context and tools reach the
agent through finalize's project_role (a ProjectRole), set only by
ProjectService. AgentLaunchAdditions is main's again, so no client can ask
for a coordinator prompt, and start_conversation loses server_tools.

Restore needs nothing of its own: the finalized agent is saved with the
conversation, as on main. F36 now checks that a coordinator and a worker keep
their prompt, context and tools after a restart and use a project tool.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
…prompt it has not sent yet

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
tool_module_qualnames lists every tool module the server has registered,
so a worker's response names message_worker even though its agent does not
have it.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: openhands <openhands@all-hands.dev>
…-xwkk9b

# Conflicts:
#	openhands-agent-server/openhands/agent_server/event_service.py
#	openhands-sdk/openhands/sdk/conversation/types.py
Only the server gives a conversation the Projects role and tools, so main's
launch path no longer strips Projects tools by class, and an ordinary child
is copied from its parent as on main. A Projects tool a conversation still
holds refuses to run when Projects is off or it is not in a project.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJH94xGSYwfoyccT4E
Keep both main's factories experimental feature and projects.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwN5xyei6hDyEx6k1KT
Base dropped the copied child's tag stripping and now gates board writes on
membership (is_member), so the activity tags follow _member() and the copied
child is left as on the base.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwN5xyei6hDyEx6k1KT
@enyst
enyst requested a review from all-hands-bot November 20, 2026 05:27

@all-hands-bot all-hands-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This review was posted by an AI agent (OpenHands).

Re-reviewed the current head 2283632c56d1e9ecaceade3a83bfa5ad858655bb as a fresh pass.

Scope: In-repo. The Agent Server owns conversation events and the canonical REST API, and clients/typescript/ mirrors it — this change sits exactly on that flow (Part of #6637, stacked on #6602; issue is ready-for-dev). No product decision needed.

What I verified on this head:

  • Tracker signals (AgentSaid, PullRequestsOpened) are derived only from events as published: creates_pull_request gates on a tool named for PR creation (substring match intentionally covers server-prefixed MCP names like github_create_pull_request) or a shell command matching gh pr create, and the ref comes from that call's own ObservationEvent (action_id matched, then discarded). Viewing PRs (gh pr view) yields no refs since its call is never tracked.
  • Board writes are member-gated (_set_activity re-checks is_member at write time), serialized on the existing _tail chain so event order holds, dedup'd no-ops, and merge_pull_requests bounds the prs tag to TAG_VALUE_MAX_LENGTH by dropping the oldest — I exercised the overflow and duplicate paths directly and they behave as described (a single over-long ref is dropped rather than raising).
  • Ownership/inheritance: ACTIVITY_TAG_KEYS is a subset of RESERVED_TAG_KEYS, so client PATCHes can't clobber them, release_members cleans them up, workers spawn with only {PROJECT_TAG_KEY}, and _reopen clears only BOARD_TAG_KEYS, so a new user message keeps lastmessage/prs across turns as claimed.
  • Router parsing is anchored on both ends and skips malformed refs; response model changes are additive with defaults, and the handwritten ProjectsClient types match. The checked-in generated contract (agent-server-schema.ts) is generated from the released 1.63.0 image and is current per the CI drift check, so leaving it untouched here is consistent with repo practice.
  • No new secret, auth, or LLM-message surface; tag values are length/key-validated by the existing _validate_tags.

Tests/checks: All GitHub Actions checks for this exact head are green. Locally: uv run pytest tests/agent_server/test_project_board.py tests/agent_server/test_project_cards.py tests/agent_server/test_projects_router.py → 162 passed; ruff check openhands-agent-server and pyright on the changed server files clean.

No material correctness, security, compatibility, or acceptance-criterion defect found.

✅ APPROVED

Base automatically changed from claude/project-thread-xwkk9b to main November 20, 2026 22:59
#6602 was squashed into main, so its files conflicted add/add. Each took
main's version with this PR's own diff (79fb43b..2283632) applied on
top; the PR's diff against main is that same diff.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJWmcdxmkFheJLLH6E
@github-actions

github-actions Bot commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

REST API breakage checks (OpenAPI) — ✅ PASSED

Result: ✅ PASSED

Action log

The lastmessage tag, summary_line and the AgentSaid signal are gone, and
with them ACTIVITY_TAG_KEYS: prs is the one server-owned activity tag, in
RESERVED_TAG_KEYS directly. The tracker's control flow is back to main's,
plus the pull-request call/result pairing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ArwwJWmcdxmkFheJLLH6E
@enyst enyst changed the title feat(projects): record a member's latest line and the pull requests it opens feat(projects): record the pull requests a project member opens Nov 21, 2026
@enyst
enyst merged commit 885242b into main Nov 21, 2026
58 of 59 checks passed
@enyst
enyst deleted the claude/project-thread-mcp0in branch November 21, 2026 01:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants