Unpredictable selection movement when the current item in the session_list is marked for deletion. #9485

Open
opened 2026-02-16 18:12:33 -05:00 by yindo · 1 comment
Owner

Originally created by @ariane-emory on GitHub (Feb 16, 2026).

Originally assigned to: @rekram1-node on GitHub.

Description

When a session has been marked down for deletion in the session_list using Ctrl+D and is then unselected - for instance by striking the up or down arrow keys, the viewport in the session_list window unexpectedly moves to the top of the list. Upon striking the up or down key a second time, the viewport returns to the correct position.

This is unintuitive and startling behaviour. If the up or down arrow keys are struck while an item is a marked for deletion, the item should be unmarked and the selection should be moved upwards or downwards in the session_list without causing the viewport to jump.

Plugins

None

OpenCode version

HEAD of dev at time of issue submission (approx 1.2.5)

Steps to reproduce

  1. Open the session_list and mark an item for deletion.
  2. Mark an item for deletion with control+d.
  3. Observe that the viewport jumps to a position that does not include the current selection.

Screenshot and/or share link

Initial state: item marked for deletion:

Image

After hitting 'up' key once, selected item not in viewport:

Image

After hitting 'up' key a second time, viewport returned to correct position:

Image

Operating System

MacOS Sequoia latest.

Terminal

iTerm2

Originally created by @ariane-emory on GitHub (Feb 16, 2026). Originally assigned to: @rekram1-node on GitHub. ### Description When a session has been marked down for deletion in the `session_list` using Ctrl+D and is then unselected - for instance by striking the up or down arrow keys, the viewport in the `session_list` window unexpectedly moves to the top of the list. Upon striking the up or down key a second time, the viewport returns to the correct position. This is unintuitive and startling behaviour. If the up or down arrow keys are struck while an item is a marked for deletion, the item should be unmarked and the selection should be moved upwards or downwards in the `session_list` without causing the viewport to jump. ### Plugins None ### OpenCode version HEAD of dev at time of issue submission (approx 1.2.5) ### Steps to reproduce 1. Open the `session_list` and mark an item for deletion. 2. Mark an item for deletion with control+d. 3. Observe that the viewport jumps to a position that does not include the current selection. ### Screenshot and/or share link #### Initial state: item marked for deletion: <img width="792" height="642" alt="Image" src="https://github.com/user-attachments/assets/58e97847-5278-4321-a701-83417f07957a" /> #### After hitting 'up' key once, selected item not in viewport: <img width="756" height="597" alt="Image" src="https://github.com/user-attachments/assets/4f4630f6-50d4-423c-b24f-5cf7f3dde94b" /> #### After hitting 'up' key a second time, viewport returned to correct position: <img width="756" height="617" alt="Image" src="https://github.com/user-attachments/assets/1ef82291-08cc-431e-9c54-854b08346573" /> ### Operating System MacOS Sequoia latest. ### Terminal iTerm2
yindo added the opentuibug labels 2026-02-16 18:12:33 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Feb 16, 2026):

This issue appears to be related to #9236: [Bug] Session list focus jumps randomly when deleting via Ctrl+D. While #9236 describes focus jumping when marking items for deletion, this issue specifically describes the viewport jumping when navigating with arrow keys after marking an item. These may be related manifestations of the same underlying issue in the session list deletion behavior.

Please check if your issue is distinct from #9236 or if it's the same root cause with different symptoms.

@github-actions[bot] commented on GitHub (Feb 16, 2026): This issue appears to be related to #9236: [Bug] Session list focus jumps randomly when deleting via Ctrl+D. While #9236 describes focus jumping when marking items for deletion, this issue specifically describes the viewport jumping when navigating with arrow keys after marking an item. These may be related manifestations of the same underlying issue in the session list deletion behavior. Please check if your issue is distinct from #9236 or if it's the same root cause with different symptoms.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9485