Skip to content

fix(enterprise): normalize legacy empty tool settings before honoring profile tools #68

Closed

Description

@simonrosenberg

Bug Description

Legacy cloud and enterprise settings rows can contain tools: [] even when no user intentionally configured a bare agent.

Before openhands-sdk 1.31.2, OpenHandsAgentSettings.tools used default_factory=list. SaasSettingsStore.store() serialized the complete settings model during ordinary settings updates, then persisted the resulting empty list into org.agent_settings and org_member.agent_settings_diff. Shared settings were also merged into every member of the organization.

openhands-sdk 1.31.2 changed the contract to:

  • tools: null: use the default toolset
  • tools: []: create an intentionally bare agent
  • non-empty tools: use the explicit toolset

The schema version remained unchanged and existing rows were not migrated. PR OpenHands/OpenHands#15228 began honoring the stored value during cloud launches, causing affected users to lose terminal, file editor, task tracker, and browser tools. PR OpenHands/OpenHands#15339 reverted that launch change as an immediate containment measure.

This is a compatibility problem in persisted org/member settings. Agent Profile tools: [] remains a valid intentional bare-agent configuration and must not be migrated.

Expected Behavior

Legacy empty tool arrays in org/member settings should resolve to the default toolset. An explicit tools: [] on an Agent Profile should continue to create a bare agent.

Self-hosted installations that skip intermediate releases must still receive the compatibility fix when they upgrade.

Actual Behavior

When cloud launch code honors org.agent_settings.tools or org_member.agent_settings_diff.tools, legacy [] values are interpreted as intentionally bare and conversations start without the default tools.

Steps to Reproduce

  1. Persist {"tools": []} in org.agent_settings or org_member.agent_settings_diff, as produced by settings saves before SDK 1.31.2.
  2. Load the effective settings for that member.
  3. Build a cloud conversation request while honoring the resolved agent_settings.tools value.
  4. Observe that the agent receives no terminal, file editor, task tracker, or browser tools.

Migration Plan

OpenHands Installation Method

OpenHands Cloud and self-hosted Enterprise.

OpenHands Version

Introduced when the SDK 1.31.2 tool semantics were adopted; exposed by cloud-1.47.0 / PR OpenHands/OpenHands#15228.

Additional Context

Activity

  1. added
    bug
    on Jul 21, 2026
  2. simonrosenberg commented on Jul 27, 2026

    @simonrosenberg
    MemberAuthor

    The implementation moved to #12 during the Agent Canvas repository cutover. OpenHands/OpenHands#15343 was closed as superseded; commit 9d28790dfa02210c09a670898b9b404a77e1472f is unchanged.

  3. transferred this issue fromOpenHands/OpenHandson Jul 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions