[2.x] feat: Notify sbtn client when command is queued (#8568)

Fixes #8356

**Problem**

When `sbtn` sends a command while another long-running task (like `console`) is already executing, the client silently blocks with no indication that the command is waiting in a queue.

**Solution**

When a new command arrives via the network channel and another command is currently running, the server now sends an `ExecStatusEvent` notification with status `"Queued"` to the client. The client displays a message like:

```
[info] waiting for: console
```
This commit is contained in:
bitloi
2026-01-16 16:17:00 -05:00
committed by GitHub
parent 4d7e0633a8
commit c832fad7b5
4 changed files with 86 additions and 2 deletions
@@ -691,6 +691,14 @@ class NetworkClient(
}
case (`Shutdown`, Some(_)) => Vector.empty
case (msg, _) if msg.startsWith("build/") => Vector.empty
case ("sbt/exec", Some(json)) =>
import sbt.protocol.codec.JsonProtocol.given
Converter.fromJson[ExecStatusEvent](json) match {
case Success(event) if event.status == "Queued" =>
event.message.foreach(m => errorStream.println(s"[info] $m"))
Vector.empty
case _ => Vector.empty
}
case _ =>
Vector(
(