Repository navigation
Writing after a pause no longer waits on background work (#275) - #411
Merged
Merged
Conversation
- A page read on the device stops between two lines when the pen lands (the worker takes a cancel; the view aborts on pen down). - The first save's move hash is worked out at open, a slice at a time. - The search for the next page to read hashes a page per slice. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…down - The next-page search reads a copy of the pages (a page removed between two slices threw and left device reading off); deviceBusy is reset in a finally. - The read's stop signal is taken before the model loads. - The move plan waits while the pen is down; the hash yields every 16 KB. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…'s growth Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.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.
Not verified on the device (the iPad bridge was in use by another session). Measured in the real-Obsidian rig with the CPU slowed. For Oskar: #275 is yours; Joost asked me to take this follow-up.
Follow-up to #275 (reporter, 3.0.0, iPadOS 17): strokes stop registering for a couple of seconds while the background work runs after a pause.
What changed
readStop), the worker gets{cancel: id}and stops at the next line. A stopped read is rescheduled, and the page is not blamed (no skip, the client is kept).payloadHashSteps,movedNotebookSteps); the first save uses it. The hash is unchanged (pinned against main's values), so two devices still make the same id.deviceStepSteps), given up when the pen lands.model/steps.ts(finish,runSliced, 6 ms slices) andrecognition/hwr/page-run.ts, both with tests.Nothing visible changed, so there is no review page.
Proof
Rig (real Obsidian, CDP), write–pause–write bursts with a CPU profile:
payloadHash519)pageContentHashof every page)Tests:
tests/view/device-reading-view.test.ts"stops the page being read when the pen lands, and blames no page (#275)" fails on main, and the two review tests ("…pen landed while the model loaded", "…a page is removed between two slices") fail on the first commit;tests/model/steps.test.tspins the hash and the slicing;tests/recognition/hwr-page-run.test.ts.npm run gates: all 11 steps pass.Test on the device
With Settings › Handwriting › Read on this device on:
iPadOS 18.2 and later deliver strokes late rather than losing them, so on a current iPad these steps may pass on main too: they check nothing broke. Only the reporter's iPadOS 17 shows the before.
Not verified
🤖 Generated with Claude Code