Repository navigation
Conversation
This was referenced Oct 15, 2026
This was referenced Oct 15, 2026
Open
Owner
Author
This was referenced Oct 15, 2026
…hase 3)
Owner ruling (2026-10-08): "{now} should be per file, {start} the
capture's start — that's the behavior I had intuited from both
existing, so if they're the same today by design that's even more
confusing than I expected." `resolve_run_path` picked one `Local::now()`
per run and `LogWriter` reused that `base` for every split; the panel's
preview only re-asked the host when a template, the project, the
logger's name, or the capture's start changed. So `{now}` read as a
timestamp frozen at the run's start, identical to `{start}` whenever a
capture had no wall-clock anchor of its own.
`LogWriter` now opens through a `FileNamer` closure — called once to
open the run and again at every roll — instead of holding a fixed
`base`. The production namer (`make_run_namer`) resolves the folder
once, rooted and read before the run starts (nothing in a folder
template has reason to differ file to file), closes over the capture's
wall-clock start once, and resolves the *file* template fresh against
`Local::now()` on every call. `{start}` therefore stays the capture's
start across every split; `{now}` names each file's own creation. The
collision rule is unchanged and is now the only reason a suffix
appears: a resolved name already on disk — because the template has no
`{now}` at all, or a `{now}` pattern repeated within its own precision
— takes the next `-002`, `-003`… the same way at the run's first file
and at every later split (`first_free_part`/`split_path`, now always
scanned from part 1 since each open supplies its own fresh base rather
than a running part counter).
The logger panel's preview ticks once a second while mounted and a
template holds `{now}` — the interval `DateTimePatternEditor` already
runs for the `date_time_pattern` setting — skipped entirely when
neither template carries the token, so an unaffected logger issues no
extra IPC.
Docs: `export_template.rs`'s `{now}` doc, `logger.rs`'s module doc and
the `LogWriter` / `FileNamer` / `make_run_namer` rustdoc, README's
logger section (per-file `{now}`, the unchanged `{start}`, the
collision rule, the preview tick). No ADR states the logger
run-naming rule — ADR 0062 covers only the date-pattern notation, not
when a logger evaluates it — so none is amended.
Verified: `cargo test -p cannet-gui` (1449 passed, two new — a roll
resolves the file template from its own fresh instant; `{start}` stays
fixed across a roll while `{now}` advances), `cargo clippy -p
cannet-gui --all-targets -- -D warnings`, `cargo fmt --all -- --check`,
rustdoc `-D warnings`; `pnpm --dir apps/gui test` (3875 passed, three
new on the preview tick), `pnpm --dir apps/gui build`; `pnpm --dir
apps/gui tauri build --no-bundle` (release host, runs). Python lanes
skipped — the diff cannot reach them.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
thebhef
force-pushed
the
task165-date-setting
branch
from
October 26, 2026 22:42
807f610 to
c41cbe4
Compare
thebhef
force-pushed
the
fix-logger-now-per-file
branch
from
October 26, 2026 22:42
32fdbd9 to
989268e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Owner ruling (2026-10-08): "{now} should be per file, {start} the
capture's start — that's the behavior I had intuited from both
existing, so if they're the same today by design that's even more
confusing than I expected."
resolve_run_pathpicked oneLocal::now()per run and
LogWriterreused thatbasefor every split; the panel'spreview only re-asked the host when a template, the project, the
logger's name, or the capture's start changed. So
{now}read as atimestamp frozen at the run's start, identical to
{start}whenever acapture had no wall-clock anchor of its own.
LogWriternow opens through aFileNamerclosure — called once toopen the run and again at every roll — instead of holding a fixed
base. The production namer (make_run_namer) resolves the folderonce, rooted and read before the run starts (nothing in a folder
template has reason to differ file to file), closes over the capture's
wall-clock start once, and resolves the file template fresh against
Local::now()on every call.{start}therefore stays the capture'sstart across every split;
{now}names each file's own creation. Thecollision rule is unchanged and is now the only reason a suffix
appears: a resolved name already on disk — because the template has no
{now}at all, or a{now}pattern repeated within its own precision— takes the next
-002,-003… the same way at the run's first fileand at every later split (
first_free_part/split_path, now alwaysscanned from part 1 since each open supplies its own fresh base rather
than a running part counter).
The logger panel's preview ticks once a second while mounted and a
template holds
{now}— the intervalDateTimePatternEditoralreadyruns for the
date_time_patternsetting — skipped entirely whenneither template carries the token, so an unaffected logger issues no
extra IPC.
Docs:
export_template.rs's{now}doc,logger.rs's module doc andthe
LogWriter/FileNamer/make_run_namerrustdoc, README'slogger section (per-file
{now}, the unchanged{start}, thecollision rule, the preview tick). No ADR states the logger
run-naming rule — ADR 0062 covers only the date-pattern notation, not
when a logger evaluates it — so none is amended.
Verified:
cargo test -p cannet-gui(1449 passed, two new — a rollresolves the file template from its own fresh instant;
{start}staysfixed across a roll while
{now}advances),cargo clippy -p cannet-gui --all-targets -- -D warnings,cargo fmt --all -- --check,rustdoc
-D warnings;pnpm --dir apps/gui test(3875 passed, threenew on the preview tick),
pnpm --dir apps/gui build;pnpm --dir apps/gui tauri build --no-bundle(release host, runs). Python lanesskipped — the diff cannot reach them.
Co-Authored-By: Claude Sonnet 5 noreply@anthropic.com