gitoria

notes

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Branchnotes17-ghost-noteae1075b2Preserve rejected drafts during note ID adoptionAtlasnotes17-ghost-note/reports/008-revendor-97bcf128.md

5.7 KB

  1. # notes mission 008 — re-vendor Hybriel 97bcf128 — gate 64/0 (was 62/2), hybriel#170 closes the offline editor gap (branch w7, NOT pushed, NOT deployed)
  2. ## Vendor
  3. - `/media/STORAGE/claude-scratch/vendor-97bcf128/` (README.txt: sha256 of every file, build command, ldd). Built read-only: `git -C /media/STORAGE/projects/hybriel archive 97bcf128 | tar -x`, `HL_NO_PLUGINS=1 bash native/build.sh` (55 s; the plugin .so files are committed in the archive).
  4. - `bin/hybriel` sha256 `60fa02f341ffa799b41a3dbd26d76057169f786e20dae0f98bb2ca3c46c39080` — **byte-identical to vendor-0f396652** (`diff -rq bin` clean): 0f396652..97bcf128 changes only `plugins/web/WebFramework.hl` (+67 lines, `offlineFiles`, `offlineFileUrls`, `viewFileUrls`) and `plugins/web/README.md` (+3). `ldd`: "not a dynamic executable"; `file`: statically linked.
  5. - Container: debian:12-slim + libssl3 + ca-certificates (the Dockerfile of notes), notes tree with the new vendor, compose copy with own names (`k2-notes-97bcf128`, volume, image), port 8750, tmpfs /tmp, cache volume, init: HTTP 200 after ~15 s, "framework listening on 8750", `docker exec … ldd` = not a dynamic executable. Container, volume and image removed.
  6. - No local XSS patch exists in notes' plugins (`plugins/webex` does not exist; w7's plugins were identical to vendor-0f396652 before this change), so nothing to keep or drop. docker-compose.yml, Dockerfile, deploy.sh unchanged (cache volume, tmpfs, init already there).
  7. ## App change (one setting, no JS)
  8. - `project.hl`: `offlineFiles = ["/md-editor.js"]`. Without it the editor stays missing offline: (b) of hybriel#170 (keep every file route a kept page's View loads through a literal `script { src }`) does not see it, because notes loads `/md-editor.js` in the shell (`components/main.hl`), not in the page View. Measured: with 97bcf128 and no setting the gate still failed the same 2 checks (62/2); with the setting 64/0. The worker's precache list now has `/md-editor.js` (the only difference in `/__hl/sw.js`, below).
  9. - `components/styles.hl` (mobile first, found by the new 390 px checks): `button` min-height 2.75rem; `.brand` and `.back` inline-flex, min 2.75rem; `md-editor::part(button)` min-width/height 2.75rem. (shared/md-editor.js untouched.)
  10. - README: "Known gap" paragraph replaced by the `offlineFiles` note.
  11. ## Gates (ports 8740/8741, Chrome 8742–8749; ident = a copy of ident a6a874c, see below)
  12. - `tests/browser.mjs`, old (w7 HEAD eeaea98 + the same bin, old plugins): **62 passed, 2 failed** — exactly the 2 failures of report 007 ("the Markdown editor is there offline", "tables: offline … with the table").
  13. - New (97bcf128 + `offlineFiles`): **64 passed, 0 failed**, both before and after the CSS change (two runs). The two checks pass.
  14. - ident for the gate: current ident HEAD (mission 011) changed the mail sink and the gate's sign-in fails with "email and code must be strings" (identkit reads the old sink format). I used `git archive a6a874c` of ident (mission 010, the one the gate was written against) + its bin. Not a notes problem; **tests/identkit.mjs needs an update for ident ≥ 7869f57** (ident#7 delivery) — left for a later mission.
  15. - Same-output real data (`tests/realdata-baseline.mjs`, old tree vs new tree, port 8752, COPY of `notes.worldapi.org-20261019-2028.tgz` (newest) → storage/mpackdb in scratch, deleted after): 295 answers each, 178 byte-identical, 115 identical after masking, **2 different**: `0032-in-___hl_sw.js` and `0033-out-___hl_sw.js` (the generated worker). The only difference is one more entry in `precache`: `"/md-editor.js"` — intended. No API answer differs. (Run before the CSS change; the CSS change alters app.css by intent.)
  16. - Real data offline (`tests/realdata-offline.mjs`, same backup copy, extended in this mission): **12 passed, 0 failed** — 28 live notes listed, offline reload lists 28 with no socket, offline edit with real keys not on the server, synced into the SAME note, no server error, plus the 6 new 390 px checks below. The copy was deleted by the test.
  17. ## Mobile: offline pages at 390 px, measured in the DOM (no image viewed)
  18. Chrome offline (CDP page + worker), reloaded offline at 390 px, every element incl. shadow DOM measured: no visible element left < 0 or right > 390, document scrollWidth, md-editor defined, every a/button/input/textarea/select/[role=button]/[contenteditable] ≥ 44 × 44.
  19. - Result now: note page 390 scroll width, no overflow, 16 tap targets all ≥ 44; list page 390, no overflow, 31 tap targets all ≥ 44; md-editor defined offline.
  20. - **Before the CSS fix (same checks failed):** brand link 53×28, Log out 82×35, "All notes" 65×24, New note 112×42, nine md-editor toolbar buttons 32×34. Fixed as above; no overflow was ever found.
  21. - Not counted as a tap target: the editor's own hidden textarea (`md-editor > textarea`, 24 px, out of sight by design); the editable surface is the md-editor shadow part.
  22. - Not measured: ident-selector's shadow DOM (not rendered on these pages offline); the online pages at 390 (screenshots of mission 007 stand).
  23. ## Cold start
  24. Measured on a heavily loaded machine (load average 62): empty HL_CACHE_DIR → ready (HTTP 200): new tree 44.8 s and 67.4 s (2 runs), old tree 42.5 s; warm 0.6–1.0 s. Mission 006 had 10.2 s on an idle machine; the numbers here are noise from load, not a change of the compile (same binary, one more setting). Re-measure on an idle machine before deploying.
  25. ## Hybriel gaps
  26. None hit. hybriel#170 (a) works as documented; (b) does not cover a script loaded in the shell rather than the page View — by design ("a kept page's View"), noted for Arachne in case a shell script should count.
  27. ## Commits (branch w7)
  28. re-vendor 97bcf128 + offlineFiles + tap sizes + 390 px checks + README + mission/report (this commit). Nothing of mine is left listening on 8740–8759.

