Repository navigation
feat(desktop): the native desktop app on MyGo and frostui (plan 0009) - #145
Conversation
ADR-0038 (proposed) draws the desktop app natively with MyGo and frostui and keeps the React app as lodge's web app. Plan 0009 holds the inventory of today's desktop app, its mapping to MyGo, frostui and an app-local kit, the hard parts (live preview, large vaults, accessibility), and the phases to parity before Tauri is deleted. Back-links on the ADRs, specs and plans it touches.
…0038 The orchestrator's notes: the palette's keys (Ctrl K except in an editor, Ctrl Shift P everywhere), the status bar's order with the connection first, the top bar's fixed field and menu, the shared pieces built once in frostui, and Phase 2 reordered to the parts that need none of them.
… app internal/desktop/notes ports app/src/editor/document.ts to Go for the MyGo desktop app (plan 0009, Phase 2): a change set with CodeMirror's compose, map and invert, a line-level Myers diff, the save loop (1 s debounce, 10 s maximum, one write in flight, merges mapped over what was typed meanwhile, conflicts, refused bases, removals, retries), CRLF notes saved with their line endings and mixed ones read-only, and an undo history that remote changes never enter. Tested against a real notesd (internal/rpctest).
internal/desktop/editor is the native app's note editor (plan 0009, Phase 2): MyGo's Markdown lexer with Obsidian's syntax laid over it (frontmatter, wikilinks and embeds, tags, highlights, %% comments, math, callouts, footnotes, block IDs), folding by headings and by indentation, a binding that reports the user's edits to the document and shows its changes, the document's undo on Ctrl+Z so another writer's change is never undone, Obsidian's editor keys and the formatting commands (ported with the web app's test cases), smart lists, links followed with Alt+Enter, Ctrl+Enter and Ctrl+click, and completion of [[ and #. internal/desktop/desktoptest holds the tests' UI-thread loop and a real notesd. MyGo v0.8.3 joins go.mod (go 1.27.3), the Flatpak's Go sources follow, and CI installs Pango and cairo for the headless Tester.
The desktop app's native reading view (ADR-0038, plan 0009) draws Markdown with MyGo's view, which shows no HTML. note.renderMarkdown rewrites only Obsidian's syntax with note.render's links, embeds and limits: wikilinks and Markdown links to vault files as note: links, images as blob: images, tags as tag: links, highlights as <mark>, callouts and lone note embeds as fenced frostnotes-callout and frostnotes-embed blocks, comments and block IDs gone, code untouched. Specified in docs/specs/render.md#markdown-for-native-views; additive within protocol 1.
internal/desktop/reading draws notesd's note.renderMarkdown with MyGo's Markdown view: re-rendered 300 ms after the text changes, so what is typed shows before it is saved; images read from notesd's blob store by hash (and remote ones by the preference); note: and tag: links handed to the window; note embeds as boxes holding the embedded note, and callouts in their type's color, foldable, from their fenced blocks. Tested with a real notesd and MyGo's headless Tester.
internal/desktop/history lists a note's versions (and a synced vault's hub revisions), shows one as read-only source or as its changes against the note on MyGo's diff view, and restores it with note.revert. The merge view sets another text beside the note's own buffer, editable and saving as typing does, takes chunks back with the diff view's hunk actions, and routes Ctrl+Z to the note's undo so another writer's change is never taken back.
internal/desktop/session connects to notesd as the local caller with the generated Go client, subscribes to events from the stored sequence, dials again each second when the connection drops, and keeps one document per open note, to which it routes note.changed, note.moved and note.removed. Tests: three writers (the user typing in MyGo's editor, an agent through notesd, an outside editor saving the file) lose no token and the caret stays; a benchmark types in a 10,000-line note (about 3 ms a keystroke with a CPU-drawn frame, under M3's 16 ms).
…e build The documents, source mode, reading view, history, merge view, session and note.renderMarkdown are built, with their evidence; what is left of Phase 2 is listed. ADR-0038 (still proposed) now says what was built: highlighting by MyGo's lexer with Obsidian's syntax laid over it, callouts and embeds as fenced blocks, SVG images drawn, and tasks not checkable in the reading view.
internal/desktop/workspace ports app/src/workspace's model and operations: splits and tab groups, tabs with back and forward, pinned, closed and reopened tabs, recent files, splitting and moving tabs to a group's edge, sidebars and the Files pane's folders, and following moves and deletions, with the web app's test cases. The operations change a workspace in place on the UI thread.
…sues frostui v0.1.0 joins go.mod (the Flatpak's Go sources follow) and draws the tabs' notices with its banner: a conflict (Compare, Dismiss), a refused base (Compare), a deleted note (Restore, close), a failed save (Retry now) and a note that cannot be edited here. Plan 0009 and ADR-0038 link egoist/mygo#1651 (hidden or replaced ranges, elements between lines, per-line styles) and egoist/mygo#1652 (edits outside the undo history), which MyGo's author welcomed: Phase 5 builds live preview on MyGo's editor in that order, and the app's own undo gives way to MyGo's when #1652 lands. The merge view says why no key or menu reaches MyGo's undo.
… catalog The system pieces in Go (the XDG paths, notesd's log tail, the Flatpak's background setting), the preferences and the workspace's versioned files, the table of commands held to specs/ui.md's keyboard map, and the vault catalog (files, aliases, tags, link text) that completes [[, [[target#, [[target#^ and #.
…ase 2 is done The note view: the inline title (Enter or leaving it renames), the properties panel (typed values, editable keys, add and remove, each edit rewriting only that key's lines, ported with the web app's test cases) and the editor, with the frontmatter folded while the panel shows it. Files pasted or dropped upload through note.upload by the vault's attachment settings.
frostyard-machines
left a comment
There was a problem hiding this comment.
Early design review (draft) at head 52b99786b980da04010ae2da80ef020ce54fc88a, against plan 0009, ADR-0038 and AGENTS.md. Scope: the design and the split between frostnotes and frostui. The full review comes when the PR leaves draft. Some CI jobs were still running at this head, so this review does not assess CI.
The direction is sound. Phase 2 builds no window and no app-local frame, and waits for frostui's frame. The pure packages (notes, workspace, session, commands) hold the decisions. frostui is pinned at a tag, with no go.work or replace. The risk:high note names .github/workflows/** and why the change is safe.
Where the frame without a rail belongs
Plan 0009:272-290 and ADR-0038:144-155 put the frame without a rail, Panes, the keymap and the waker in frostui, and keep only tab strips, the split tree of tab groups and pane tabs in internal/desktop/uikit. That split is right. Frostmail's #223 needs the same frame and has an app-local stand-in for it, so the two plans must agree on one frostui frame.
Question for frostui's owner (Ghanima): will frostui ship the frame without a rail (full-height content, top-bar segments, status bar, optional console split), Panes and the coalescing waker, in which version? Should the tab strips, split tree and pane tabs (plan 0009:292-300) go to frostui from the start, or wait in uikit until a second app needs them?
Findings
- Major
internal/desktop/commands/commands.go:1-5,11-29: the doc comment depends on "frostui's command table, from v0.2.0", andScopemirrors frostui'sKeyScope. frostui has onlyv0.1.0, and noKeyScopethat this PR can import. Frostmail's #223 has a different key model (browser key names and its own text-field rule). Fix: name in plan 0009 (Phase 3 or the generic pieces list) that the app takesKeyScopeand the binding from frostui'sCommandTablewhen it lands, and removeScopethen. Until then, state in the comment thatScopeis a copy to replace, not a frostui type. - Minor plan 0009:301-314 (packages):
catalog,prefsanddesktoptestare in the PR, but the package list does not name them. Fix: add them to the list with one line each. - Minor plan 0009:292-300:
internal/desktop/uikitdoes not exist yet, so nothing enforces its import rule. Fix: none needed now; add the package and its import test in the same PR as its first piece (Phase 4), as plan 0009 says.
internal/desktop/panes draws Files (MyGo's virtualized outline, with sorting, inline rename, drag into folders and context menus), Search, Backlinks, Outgoing links, Tags, All properties, Outline and Tasks, tested against a real notesd. internal/desktop/uikit holds the generic pieces frostui does not have: closable, pinnable, draggable tab strips, a split tree and icon pane tabs; a test keeps its imports to the standard library, MyGo, purego and frostui.
…nd settings The native app now boots: cmd/frostnotes over internal/desktop/window, with a thin local frame that frostui v0.2.0's PaneShell replaces. Every command of the keyboard map runs from the palette and its keys. The open rules of the Rust shell move to internal/desktop/system and join the risk paths.
frostyard-machines
left a comment
There was a problem hiding this comment.
Re-review at head 3265f5f39999e0ff7e3ac231309907053f6b9cb3 (draft). New since 52b9978: 114ea1e (panes, uikit's tab strips and split tree), 93b40dd (tab tests) and 3265f5f (the window: frame, workspace, palette, vault manager, settings). I read the frame, system/open.go and its risk-path entry, uikit and its import test, the Makefile targets, and checked the open findings. The full review of the views comes when the PR leaves draft. CI at this head: verify, race and Flatpak were still running.
frostui v0.2.0 now holds the shared pieces
frostui tagged v0.2.0 (its #4 and #5). It has PaneShell and PaneFrame (the frame without a rail: full-height content, top bar, palette field, status bar, console pane, toasts), Panes, Connection and ConnectingScreen, CommandTable with KeyScope and KeyBinding, SourceList, Opener, the settings layout and Waker. These are the pieces plan 0009:270-290 and ADR-0038:144-155 assign to frostui, which "Frostnotes builds none of".
Findings
- Major
internal/desktop/window/frame.go:14-16and the whole file: an app-local stand-in forPaneShell("comes in v0.2.0"). v0.2.0 is out. The stand-in also drifts already from Frostmail's stand-in on #223: the palette field is 380 wide here (:71) and 300 there, and the top bar's padding isSpaceLhere (:64) andSpaceMthere. Plan 0009 shares that bar between the two apps. Fix: pingithub.com/frostyard/frostui v0.2.0(thengo run ./tools/flatpakgo, as before), draw the window withfrostui.PaneShellandPaneFrame(withTableandConnection), and deleteframe.go's top bar, status bar and connecting screen. - Major
internal/desktop/commands/commands.go:1-29(open since my first review):Scopecopies frostui'sKeyScope. Fix: usefrostui.KeyScopeandKeyBindingfrom v0.2.0, and letCommandTablebind the keys. - Major
internal/desktop/system/open.go:1-126: what the app opens (an L1 path, now in.github/risk-paths.json) is written again beside frostui'sOpener(its ADR-0008: open behind allow-lists). Fix: buildOpenURLandOpenFileonfrostui.Opener{Roots: []string{vault}, Extensions: <the openable list>}, and keep in this repository only whatOpenerlacks: themailtoquery filter (to,cc,bcc,subject,body). Question for frostui's owner (Ghanima): shouldOpenerdrop amailtolink's other query keys (asattach=) itself, so that every app gets that rule? - Major PR body: it still says "No window is built yet", and its risk tier names only
.github/workflows/**. This head also changes.github/risk-paths.jsonand addsinternal/desktop/system/open.goto an L1 glob. Fix: update the summary and the gaps, and in the risk tier name.github/risk-paths.jsonandinternal/desktop/system/open.go, with why the change is safe (the rules ofapp/src-tauri/src/open.rs, kept). - Minor
internal/desktop/system/open_test.go:10-26:open.rs's tests (mail_links_keep_only_addressees_subject_and_body) also check a key in another case (ATTACH=,To=) and a percent-encoded key (%61ttach=). The Go test checks onlyattach=. Fix: port those cases, so the port keeps the rule the Rust test held. - Minor
internal/desktop/panes/tree.go,files.go: the Files tree is the app's own. Plan 0009's Phase 4 says "Files (frostui's tree)". Fix: draw it withfrostui.SourceList, or record in plan 0009 why the Files pane needs its own tree. - Minor (open) plan 0009:301-314:
catalog,prefsanddesktoptestare still not in the package list. This head changes no doc: plan 0009's status for Phases 3 and 4 andAGENTS.mddo not say what is built. Fix: record both, asAGENTS.mdasks ("rewrite designs, specs and code in place").
Closed
- My first review's point 3:
internal/desktop/uikitnow exists, andTestImportsNothingOfTheAppholds it to the standard library, MyGo, purego and frostui. Closed.
make desktop-build builds with mygo_noinspector and MyGo's production flag: good.
…nd settings The thin local frame goes: PaneShell draws the top bar, the connection, the status bar and the toasts; Panes holds the sidebars; the command table binds every key; the palette finds notes, folders, templates and headings as sources; Files is a SourceList; settings use frostui's layout. A burst of posts runs in one window update.
…dence Local edits from the window go through the document, so that they save. The Flatpak also builds the native app, which FROSTNOTES_NATIVE=1 runs for a trial while the Tauri module stays the default. CI starts the release build under Xvfb. Phases 3 and 4 of plan 0009 are done; Phase 5 waits for MyGo.
frostyard-machines
left a comment
There was a problem hiding this comment.
Re-review at head 8a9b5a5fc7a78570f29f0a908cfacbba827d03ec (draft). New since 3265f5f: a1978fc (the window on frostui v0.2.0) and 8a9b5a5 (link previews, tag search, the trial build). I read go.mod, window/frame.go, system/open.go and its use in cmd/frostnotes, commands, the Flatpak manifest and launcher, the new CI job, scripts/desktop-smoke.sh, AGENTS.md and plan 0009, and checked the open findings. CI at this head was still running.
Closed
- 1 (frame):
window/frame.gonow drawsfrostui.PaneFrameonPaneShell, withSidebarPanes,Connectionand the palette; the local top bar, status bar and connecting screen are gone. Closed. - 2 (keys):
CommandTablebinds the keys; the app'sScopeis now its own data (it addsInEditor, which frostui lacks) andactions.go:874-884maps it tofrostui.KeyScope. Closed; see point 11 for the comment. - 3 (opener):
cmd/frostnotesopens throughfrostui.Opener(Roots: []string{root},Extensions: system.OpenableExtensions()) after the app's ownVaultFileandWebURLrules; thexdg-opencall is gone. Closed. The question to frostui's owner (Ghanima) about themailtofilter stays open; it does not block this PR. - 6 (Files tree): Files is on
frostui.SourceList(plan 0009, Phase 4). Closed. - 7 (docs): plan 0009's package list, its Phase 3 and 4 status, and
AGENTS.mdnow say what is built. Closed.
Still open
- Major PR body: still says "No window is built yet", "frostui v0.1.0 is pinned" and "Phase 3, … once frostui's shared pieces land", and its risk tier names only
.github/workflows/**(L2). The PR now carrieslevel:L1: it changespackaging/flatpak/org.frostyard.Frostnotes.jsonandpackaging/flatpak/frostnotes.sh(L1, publication),.github/risk-paths.json, and a new CI job. Fix: rewrite the summary and the gaps to this head, and in the risk tier name each matched path and why it is safe: the manifest buildsfrostnotes-nativeand installs it in/app/libexecwithout changing the sandbox's permissions; the launcher runs it only whenFROSTNOTES_NATIVE=1; the newdesktopjob uses the same pinned actions,contents: readandpersist-credentials: false. - Minor
internal/desktop/system/open_test.go:14: still checks onlyattach=. Portopen.rs's cases for a key in another case (ATTACH=,To=) and a percent-encoded key (%61ttach=).
New
- Minor
packaging/flatpak/frostnotes.sh:67-71and the manifest: the trial (FROSTNOTES_NATIVE=1,/app/libexec/frostnotes-native,-X main.version=trial) lives on this branch only while it is a draft, but nothing says it goes before the merge. This PR merges at parity, when the native app replaces the Tauri app. Fix: name in plan 0009's Phase 7 that the switch removes the toggle, installs the native app as/app/libexec/frostnotes-appand stamps its real version, so the released Flatpak never carries two apps. - Minor
internal/desktop/commands/commands.go:3-5,13: "frostui's command table, from v0.2.0" and "The scopes, as frostui's KeyScope" no longer describe the code: the values differ fromfrostui.KeyScope(frostui hasOutsideText; the app hasInEditor) and the window maps them. Fix: say thatScopeis the app's, and thatwindowmaps it tofrostui.KeyScope. - Info CI: the new job "Native desktop app (make desktop-smoke)" is not in the repository's required-checks ruleset. If it must gate merges, the owner adds it to the ruleset; the job's name must then stay as it is.
scripts/desktop-smoke.sh keeps everything in a temporary directory with its own XDG_* and HOME, and fails when the app exits before the timeout: good.
A tab the workspace restores draws before the catalog is read, and it showed that its file was missing for good. A test also holds the sidebars to the workspace and the bar's toggle.
frostyard-machines
left a comment
There was a problem hiding this comment.
Re-review at head 4e7b7291161bf3b465688131d0342b84a33293d9 (draft). New since 8a9b5a5: 4e7b729 (a restored image tab waits for the file list). I read the whole commit.
catalog.Loadedis set in the same place asfilesandfolders, andcontentreads the image again until the catalog has the file's hash.TestARestoredImageTabShowsOnceTheFilesAreReadcovers the restored tab against a real notesd, andTestTheSidebarsFollowTheWorkspaceAndTheTogglecovers the sidebars' two toggles. No finding in this commit.
The open findings of my review at 8a9b5a5 do not change: 4 (Major), the PR body and its risk tier, and 5, 10, 11 (Minor) and 12 (Info).
…adcrumb ADR-0039 records live preview as replacements over the source, and internal/desktop/livepreview works out what shows; the editor adopts it when a MyGo release has replacements. A delete can be undone from its toast, the window wakes through frostui's waker, and one go build stamps the Flatpak's binaries.
Move go.mod, mise.lock and the nsl script to go1.27.4 with go.dev's checksums, and test that the three agree. The Flatpak builds with Flathub's Go SDK extension under GOTOOLCHAIN=local. Flathub has merged 1.27.4 but still publishes 1.27.3, so the Flatpak build refuses go.mod until the new extension is out.
frostyard-machines
left a comment
There was a problem hiding this comment.
Cross-review re-review 1 (of at most 3), range cd73e6b..982772d plus the earlier findings. Reviewer: openai/gpt-6.1-sol, the same as before. It is a static review: the reviewer ran no tests or builds.
Verdict at 982772d: Not ready.
Closed, with a guard that fails without the fix (or with a race guard): X1, X2, X4 to X7, X9, X11 to X15, X17, X20, X23 to X27, X30, X34, X35, X38, X42, X45, X47, X53, X59, X74, N1, N2. Thank you: that is most of the list.
Still blocking (the reviewer's list; I checked X10 and N3 in the code)
X10. internal/desktop/session/session.go:278 with notes/doc.go:177: forget disposes a released document when Unsaved() is false, and Unsaved() is dirty || flight != nil. A save refused after the release runs refused(), which clears dirty and keeps the user's text only in the NoticeRefused notice. forget then disposes it, and that text is lost. Fix: count a refused notice (or any held recovery text) as unsaved until it is saved or discarded; test release, then a refusal.
N3 (new; this keeps X16 partly open). internal/render/markdown.go:282-303 (emptyAltAt): the search for \n\n[r]: a.png, the reference image finds the next block's marker and rewrites b.png with a's target, which is wrong content (the same class as X4). Fix: bound the search to the block's end, and skip reference images (no ( after ]); add this fixture.
X19. internal/desktop/livepreview/livepreview.go:698: the label is parsed once now, but nested labels still scan and copy quadratically, and the recursion has no depth limit. Fix: cap the depth (or the work per line); add a deep-nesting test with a time bound.
X28. internal/desktop/window/app.go:141: drafts commit at window close, but not when a tab is released, and not after the asynchronous Flush. Property typing during the flush can still disappear. Fix: commit on tab release, and again before the final flush ends.
X33. internal/desktop/editor/properties.go:94: the 10,000-node budget resets for each property. Thousands of aliases to one large sequence still exhaust memory. Fix: one budget for the whole frontmatter; test many aliases of one big node.
X39. internal/desktop/window/actions.go:241: the resolve callback is guarded now, but the createAndOpen callback after it is not. Fix: guard its completion by the vault ID too; test a vault switch during the create.
X40. internal/desktop/window/actions.go:473 (saveUnder): Flush also finishes when a save failed and waits to retry, and typing stays possible during the delete. Then the delete runs on the old base, and Removed re-creates the note. Fix: stop the delete when a flush ends unsaved (say so), and block editing of the note until the delete answers; test both.
X3. internal/desktop/reading/view.go:76: the plan now matches the code, but decoded images still stay without a bound while a view is open. The reviewer wants the cache bounded.
X31. internal/desktop/editor/format.go:510 (inCode): "\n x\n - a" still continues the list markup inside indented code. Fix: track whether the indented run started as code; extend the test.
X44. internal/desktop/window/app.go:249: with a.settings = nil during a switch, a new note goes to the vault root before the new settings arrive. Fix: wait for the settings before creating (or create once they land); test the destination.
X46. internal/desktop/window/tabs.go:302: the read is off the UI thread now, but os.ReadFile of a blob still has no size bound. Fix: check the size (or read through a LimitReader) before decoding; add an oversized-blob test.
I graded X3, X31, X44 and X46 lower in part 2, but ready-for-human needs the reviewer's Ready, so these must close or be answered with a reason it accepts.
Also on this PR
411cda2(the Major findings) came after this range. I read its riskiest parts: load errors, workspace write retries, early events and join cleanup. I found no defect. The next re-review covers it.- CI:
Vulnerabilities (make vulncheck)still fails on GO-2026-6859, becausego.modis still at go1.27.3 (see my earlier comment). frostmail#223 made the same bump in51daf94. - 2 re-reviews are left. To use them well, push the fixes above and the Go bump together. Then the next re-review checks
982772d..HEADin one pass.
frostyard-machines
left a comment
There was a problem hiding this comment.
Review of 4d4c55f (Go 1.27.4), against 411cda2.
- The new checksum matches go.dev's published value for
go1.27.4.linux-amd64.tar.gz(7226736c…dab24840).go.mod,mise.lockanddev/nsl/provision.shmove together, andTestGoPinsAgreekeeps them in step.vulncheckpasses.
Blocking (CI red): Flatpak (build and test) fails. Log: go: go.mod requires go >= 1.27.4 (running go 1.27.3; GOTOOLCHAIN=local). packaging/flatpak/org.frostyard.Frostnotes.json:6-7,24 still builds with Flathub's org.freedesktop.Sdk.Extension.golang, which is at 1.27.3. The new .memory/corrections.jsonl line says this, but the PR cannot be ready while a required job is red.
Fix (the same as frostmail#223's 51daf94): build with Go's own tarball in the manifest. Remove the sdk-extensions entry. Add an archive source https://dl.google.com/go/go1.27.4.linux-amd64.tar.gz, sha256 7226736c2339719cda28fbf3a54d71aa63bcefe376e98cef00034268dab24840, dest: go-sdk, only-arches: [x86_64] (the only arch flatpak.yml bundles). Set append-path to /run/build/<module>/go-sdk/bin, and keep GOTOOLCHAIN=local. Extend TestGoPinsAgree so that the manifest's tarball version and checksum must match go.mod and mise.lock. Then change the corrections line, which now says that the Flatpak waits for Flathub. packaging/flatpak/** is an L1 risk path, so name this change in the PR body's risk section.
The re-review 2 (of 3) of 982772d..HEAD waits until this fix and the blocking points of my last review are pushed.
Keep a released note whose text notesd refused, and stop a delete when a note under it could not be saved, freezing those notes until it answers. Commit a focused property on tab release and after the last flush. Wait for a vault's settings before placing a new note, and drop a create answered after a vault switch. Bound the work behind untrusted notes: link nesting and scanning per line, frontmatter aliases across the note, an image file's size and a view's decoded images. Find an image with no alt text only inside its own block, and keep list markup inside indented code from continuing.
Flathub's Go extension still serves 1.27.3, so the Flatpak could not build go.mod's 1.27.4. Pin go.dev's tarball by version and checksum in the manifest and test it against go.mod and mise.lock.
frostyard-machines
left a comment
There was a problem hiding this comment.
Cross-review re-review 2 (of at most 3), range 982772d..22beaa2 (all 4 commits) plus the earlier findings. Reviewer: openai/gpt-6.1-sol, the same as before. It is a static review: the reviewer ran no tests or builds. I reviewed f6ce81c and 22beaa2 myself too, and I checked N4 in the code.
Verdict at 22beaa2: Not ready. Blocking: X40, N4.
Closed with a guard: X3, X10, X19, X28, X31, X33 (see N4), X39, X44, X46. The Go pins agree, and the Flatpak manifest uses the checksummed tarball with GOTOOLCHAIN=local. Of the Major findings that 411cda2 addresses, X29, X32, X57, X60, X62, X65, X67 to X69, X71 and X75 are closed.
Blocking
X40 (partly closed). internal/desktop/editor/noteview.go:288,326 with notes/doc.go:354-356: during a delete, Freeze makes Document.change refuse edits, but the property panel's controls stay enabled. A checkbox or field change during a slow delete is dropped with no sign, also when the delete then fails. Fix: disable the property controls (and any other editing control) while ReadOnly() is set, as the editor does; test a held delete, a property change, then a failed delete.
N4 (new). internal/desktop/editor/properties.go:170,366: the alias budget is shared across the frontmatter now, so expansion past it gives a plain nil value, and RenameProperty re-renders the property from that parsed value (renderProperty(to, p.props[i].Value, …)). With a 5,000-item anchor and 3 properties that reference it, renaming the third writes null: data in the note changes. (Even inside the budget, a rename turns b: *a into the expanded copy.) Fix: rename only the key, and keep the property's own value lines as they are; or refuse an edit of a property whose value was truncated. Test that a rename keeps an alias value byte for byte.
Not blocking
- N3 (partly closed).
internal/render/markdown.go:303: a matching destination does not prove that the marker is the image's own. For![][r] ``with[r]: photo.png, the reference image still rewrites the code span. Fix: use the image node's own source span; add this fixture. - N5.
internal/desktop/window/app.go:371: if the first settings request fails, later Create commands queue callbacks that nothing releases. Fix: retry the settings request when a callback queues and none is running, or report the failure at once. - Major findings still partly open: X22 (a suffix on a closing line can open an untracked comment), X41 (reading-mode links drop the heading), X43 (closing before the vault list answers loses the queued events), X54 (cleanup can query before a cancelled Add commits), X56 (
forgetFolderhides cleanup errors), X61 (a vault switch drops the failed workspace's retry).
Next
1 re-review is left. When X40 and N4 are fixed, it checks 22beaa2..HEAD. If that re-review is still Not ready, the PR goes to the owner to decide.
Disable the property panel and the merge view while a note is read-only, so a change during a delete is not dropped with no sign. A rename now changes only the key, keeping aliases, anchors and comments. Also close what stayed partly open: comments opened on a closing line, heading links in the reading view, events held for the vault list, a vault add cut short by a cancel, a failed workspace write across a vault switch, a settings request that failed, and an image's marker inside a code span.
frostyard-machines
left a comment
There was a problem hiding this comment.
Cross-review re-review 3 (the last of 3), range 22beaa2..69580cd plus the earlier findings. Reviewer: openai/gpt-6.1-sol, the same as before. It is a static review: the reviewer ran no tests or builds. I reviewed 69580cd myself too.
Verdict at 69580cd: Ready. Blocking: none.
- X40 is closed. The property panel (
editor/noteview.go:234) and the merge view (history/merge.go:39,50) take no edits while the note is frozen. The guards areTestThePropertiesPanelTakesNoChangeWhileTheNoteIsFrozenandTestTheMergeViewTakesNoEditWhileFrozen. - N4 is closed. A rename replaces only the key (
editor/properties.go:378) and re-reads the result to compare the value. The guards areTestARenamePastTheAliasBoundKeepsTheAliasandTestARenameKeepsTheValuesLinesByteForByte. - Also closed: N5, X22, X56, X61. The join's cancel now waits for
vault.add's answer and removes exactly the vault it returned.
Not blocking. Follow-ups, fine after the merge:
- N3 (partly).
internal/render/markdown.go:299checks only the next sibling. 2 adjacent empty reference images before a code span still let the first one rewrite the span. - X41 (partly).
reading/view.go:133follows headings, but not#^blockanchors. - X43 (partly). A saved sequence of 0 means "live only" (
session/session.go:145), so held events cannot replay in that edge case. - X54 (partly). A timeout or a lost connection during
vault.addcan still leave a committed vault without its ID. - N6 (low).
editor/properties.go:384:reflect.DeepEqualrejects an unchanged NaN. Renaminga: .nanfails, although the bytes are intact. Fix: a NaN-aware compare. - The non-blocking Minor findings of part 2 that the commits did not address.
The risk paths are named in the PR body. ready-for-human follows when CI is green at this head. Verify and Race were still running when I checked.
Summary
The desktop app moves from Tauri and React to a native Go app on MyGo and frostui; the React app stays as lodge's web app. It stays a draft until the owner has checked what only they can check, below. The last commit is the packaging move and the removal of
app/src-tauri, kept separate so it can be dropped or reviewed alone.note.renderMarkdown, renders a note as Markdown that MyGo's Markdown view reads. It is additive within protocol 1 and specified in specs/render.md.cmd/frostnotes,internal/desktop/), on frostui v0.2.0 and a fork of MyGo (see thereplacebelow), with nogo.work:PaneShell: top bar, palette, status bar in the shared order, dialogs, toasts, connecting screen, one instance, problem records, the vault manager, joining a hub, and settings with every preference, vault setting, Sync, Hub and Background.SourceListand the other panes; the quick switcher and the folder, template and heading choosers as palette sources; daily notes, templates, file tabs, opening outside the app; every command and key through frostui'sCommandTable.internal/desktop/livepreviewworks out what shows, with the reveal rule, andinternal/desktop/editor/live.godraws it on MyGo'sReplacements andBlocks: hidden marks; bullets, task boxes, quotes and rules; callouts, tables, note embeds and images as the reading view draws them; fence headers with Copy; links, tags and footnotes a click reaches. Undo is MyGo's, with other writers' changes and merges applied throughBuffer.EditRemote.packaging/icons/; the metainfo's screenshots from the Tester;app/src-tauri,@tauri-apps/*, the window buttons and the Flatpak-only settings gone from the React app, which builds only for lodge, with notesd still inside the Flatpak.Risk tier
Risk tier: 3 — this PR matches these paths in
.github/risk-paths.json:internal/desktop/system/open.go(L1): the rules for what the native app opens outside itself. It is a port ofapp/src-tauri/src/open.rswith the same tests: http, https and mailto only,attach=dropped from a mailto link; a file must be a regular, non-executable document inside the vault, symbolic links followed first. What passes then goes through frostui's allow-listedOpener. The new file joins the risk paths in this PR.packaging/flatpak/org.frostyard.Frostnotes.json,packaging/flatpak/frostnotes.sh,packaging/flatpak/stamp-version.sh(L1): one Go module builds notesd, notesctl and the app, which installs as/app/libexec/frostnotes-app, so the launcher is otherwise unchanged. Sandbox permissions are unchanged..github/workflows/ci.yml(L2): an apt step inverifyandracefor MyGo's headless Tester, a newdesktopjob, and theappjob removed. No new action; the job's permission iscontents: read, andpersist-credentialsis false.Makefile(L2): the targetsdesktop-build,desktop-run,desktop-smoke,desktop-evidence.verifyalso runs frostui's tests against the MyGo fork while thereplacestays,cibuilds the native app in place ofapp-buildandapp-test, andcheckandbumpare unchanged..github/risk-paths.json(L2): addsopen.go,internal/desktop/reading/view.goandinternal/desktop/editor/live.goat L1, and drops the globs of the Tauri files that are gone. Those two files are what the CSP's place now holds in the native app:loadImagereads only the blob store and, with Load remote images on,fetchreads onlyhttpandhttps, within a byte limit and a pixel limit;embedKindapplies the same rule to what live preview draws..github/workflows/flatpak.yml(L1),internal/workflowcheck,internal/packagecheck(L2): the checks of files that are gone go with them (the cargo entry and its tests, the shell's version stamp); the portal line is now checked againstsystem.PortalFailure.dev/nsl/provision.sh(L1),mise.lock(L2): Go moves from 1.27.3 to 1.27.4 for GO-2026-6859, with the checksums go.dev publishes for that release. Nothing else in either file changes.internal/workflowcheck/gopins_test.go(L2): a new test thatgo.mod,mise.lock,provision.shand the Flatpak's manifest name the same Go and the same checksum, and that the manifest keepsGOTOOLCHAIN=local. It loosens nothing.packaging/flatpak/org.frostyard.Frostnotes.json(L1), Go: the build uses go.dev's 1.27.4 tarball, pinned by checksum, in place of Flathub's Go extension, which still serves 1.27.3. No finish-args change, andGOTOOLCHAIN=localmakes a mismatch fail the build.internal/desktop/reading/view.go(L1): image files are read through a 128 MB limit, and a view's decoded images share a 256-megapixel budget. Both only refuse more; what a note may load does not widen.GoToscrolls to a heading already in the view.Three more things for the reviewer:
replaceon MyGo, approved by the owner on 2026-11-10.go.modreplacesgithub.com/egoist/mygowithgithub.com/bketelsen/mygo v0.8.4-0.20261111005420-2088771701f7, branchintegration/frostyard: egoist/mygo#1654, egoist/mygo#1655 and egoist/mygo#1662 merged together. It goes when all three are in a MyGo release.packaging/flatpak/go-sources.jsonis regenerated for it.goline ingo.mod. The Flatpak builds with the SDK's Go andGOTOOLCHAIN=local.internal/markdown's tag nodes now record where they start and end, so the renderer can rewrite them. Parse results are unchanged.What only the owner can check
Native desktop app (make desktop-smoke)in place of the removedApp shelljob.Parity gaps that remain
SourceListhas no middle click (the context menu offers Open in new tab), andStatusItemhas no menu, so the status bar's editing mode only toggles the reading view; Live Preview or Source mode is in Settings.canPickprops stay but are always false.Docs housekeeping
TEMPLATE.mddocs/README.mdVerification
make checkgreen (host): tidy, gen-check, vet, gofmt, golangci-lint (0 issues), every unit test, including MyGo's headless Tester testsmake genrun andmake gen-checkgreen, for the change toschema/rpc/note.yamlmake vault-itgreen at Phase 2, for the parser changemake ui-checkand the web build: not run here, since this host has no nsl machine namedfrostnotesand its container policy refuses a Node image. The last commit changes the React app and editspnpm-lock.yamlby hand, so CI'suianddebjobs are its first real check.packaging/flatpak/go-sources.jsonregenerated withgo run ./tools/flatpakgomake desktop-smoke's script run in a Debian container, on the fork: the release build started under Xvfb against a real notesd and was still running after 10 sTestNoTokenIsLostWithThreeWriters: the user types while an agent writes through notesd and an outside editor saves the file. No token is lost and the caret stays.BenchmarkTypingInALongNote: 8 ms a keystroke in live preview and 2.3 ms in source mode in a 10,000-line note with blocks, with a CPU-drawn frame, on an AMD Ryzen AI MAX+ 395. M3's target is 16 ms.TestEveryCommandRunsFromThePalette,TestEveryKeyRunsItsCommand: every command of the keyboard map, by the palette and by its window keys. The keys the editor binds are covered byinternal/desktop/editor's tests.TestCreatingOpeningAndRemovingVaults,TestJoiningALoopbackHub,TestEveryScreenDraws(light and dark), against a real notesd.TestAnEditOnThePhoneReachesTheDesktop: an edit on the hub reaches the open editor in about 12 ms over loopback, with the test server's sync settings; M2's latency evidence covers production settings.BenchmarkAKeystrokeInALongNote(livepreview): about 1 ms a keystroke in a 10,000-line note; a 20-second fuzz run found no overlapping or out-of-range pieces.TestALargeVaultStaysWithinAFrame(10,125 files), on the fork before the last bump: the tree median 355.78µs, worst 1.350822ms; the switcher median 4.833966ms, worst 10.72888ms. CPU-drawn frames on an AMD Ryzen AI MAX+ 395; the target is 16 ms.