Skip to content

feat: consolidate conversation filters with distinct inactive/old toggles#773

Draft
rbren wants to merge 1 commit into
mainfrom
openhands/fix-675-consolidate-conversation-filters
Draft

feat: consolidate conversation filters with distinct inactive/old toggles#773
rbren wants to merge 1 commit into
mainfrom
openhands/fix-675-consolidate-conversation-filters

Conversation

@rbren
Copy link
Copy Markdown
Member

@rbren rbren commented May 26, 2026

  • A human has tested these changes.

Why

Issue #675 proposed adding "Hide inactive" and "Hide old" conversation toggles, but @sjathin's PR #756 observed they used the same 60-minute time threshold, making them identical/duplicative. @rbren asked: "Is the inactive logic different on cloud vs local? Is inactive/old truly duplicative?"

Investigation findings:

  • "Inactive" and "old" ARE genuinely different when properly defined — they're only duplicative if both use the same time-based threshold (the confusion in the original issue description).
  • Inactive (execution-status-based): the agent has stopped working — execution_status is PAUSED, ERROR, or STUCK. This works on both cloud (a paused sandbox will have execution_status=PAUSED) and local (user stopped or agent errored). A conversation that just errored 5 minutes ago is inactive but NOT old.
  • Old (time-based): not updated for 60+ minutes. A long-running RUNNING conversation could be "old" but is never "inactive".
  • Cloud vs local difference: Cloud conversations have sandbox_status (PAUSED/RUNNING). Local conversations have sandbox_status = null. But execution_status reflects the agent's stopped state on both platforms, so execution-status-based "inactive" applies uniformly.

Summary

  • Replace the separate "Older conversations" section and "All/Relevant threads" radio buttons in the filter menu with two independent checkbox toggles in the unified "Show" section:
    • Hide inactive conversations — hides PAUSED, ERROR, or STUCK conversations (execution-status-based; different from "old")
    • Hide old conversations — hides conversations not updated for 60+ minutes (time-based; replaces the old collapsible section)
  • Add hideInactiveConversations preference (default: false) to the store
  • Add isConversationInactive() helper function
  • Keep threadScope in the store for backward compatibility with persisted state
  • Add i18n translations for both new labels across all 15 supported languages

Issue Number

Fixes #675

How to Test

  1. npm ci && npm run dev (or npm run dev:mock for mock mode)
  2. Open the sidebar conversation list and click the filter (⇅) icon
  3. Verify the "Show" section now has two checkbox toggles: "Hide inactive conversations" and "Hide old conversations"
  4. Start some conversations, pause one, let one error — enable "Hide inactive" and verify the stopped conversations disappear
  5. Enable "Hide old" and verify conversations older than 1 hour disappear
  6. Verify the two filters work independently and can be combined

Or run the tests: npm test (all 2599 tests pass).

Type

  • Feature
  • Refactor

Notes

  • threadScope ("All threads" / "Relevant threads") is removed from the filter menu UI but kept in the store for localStorage backward-compatibility. Existing users who had threadScope: "relevant" persisted will still have it applied (the filtering logic is preserved in the panel), but the UI control is gone.
  • The PR resolves the investigation question from @rbren and supersedes feat: consolidate conversation filters with hide toggles #756 with a cleaner semantic model.

This PR was created by an AI agent (OpenHands) on behalf of the team.

@rbren can click here to continue refining the PR


🐳 Docker images for this PR

GHCR package: https://github.com/OpenHands/agent-canvas/pkgs/container/agent-canvas

Component Value
Image ghcr.io/openhands/agent-canvas
Architectures amd64, arm64
Agent Server ghcr.io/openhands/agent-server:1.23.0-python
Automation openhands-automation==1.0.0a3
Commit 81e00cc489148008ec79053f0fabf9edeee853aa

Pull (multi-arch manifest)

# Multi-arch manifest — Docker automatically pulls the correct architecture
docker pull ghcr.io/openhands/agent-canvas:sha-81e00cc

Run

docker run -it --rm \
  -p 8000:8000 \
  ghcr.io/openhands/agent-canvas:sha-81e00cc

All tags pushed for this build

ghcr.io/openhands/agent-canvas:sha-81e00cc-amd64
ghcr.io/openhands/agent-canvas:openhands-fix-675-consolidate-conversation-filters-amd64
ghcr.io/openhands/agent-canvas:pr-773-amd64
ghcr.io/openhands/agent-canvas:sha-81e00cc-arm64
ghcr.io/openhands/agent-canvas:openhands-fix-675-consolidate-conversation-filters-arm64
ghcr.io/openhands/agent-canvas:pr-773-arm64
ghcr.io/openhands/agent-canvas:sha-81e00cc
ghcr.io/openhands/agent-canvas:openhands-fix-675-consolidate-conversation-filters
ghcr.io/openhands/agent-canvas:pr-773

About Multi-Architecture Support

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

…gles