Branches

Latest commits

  • ae1075b2Preserve rejected drafts during note ID adoptionAtlas
  • 383cce23|||PR Prevent saved local edits from restoring deleted notesAtlas
  • 99ca1cf6Merge branch 'vendor-day56' into mainAtlas
  • 649cef37|||PR Vendor Hybriel day56Atlas
  • aadd0abcMerge branch 'hl-standard-2' into mainAtlas
  • 52ffac9f|||PR Keyboard and reload checks for the notes gate (HL-STANDARD F21, F5)Atlas
  • 617ee8c0Merge branch 'hl-standard' into mainAtlas
  • 452458ee|||PR Type the function parameters of notes' own .hl files (HL-STANDARD L10)Atlas
  • 23758cd6Re-vendor complete Hybriel plugins and runtime to day44mre
  • 5d7cc700Backup tar: --hard-dereference, so mpackdb sidecars are never stored as hard links (Tracker's finding)mre
  • 3e07b1cfVendor complete Hybriel day39 plugin sources and librariesmre
  • d7366702Check session cookie flags after login and assert anonymous GET stays cookielessmre
  • 16bc8fd8Re-vendor Hybriel day38b with the mpackdb store-open race fixmre
  • d860dc2dnotes#12: the markup names its own rules instead of hand-written class strings: the selected row is `aria-current="page"` (the list-first theme rule styles it, no class), the delete question is `Style.pAsk` and follows its own `open` attribute (bound to `asking`), the error line is `Style.pMessage` (body once in lib/looks.hl, rule in notes.hl, main.hl and loginfailed.hl). The CSS declarations are the same, only selectors changed (.ask -> p.ask, .ask.open -> p.ask[open], .message -> p.message); the pages look the same (AE 0 at 4 sizes). main.hl's selectorClass in/out stays (login.js reads it).mre
  • 2e7f8664notes#13: the list and back links pass the note key from the loop (emit pick(e, r.key)) instead of writing data-note into the View and reading it back with getAttribute; the two window.history.replaceState calls and the identcode e.target.value read stay (hl:web has no replace-navigation, a bound hidden input is not adopted on a script's change event), see NO13 reportmre
  • 4dc98282notes#15: a deleted note made in this tab leaves the list at once (the delete now removes this tab's edit under every key the row has: local id, server id); gate: browser.mjs notes#15 section, red on the old codemre
  • e4e7402fnotes#11: plain declarations instead of let for variables never reassigned (components/notes.hl 3, lib/jsoncheck.hl 5, lib/util.hl 2, tools/migrate-short-ids.hl 8)mre
  • 27b6a09enotes#8: Style blocks in the nested form (note-list, note-editor, .ask with their children nested, :empty as a nested pseudo-class); the same CSS rules, the pages look the samemre
  • 71a9538bnotes: B27W report, log linemre
  • 78ba0073notes: an ident access key (Authorization: Bearer idt_…) reads and writes its identity's notes through /api/me and /api/notes; gate tests/ident-access-notes.mjs (ident#27)mre