Repository navigation
projcore: rich task notes in the plan model (Task, task.set, .yppx, format plugin read/write) - #1802
Merged
Merged
Conversation
A task's notes can carry richtext markup beside the plain text every reader uses. set_rich_notes splits a value into the two (markup kept only when it formats something), and a plain set_notes of new text drops the markup so old formatting never comes back over new text. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L2XCadpiTmNZGJmLxXsMvK
#1801) The markup travels where the formatting does, as <note uid markup> children of formatting.xml, so a .mpp plugin gets it through the existing _ex symbols and a .yppx save keeps it. A note is applied on read only to a task whose plain notes it still describes; a plan without rich notes writes the part exactly as before (or none). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L2XCadpiTmNZGJmLxXsMvK
Markup is taken verbatim (never the one-line notes form), refused with notes in one call, and every task reply with notes carries markup: the stored formatting, else the plain notes' own canonical markup, so a plain note that starts with <p> is never read as markup. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L2XCadpiTmNZGJmLxXsMvK
MSPDI carries plain notes only, so without this a plugin's richtext Notes
page would prefill plain text and its OK would wipe the formatting. Both
hosts add a read-only {uid: markup} map built in projcore; the fixture's
fixture.richnote runs the downstream loop (read, extend, task.set).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L2XCadpiTmNZGJmLxXsMvK
…s rich_notes (#1801) Review r1: the plugin ABI, PROJECT.md and CLAUDE.md still said the formatting text is NULL whenever the plan has no formatting and is only formatting, so a plugin author could drop every rich note. yppxy's control verb table now lists task.set rich_notes and the reply key. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01L2XCadpiTmNZGJmLxXsMvK
1 of 2 tasks
|
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Owner
Author
|
Merged automatically (auto-merge is on for this checkout): review stopped: round 1 had no Major; all findings fixed; merge rounds: none; whole suite green on c183911 (12798 tests); merge-check ok; CI 14/14 green. Follow-ups: leftovers issue #1803 (both minor, plan out-of-scope items, filed new):
No finding was disputed or deferred. |
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.
What and why
Closes #1801. A plugin's
richtextTask Information Notes page could edit bold, italic, alignment and bullets, but the plan kept only plain text, so the formatting was dropped at OK. Task notes now carry their formatting beside the plain text.Task::rich_notes: canonicalprojcore::richtextmarkup,Someonly when it formats something, and its plain text is alwaysnotes.notesstays plain for every existing reader (MSPDI<Notes>, the grid, search, yppxy).Editor::set_rich_notessets text and markup as one undo step; a style-only change is a step and marks the plan dirty; an identical value is no step.set_noteswith new text clears the markup in the same step (same text keeps it).task.set {rich_notes}(taken verbatim, never through the one-line\nescape; refused together withnotes); task replies (task.get,task.set,task.list) carryrich_noteswhenever the task has notes, as markup (canonical for unformatted notes, so a plain note starting with<pis never misread)..yppxand format plugins.formatting.xmlcarries<note uid="N" markup="…"/>(newlines , tabs	), written by oneformatting::part_xmlfor.yppxand foryppx_plugin_write_ex; read back by.yppxandyppx_plugin_read_ex. No new ABI symbol. A plan without rich notes saves byte-identically. A<note>is applied only where the task's plain notes are its plain text, so old formatting never lands on new text; MSPDI imports and plugin reads without notes have none.view_json, yppxyrun_command) carries a read-onlyview.rich_notes{uid: markup};task.set rich_notesstays the only writer. The fixture'sfixture.richnote(command only, no manifest change) proves the read-edit-write loop.plugin_abi.rs, PROJECT.md, CLAUDE.md, yppxy's control table.Resource and assignment notes are out of scope.
Tests
New tests in richtext (
split_notes_keeps_markup_only_when_it_formats), editor (6, with an invariant helper),formatting::notes(6), yppx (2),projcore/tests/plugins.rs(rich_notes_cross_the_plugin_seam_both_ways), projctl (5),yppxy/tests/plugins.rs(a_ui_plugin_reads_and_writes_rich_notes), suite plugin_ui (the_view_json_carries_the_rich_notes). fmt and clippy-D warningsclean on projcore, projctl, yppxy, the fixture and the suite. No.uitwas needed or run (the fixture's manifest is unchanged; macOS cannot drive the window).Review
Plan agreed in two rounds (v1's gap: UI plugins see only MSPDI plus
view, soview.rich_noteswas added). revmux r1 (claude-only, 4 reviewers, none degraded): 0 Major, 2 Minor, both fixed in c183911 (the_exABI doc said the formatting text is NULL without formatting; yppxy'stask.settable lackedrich_notes). Nothing disputed or deferred.review stopped: round 1 had no Major; all findings fixed
🤖 Generated with Claude Code
https://claude.ai/code/session_01QPxLA5cJ1on1ZkqWFBMya6