diff options
| author | Gabriel Schneider <[email protected]> | 2026-09-29 11:36:01 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-10-01 00:12:16 -0300 |
| commit | 05118f216d524c96ffe936e494b8ecce26303de1 (patch) | |
| tree | e67fe916801ef58d32cd04988240571cae8f8a49 /src/Messages.zig | |
| parent | 35f06a55bad1891e3d5e779630b232b2c322bc83 (diff) | |
| download | pardes-05118f216d524c96ffe936e494b8ecce26303de1.tar.gz pardes-05118f216d524c96ffe936e494b8ecce26303de1.zip | |
A builtin's Verbose announcement is the message row's alone, never logged
With Verbose on by default, /log filled with msg - DumpDir, msg 4 Grep and the like, with machinery to take an announcement back out when its builtin failed or said something itself. A msg record is now only something said; the take-back machinery goes with it.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'src/Messages.zig')
| -rw-r--r-- | src/Messages.zig | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/Messages.zig b/src/Messages.zig index ce7a2a8c..aebaff0c 100644 --- a/src/Messages.zig +++ b/src/Messages.zig @@ -503,9 +503,6 @@ pub fn clip(text: []const u8, max: usize) []const u8 { /// reportError with the words already chosen. pub fn reportFailure(p: *Pardes, id: usize, text: []const u8) void { p.fs.failures +%= 1; - // A failure said later, when the host could not do the work (a Save's - // write): that builtin's announcement goes from the log too. - ctlfs.events.dropFailedAnnouncement(p, text, false); // A builtin a ctl write runs: its first error is also the write's, cut // between words. const failing_write = p.fs.no_prompt or p.fs.capturing; @@ -520,11 +517,9 @@ pub fn reportFailure(p: *Pardes, id: usize, text: []const u8) void { p.fs.failure_len = @intCast(n); } // The write fails with it, and its err record says it: no msg for it, - // and no Verbose announcement before that, so the same failure again is - // the same record again, counted (events.pushCounting). + // so the same failure again is the same record again, counted + // (events.pushCounting). if (failing_write) { - const serial: u32 = if (p.fs.session_write) 0 else if (id < MAX_PANES) if (p.panes[id]) |pane| pane.serial else 0 else 0; - ctlfs.events.dropAnnouncement(p, serial, text); p.fs.unlogged = true; defer p.fs.unlogged = false; return setMessage(p, id, text); |
