# debugger: Fix allow showing more than 1 compact session item \(\#37036\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/64b6e8ba0fd47828b6cf2917f520ca9962c15df5)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 64b6e8ba0fd47828b6cf2917f520ca9962c15df5

Requested commit: 64b6e8ba0fd47828b6cf2917f520ca9962c15df5

Commit: 64b6e8ba0fd47828b6cf2917f520ca9962c15df5

Tree: 9a4bd02ffc2d920d5e010c463eba1d4e6d3e6d8f

Author: Remco Smits

Committer: GitHub

## Message

```
debugger: Fix allow showing more than 1 compact session item (#37036)

Closes #36978

This PR fixes an issue that we would only show the first `root -> child`
session in compact mode, but the session that came after it, we would
only show the child session label instead of also adding the parent
label due to compact mode.

## Before
<img width="348" height="173" alt="Screenshot 2025-08-27 at 22 18 39"
src="https://github.com/user-attachments/assets/ad6afd3a-196d-497f-812a-00698676ee90"
/>

## After
<img width="563" height="211" alt="Screenshot 2025-08-27 at 21 57 16"
src="https://github.com/user-attachments/assets/a953ef2a-a796-4160-b868-96e96f81c858"
/>

With 3 parent + child sessions and one parent session only.
<img width="484" height="223" alt="Screenshot 2025-08-27 at 22 22 13"
src="https://github.com/user-attachments/assets/a26f79a4-63a5-43d0-a714-d62cb1995e6e"
/>

cc @cole-miller I know we hacked on this some while ago, so figured you
might be the best guy to ask for a review.

Release Notes:

- Debugger: Fix to allow showing more than 1 compact session item

---------

Co-authored-by: Anthony <anthony@zed.dev>
```

## Parents

- [236b3e546e484647c491323d733c299af518c7a0](https://git.cafe/gitcafe/zed/commit/236b3e546e484647c491323d733c299af518c7a0?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/64b6e8ba0fd47828b6cf2917f520ca9962c15df5?format=markdown)
