|
1 | 1 | use std::{process::ExitStatus, time::Duration}; |
2 | 2 |
|
3 | 3 | use vite_path::RelativePathBuf; |
| 4 | +use vite_task_server::Error as IpcServerError; |
4 | 5 |
|
5 | 6 | use super::cache::CacheMiss; |
6 | 7 |
|
@@ -43,6 +44,12 @@ pub enum ExecutionError { |
43 | 44 | /// Creating the post-run fingerprint failed after successful execution. |
44 | 45 | #[error("Failed to create post-run fingerprint")] |
45 | 46 | PostRunFingerprint(#[source] anyhow::Error), |
| 47 | + |
| 48 | + /// The runner-aware IPC server failed to bind for this task. Reported |
| 49 | + /// instead of silently degrading so that `{ auto: true }` inputs stay |
| 50 | + /// observable end-to-end. |
| 51 | + #[error("Failed to set up task communication")] |
| 52 | + IpcServerBind(#[source] std::io::Error), |
46 | 53 | } |
47 | 54 |
|
48 | 55 | #[derive(Debug, Clone)] |
@@ -76,6 +83,14 @@ pub enum CacheNotUpdatedReason { |
76 | 83 | /// (its `input` config includes auto-inference). Task ran but cannot |
77 | 84 | /// be cached without tracked path accesses. |
78 | 85 | FspyUnsupported, |
| 86 | + /// The runner's IPC server failed during execution, so the collected |
| 87 | + /// reports may be incomplete. Caching such a run would risk stale |
| 88 | + /// inputs/outputs on the next hit. Carries the underlying error for |
| 89 | + /// user-facing reporting. |
| 90 | + IpcServerError(IpcServerError), |
| 91 | + /// A runner-aware tool explicitly requested that this run not be cached |
| 92 | + /// (e.g. vite dev-server, a watch task). |
| 93 | + ToolRequested, |
79 | 94 | } |
80 | 95 |
|
81 | 96 | #[derive(Debug)] |
|
0 commit comments