Anthony Eid
4a2afebc56
Fix task modal fallback when LSP tasks are empty ( #58090 )
...
References
[FR-28](https://linear.app/zed-industries/issue/FR-28/task-modal-does-not-show-runnable-rust-test ).
The bug this PR aims to fix is
> I can click the play button beside a rust test function, but it does
not show up in the task modal.
I wasn't able to reproduce it, but I suspect this was caused by the task
system preferring LSP code actions by default. It checked that an LSP
was queried for a task instead of checking if the queried LSP actually
returned any tasks. So the fix was just adding the below if statement as
a check.
```rust
if !new_lsp_tasks.is_empty() {
lsp_tasks
.entry(source_kind)
.or_insert_with(Vec::new)
.append(&mut new_lsp_tasks);
}
```
I also added a regression test for this
Self-Review Checklist:
- [x] I have reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the UI/UX checklist
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable
Release Notes:
- Fixed task modal failing to show language tasks in some cases
2026-05-29 17:49:11 +00:00
..
2026-05-29 15:27:28 +00:00
2026-05-20 20:51:56 +00:00
2026-05-27 10:31:57 +00:00
2026-05-15 12:01:31 +00:00
2026-05-29 15:27:28 +00:00
2026-05-26 15:11:19 +00:00
2026-05-27 14:08:15 +00:00
2026-05-28 23:04:44 +00:00
2026-05-29 15:27:28 +00:00
2026-05-29 07:06:57 +00:00
2026-05-28 18:20:11 +00:00
2026-04-23 23:47:30 +00:00
2026-05-29 15:21:53 +00:00
2026-05-27 10:31:53 +00:00
2026-05-01 22:33:54 +00:00
2026-05-26 20:49:22 +00:00
2026-05-28 17:45:54 +00:00
2026-05-27 10:31:53 +00:00
2026-05-19 21:31:34 +00:00
2026-05-29 15:58:02 +00:00
2026-05-11 15:53:20 +00:00
2026-05-27 16:39:19 +00:00
2026-05-18 14:49:40 +00:00
2026-05-21 08:32:23 +00:00
2026-05-11 15:22:43 +00:00
2026-05-28 20:19:17 +00:00
2026-05-08 15:53:40 +00:00
2026-05-27 16:08:52 +00:00
2026-05-29 07:06:57 +00:00
2026-05-29 07:06:57 +00:00
2026-05-19 17:45:07 +00:00
2026-05-28 15:00:31 +00:00
2026-05-28 15:00:31 +00:00
2026-05-15 17:08:40 +00:00
2026-05-04 06:30:47 +00:00
2026-05-15 11:12:41 +00:00
2026-04-27 08:42:45 +00:00
2026-04-29 10:27:47 +00:00
2026-04-24 10:29:51 +00:00
2026-05-13 23:35:10 +00:00
2026-05-25 11:53:12 +00:00
2026-05-25 17:01:58 +00:00
2026-04-29 10:27:47 +00:00
2026-05-29 05:12:28 +00:00
2026-05-28 17:30:36 +00:00
2026-04-30 11:10:14 +00:00
2026-05-29 07:21:30 +00:00
2026-05-27 14:11:23 +00:00
2026-05-20 22:42:31 +00:00
2026-05-27 14:11:23 +00:00
2026-04-10 13:27:04 -04:00
2026-05-21 15:23:20 +00:00
2026-05-29 17:49:11 +00:00
2026-05-06 09:28:05 +00:00
2026-05-08 10:36:03 +00:00
2026-05-27 16:21:30 +00:00
2026-05-21 08:32:23 +00:00
2026-04-29 07:27:05 +00:00
2026-05-21 08:32:23 +00:00
2026-05-27 10:31:53 +00:00
2026-05-21 08:32:23 +00:00
2026-05-29 14:10:02 +00:00
2026-04-18 06:34:19 +00:00
2026-05-04 06:30:47 +00:00
2026-05-27 10:31:53 +00:00
2026-05-27 15:35:46 +00:00
2026-05-06 10:56:20 +00:00
2026-05-27 20:59:01 +00:00
2026-05-26 02:10:47 +00:00
2026-04-30 14:17:32 +00:00
2026-05-29 15:27:21 +00:00
2026-05-26 13:41:28 +00:00
2026-05-21 10:00:29 +00:00
2026-05-29 15:58:02 +00:00
2026-05-27 18:17:59 +00:00
2026-05-27 18:17:59 +00:00
2026-05-26 14:32:45 +00:00
2026-04-24 08:58:26 +00:00
2026-04-14 18:14:31 +02:00
2026-04-23 23:47:30 +00:00
2026-05-26 12:59:21 +00:00
2026-05-26 14:32:45 +00:00
2026-05-27 18:17:59 +00:00
2026-05-26 16:22:19 +00:00
2026-05-26 02:10:47 +00:00
2026-05-08 10:36:03 +00:00
2026-04-22 22:22:10 +00:00
2026-05-14 22:20:34 +00:00
2026-05-26 12:59:21 +00:00
2026-05-05 22:41:13 +00:00
2026-04-29 10:27:47 +00:00
2026-05-14 22:20:34 +00:00
2026-05-28 13:27:55 +00:00
2026-04-18 00:55:44 +02:00
2026-05-27 13:05:55 +00:00
2026-05-26 10:00:34 +00:00
2026-05-29 16:28:27 +00:00
2026-05-15 16:27:11 +00:00
2026-05-08 10:36:03 +00:00
2026-05-20 14:12:42 +00:00
2026-05-26 14:58:09 +00:00
2026-05-08 10:36:03 +00:00
2026-05-29 15:21:53 +00:00
2026-05-27 10:31:53 +00:00
2026-05-28 13:47:58 +00:00
2026-05-28 13:47:58 +00:00
2026-05-27 16:27:18 +00:00
2026-05-04 22:51:56 +00:00
2026-04-23 18:41:52 +00:00
2026-05-06 12:27:58 +00:00
2026-05-28 13:27:55 +00:00
2026-05-27 04:39:26 +00:00
2026-05-29 07:06:57 +00:00
2026-05-14 21:03:56 +00:00
2026-04-15 02:21:56 -04:00
2026-05-29 07:06:57 +00:00
2026-05-29 11:23:56 +00:00
2026-05-21 03:59:50 +00:00
2026-05-26 10:00:34 +00:00
2026-05-28 17:45:54 +00:00
2026-05-05 05:10:46 +00:00
2026-05-27 12:43:06 +00:00
2026-05-12 15:52:52 +00:00
2026-05-14 16:30:08 +00:00
2026-05-06 14:06:48 +00:00
2026-05-29 07:31:00 +00:00
2026-05-05 22:41:13 +00:00
2026-05-26 13:41:44 +00:00
2026-05-05 22:41:13 +00:00
2026-05-29 15:27:28 +00:00
2026-05-26 07:09:47 +00:00
2026-05-21 19:48:43 +00:00
2026-05-15 21:17:43 +00:00
2026-05-29 15:58:02 +00:00
2026-04-16 16:36:09 -07:00
2026-05-26 19:41:24 +00:00
2026-05-28 20:14:34 +00:00
2026-05-08 21:03:40 +00:00
2026-05-27 10:31:53 +00:00
2026-05-26 07:09:47 +00:00
2026-05-27 20:35:32 +00:00
2026-05-29 15:58:02 +00:00
2026-05-25 11:53:12 +00:00
2026-05-28 15:25:54 +00:00
2026-05-26 07:09:47 +00:00
2026-05-29 07:06:57 +00:00
2026-05-05 16:25:56 +00:00
2026-05-29 03:47:05 +00:00
2026-05-28 23:04:44 +00:00
2026-04-29 10:27:47 +00:00
2026-05-05 22:41:13 +00:00
2026-04-24 10:29:51 +00:00
2026-05-27 19:33:04 +00:00
2026-05-27 10:31:53 +00:00
2026-05-04 06:30:47 +00:00
2026-05-27 10:31:53 +00:00
2026-05-12 16:20:53 +00:00
2026-05-29 17:49:11 +00:00
2026-05-28 22:24:22 +00:00
2026-05-28 09:34:57 +00:00
2026-05-27 10:31:53 +00:00
2026-05-20 02:33:07 +00:00
2026-04-23 23:47:30 +00:00
2026-05-21 22:16:01 +00:00
2026-05-28 19:43:30 +00:00
2026-05-27 20:02:48 +00:00
2026-05-08 10:36:03 +00:00
2026-05-29 07:06:57 +00:00
2026-05-29 07:06:57 +00:00
2026-05-29 07:06:57 +00:00
2026-05-25 16:20:30 +00:00
2026-05-28 02:36:38 +00:00
2026-05-27 10:31:53 +00:00
2026-05-12 19:40:00 +00:00
2026-05-01 22:33:54 +00:00
2026-05-29 07:06:57 +00:00
2026-05-27 00:04:30 +00:00
2026-05-29 16:28:27 +00:00
2026-05-29 11:59:18 +00:00
2026-05-27 16:08:52 +00:00
2026-05-13 11:34:50 +00:00
2026-05-28 20:19:17 +00:00
2026-05-28 20:19:17 +00:00