Repository navigation
perf: faster cold start and lists; fix e2e-views nightly - #2
Merged
Merged
Conversation
Move file-path repairs, AI schedulers, meeting reminders, and the screenshot module off the first-window path so ready-to-show is not blocked by unused work. Lazy-load emoji-mart, markdown/highlight, chat modals, and file previews; memoize the virtual message list so composer typing does not rebuild rows. Co-authored-by: kenneth <zhou24388@163.com>
verify:e2e-views timed out clicking nav-tab-board because antd Tour's SVG mask intercepts pointer events. LANPM_E2E now seeds demo-project, TopBar closes the coachmark once groups exist, and tab clicks dismiss any leftover overlay. Also bump checkout/setup-node to v5 (Node 24). Co-authored-by: kenneth <zhou24388@163.com>
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.
Why
LanPM already has virtual chat lists, lazy group views, and a 2000-message memory window. Remaining runtime cost was still on the first-window path and the chat module graph: emoji-mart, react-markdown, and highlight.js were parsed for every cold start / chat paint, and composer keystrokes rebuilt the virtual list.
This PR also fixes GitHub Actions run 34779106284 (
e2e-nightly/verify:e2e-views) on the same branch.P2P, IPC, i18n, and AES-GCM/TOFU behavior are unchanged.
CI fix (
verify:e2e-views)Evidence (job 103782704966, step 8 ~line 338):
The board tab was in the DOM. Antd Tour’s SVG mask from
DiscoverCoachmarkintercepted the click. Discover E2E already dismisses that overlay; views smoke did not. After mock catalog defaulted off,LANPM_E2E=1also stopped seedingdemo-project, so a zero-group first-run Tour was likely on screen.Fix:
LANPM_E2E=1seedsdemo-projectagain (overridesLANPM_NO_DEMO)clickBottomNavTab/ setup dismiss leftover.ant-tourbefore clickingnav-tab-*actions/checkoutandactions/setup-nodev4 → v5 so Actions stops forcing the Node 20 runtime onto Node 24Performance (kept)
1. App startup / cold start
createWindow()first;scheduleDeferredStartup()runs file repairs, AI patrol/probe, meeting reminders, and screenshot init onsetImmediate.electron-screenshotsloads on first capture. Setup wizard isReact.lazy.2. Chat rendering / message list
Memo +
useMemorows onChatVirtualMessageList; overscan 8 → 4. emoji-mart / Markdown / CodeBlock / voice / chat modals load only when needed.3. Long-list scrolling
No virtuoso (SPRINT-60 NO-GO). Board
KanbanCardmemo; files previewers lazy +content-visibility: auto.4. Memory / RSS
Heavy modules stay out of RSS until used.
loadMessagestrims throughCHAT_MEMORY_WINDOW(2000).Verify (this VM)
Green:
npm run typecheckverify:chat-perf*·verify:list-scroll·verify:core-views-perf·verify:measure-perf· …)vitestseed + coachmark unit tests ·verify:ci-e2e-nightly·verify:discoverNot run here: Electron GUI
verify:e2e-views/measure:perf(Electron dist not installed in this agent image;electronpackage reports “failed to install correctly”). Re-run on a desktop or lete2e-nightlyworkflow_dispatch:Out of scope
[Unreleased]only)