Addresses issue #675 (and the investigation in @rbren's comment) by
implementing two genuinely different filter toggles instead of duplicating
the same time-based threshold.

Investigation findings:
- 'Inactive' and 'old' ARE different concepts when properly defined:
  - Inactive (execution-status-based): agent stopped working (PAUSED/ERROR/STUCK).
    Applies equally on cloud and local. A just-errored conversation is inactive
    but NOT old.
  - Old (time-based): not updated for 60+ minutes. A still-running conversation
    can be 'old' but is never 'inactive'.
  - They are duplicative ONLY if both use the same time threshold (the mistake
    in the original issue description).

Changes:
- Add hideInactiveConversations (default: false) to preferences store
- Add isConversationInactive() helper in list helpers
- Replace 'All/Relevant' radio buttons and separate 'Older' section in the
  filter menu with two independent checkbox toggles in the 'Show' section:
  'Hide inactive conversations' and 'Hide old conversations'
- Keep threadScope in store for backward compat with persisted state
- Add i18n keys for both new filter labels (15 languages)
- Add tests for isConversationInactive, store preferences, and filter behavior

Co-authored-by: openhands <openhands@all-hands.dev>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 26, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
agent-canvas Ready Ready Preview, Comment May 26, 2026 4:05pm

Request Review

@github-actions
Copy link
Copy Markdown
Contributor

📸 Snapshot Test Report

Warning

Snapshot comparison step crashed (timeout, OOM, or runner error) — diff results below may be incomplete or absent.
Check the CI logs for the full error output (look for the "Run snapshot comparison" step).

❌ 1 snapshot differ from the main branch baseline. Add the update-snapshots label to acknowledge intentional changes.

Category Count
🔴 Changed 1
🆕 New 0
✅ Unchanged 72
Total 73

How to resolve:

  • Unintentional diffs — the baselines on main may have moved since this branch was created. Merge the latest main into this branch and re-run CI.
  • Intentional changes — add the update-snapshots label. CI will pass and the new screenshots become the baseline when this PR merges.
🔴 Changed snapshots (1)

sidebar

sidebar-filter-menu

Expected (main) Actual (PR) Diff
expected actual diff
✅ Unchanged snapshots (72)

archived-conversation

  • conversation-panel-with-archived-badges
  • conversation-view-archived
  • conversation-view-sandbox-error

automations

  • automations-delete-modal
  • automations-list-active-inactive
  • automations-no-automations
  • automations-search-no-results

backends-extended

  • backend-add-blank-disabled
  • backend-add-cloud-advanced-open
  • backend-add-cloud-no-key-disabled
  • backend-add-cloud-with-key-enabled
  • backend-add-form-partially-filled
  • backend-add-invalid-url-disabled
  • backend-add-local-ready
  • backend-add-name-only-disabled
  • backend-add-two-column-layout
  • backend-add-whitespace-host-disabled
  • backend-after-switch
  • backend-cancel-nothing-saved
  • backend-dropdown-two-backends
  • backend-edit-prefilled
  • backend-manage-after-removal
  • backend-manage-two-listed
  • backend-remove-cancelled
  • backend-remove-confirmation
  • backend-switch-overlay

backends

  • backend-add-modal
  • backend-manage-modal
  • backend-selector-open

changes-tab

  • changes-deleted-file
  • changes-diff-viewer
  • changes-empty

collapsible-thinking

  • reasoning-content-collapsed
  • reasoning-content-expanded
  • think-action-collapsed
  • think-action-expanded

mcp-page

  • mcp-custom-server-1-editor-open
  • mcp-custom-server-2-url-filled
  • mcp-custom-server-3-all-filled
  • mcp-custom-server-4-installed
  • mcp-custom-server-editor
  • mcp-empty-installed
  • mcp-search-filtered
  • mcp-slack-install-1-marketplace
  • mcp-slack-install-2-modal
  • mcp-slack-install-3-filled
  • mcp-slack-install-4-installed

onboarding

  • onboarding-step-0-choose-agent
  • onboarding-step-1-check-backend
  • onboarding-step-2-setup-llm
  • onboarding-step-3-say-hello

projects-workspace-browser

  • projects-workspace-browser

settings-page

  • add-backend-modal
  • analytics-consent-modal
  • home-screen
  • settings-app-page
  • settings-page

settings-secrets

  • secrets-add-form-filled
  • secrets-add-form
  • secrets-after-save
  • secrets-delete-confirm
  • secrets-list

settings-verification

  • condenser-settings
  • verification-settings-off
  • verification-settings-on

sidebar

  • sidebar-collapsed
  • sidebar-conversation-panel

skills-page

  • skills-empty
  • skills-loaded
  • skills-no-match
  • skills-search-filtered
  • skills-type-filter

Generated by the Snapshot Tests workflow. This comment was created by an AI agent (OpenHands) on behalf of the repo maintainers.

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.

Consolidate conversation filters: merge "older conversations" into "Show" section with hide toggles

2 participants