openproj 0.77.2__tar.gz → 0.78.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (300) hide show
  1. {openproj-0.77.2 → openproj-0.78.0}/PKG-INFO +1 -1
  2. {openproj-0.77.2 → openproj-0.78.0}/design/drawings.md +37 -5
  3. {openproj-0.77.2 → openproj-0.78.0}/docs/quickstart.md +1 -0
  4. {openproj-0.77.2 → openproj-0.78.0}/pyproject.toml +1 -1
  5. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/__init__.py +1 -1
  6. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/controls.py +109 -39
  7. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/styles.py +6 -0
  8. {openproj-0.77.2 → openproj-0.78.0}/tests/test_editor.py +153 -27
  9. {openproj-0.77.2 → openproj-0.78.0}/tests/test_table.py +6 -1
  10. {openproj-0.77.2 → openproj-0.78.0}/uv.lock +1 -1
  11. {openproj-0.77.2 → openproj-0.78.0}/.gcloudignore +0 -0
  12. {openproj-0.77.2 → openproj-0.78.0}/.gitattributes +0 -0
  13. {openproj-0.77.2 → openproj-0.78.0}/.github/workflows/ci.yml +0 -0
  14. {openproj-0.77.2 → openproj-0.78.0}/.github/workflows/release.yml +0 -0
  15. {openproj-0.77.2 → openproj-0.78.0}/.gitignore +0 -0
  16. {openproj-0.77.2 → openproj-0.78.0}/.pre-commit-config.yaml +0 -0
  17. {openproj-0.77.2 → openproj-0.78.0}/.test_durations +0 -0
  18. {openproj-0.77.2 → openproj-0.78.0}/AGENTS.md +0 -0
  19. {openproj-0.77.2 → openproj-0.78.0}/Dockerfile +0 -0
  20. {openproj-0.77.2 → openproj-0.78.0}/LICENSE +0 -0
  21. {openproj-0.77.2 → openproj-0.78.0}/README.md +0 -0
  22. {openproj-0.77.2 → openproj-0.78.0}/deploy/RUNBOOK.md +0 -0
  23. {openproj-0.77.2 → openproj-0.78.0}/deploy/boot.py +0 -0
  24. {openproj-0.77.2 → openproj-0.78.0}/deploy/example.env +0 -0
  25. {openproj-0.77.2 → openproj-0.78.0}/design/EDITOR.md +0 -0
  26. {openproj-0.77.2 → openproj-0.78.0}/design/QUEUE.md +0 -0
  27. {openproj-0.77.2 → openproj-0.78.0}/design/README.md +0 -0
  28. {openproj-0.77.2 → openproj-0.78.0}/design/context-menus.md +0 -0
  29. {openproj-0.77.2 → openproj-0.78.0}/design/cycle-calendar.md +0 -0
  30. {openproj-0.77.2 → openproj-0.78.0}/design/deferred-push.md +0 -0
  31. {openproj-0.77.2 → openproj-0.78.0}/design/hackmd-observed.md +0 -0
  32. {openproj-0.77.2 → openproj-0.78.0}/design/probes/README.md +0 -0
  33. {openproj-0.77.2 → openproj-0.78.0}/design/probes/ci-durations-4core.txt +0 -0
  34. {openproj-0.77.2 → openproj-0.78.0}/design/probes/ci-durations-after-cache.txt +0 -0
  35. {openproj-0.77.2 → openproj-0.78.0}/design/probes/ci-durations.txt +0 -0
  36. {openproj-0.77.2 → openproj-0.78.0}/design/probes/ci-speed.md +0 -0
  37. {openproj-0.77.2 → openproj-0.78.0}/design/probes/coedit-under-load.md +0 -0
  38. {openproj-0.77.2 → openproj-0.78.0}/design/probes/concurrency-audit.md +0 -0
  39. {openproj-0.77.2 → openproj-0.78.0}/design/probes/hackmd_probe.py +0 -0
  40. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/adversarial-tail.json +0 -0
  41. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/adversarial.json +0 -0
  42. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/coedit-churn.json +0 -0
  43. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/coedit-same-room.json +0 -0
  44. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/detail-cost.json +0 -0
  45. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/diverge.json +0 -0
  46. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/index-warm.json +0 -0
  47. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/lockout.json +0 -0
  48. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/mixed-rtt600.json +0 -0
  49. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/mixed.json +0 -0
  50. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/read-load.json +0 -0
  51. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/same-contention.json +0 -0
  52. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/write-different.json +0 -0
  53. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/write-different.md +0 -0
  54. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/write-same.json +0 -0
  55. {openproj-0.77.2 → openproj-0.78.0}/design/probes/load/write-same.md +0 -0
  56. {openproj-0.77.2 → openproj-0.78.0}/design/time-model.md +0 -0
  57. {openproj-0.77.2 → openproj-0.78.0}/design/views-and-kinds.md +0 -0
  58. {openproj-0.77.2 → openproj-0.78.0}/docs/architecture.md +0 -0
  59. {openproj-0.77.2 → openproj-0.78.0}/docs/data-model.md +0 -0
  60. {openproj-0.77.2 → openproj-0.78.0}/docs/shape-up.md +0 -0
  61. {openproj-0.77.2 → openproj-0.78.0}/gcloud_deploy.sh +0 -0
  62. {openproj-0.77.2 → openproj-0.78.0}/seed/README.md +0 -0
  63. {openproj-0.77.2 → openproj-0.78.0}/seed/config/cycles.yaml +0 -0
  64. {openproj-0.77.2 → openproj-0.78.0}/seed/config/defaults.yaml +0 -0
  65. {openproj-0.77.2 → openproj-0.78.0}/seed/config/holidays.yaml +0 -0
  66. {openproj-0.77.2 → openproj-0.78.0}/seed/config/people.yaml +0 -0
  67. {openproj-0.77.2 → openproj-0.78.0}/seed/cycles/0037.md +0 -0
  68. {openproj-0.77.2 → openproj-0.78.0}/seed/issues/issue-778899.md +0 -0
  69. {openproj-0.77.2 → openproj-0.78.0}/seed/issues/issue-a1b2c3.md +0 -0
  70. {openproj-0.77.2 → openproj-0.78.0}/seed/issues/issue-b3c4d5.md +0 -0
  71. {openproj-0.77.2 → openproj-0.78.0}/seed/issues/issue-c9d0e1.md +0 -0
  72. {openproj-0.77.2 → openproj-0.78.0}/seed/issues/issue-d4e5f6.md +0 -0
  73. {openproj-0.77.2 → openproj-0.78.0}/seed/issues/issue-e6f7a8.md +0 -0
  74. {openproj-0.77.2 → openproj-0.78.0}/seed/notes/note-11aa22.md +0 -0
  75. {openproj-0.77.2 → openproj-0.78.0}/seed/notes/note-33bb44.md +0 -0
  76. {openproj-0.77.2 → openproj-0.78.0}/seed/notes/note-55cc66.md +0 -0
  77. {openproj-0.77.2 → openproj-0.78.0}/seed/notes/note-66dd77.md +0 -0
  78. {openproj-0.77.2 → openproj-0.78.0}/seed/notes/note-77ee88.md +0 -0
  79. {openproj-0.77.2 → openproj-0.78.0}/seed/notes/note-88ff99.md +0 -0
  80. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0a0001--testing-rank-reproducibility.md +0 -0
  81. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0b0001--porting-throughflow.md +0 -0
  82. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0c0001--porting-the-bed.md +0 -0
  83. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0d0001--aroma-transport-convergence.md +0 -0
  84. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0e0001--burner-radiation-port.md +0 -0
  85. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0f0001--scan-operator-on-the-gpu-backend.md +0 -0
  86. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0f0002--chaff-optics-in-the-burner.md +0 -0
  87. {openproj-0.77.2 → openproj-0.78.0}/seed/pitches/pitch-0f0003--tap-deck-rewrite.md +0 -0
  88. {openproj-0.77.2 → openproj-0.78.0}/seed/products/prod-0f0001--kiln4py.md +0 -0
  89. {openproj-0.77.2 → openproj-0.78.0}/seed/products/prod-0f0002--hearth.md +0 -0
  90. {openproj-0.77.2 → openproj-0.78.0}/seed/projects/proj-000001--whole-roast.md +0 -0
  91. {openproj-0.77.2 → openproj-0.78.0}/seed/projects/proj-000002--scan-backend.md +0 -0
  92. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0a1001--ci-for-the-standalone-driver-v1-5.md +0 -0
  93. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0a1002--implement-deterministic-means.md +0 -0
  94. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0b1001--port-the-air-side-throughflow.md +0 -0
  95. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0b1002--port-the-bed-side-throughflow.md +0 -0
  96. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0c1001--port-the-bed-solver.md +0 -0
  97. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0c1002--coordinate-with-kettleworth.md +0 -0
  98. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0d1001--flume-blend-coefficients.md +0 -0
  99. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0d1002--transport-module-halo-exchanges.md +0 -0
  100. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0d1003--drum-convergence-study.md +0 -0
  101. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0e1001--port-the-near-ir-burner.md +0 -0
  102. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0e1002--port-the-far-ir-burner.md +0 -0
  103. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0f1001--lower-the-scan-to-the-gpu-backend.md +0 -0
  104. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0f1002--bench-the-scan-against-the-cpu-reference.md +0 -0
  105. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0f1003--port-the-tap-deck-reader.md +0 -0
  106. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0f1004--wire-the-tap-deck-writer.md +0 -0
  107. {openproj-0.77.2 → openproj-0.78.0}/seed/tasks/task-0f1005--retire-the-f2py-shim.md +0 -0
  108. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/auth.py +0 -0
  109. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/bootstrap.py +0 -0
  110. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/cli.py +0 -0
  111. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/coedit.py +0 -0
  112. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/github.py +0 -0
  113. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/index.py +0 -0
  114. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/model.py +0 -0
  115. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/pusher.py +0 -0
  116. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/query.py +0 -0
  117. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/__init__.py +0 -0
  118. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/calendar.py +0 -0
  119. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/cycles.py +0 -0
  120. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/deck.py +0 -0
  121. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/detail.py +0 -0
  122. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/editor.py +0 -0
  123. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/env.py +0 -0
  124. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/export.py +0 -0
  125. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/graph.py +0 -0
  126. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/help.py +0 -0
  127. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/hill.py +0 -0
  128. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/icons.py +0 -0
  129. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/markdown.py +0 -0
  130. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/pop.py +0 -0
  131. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/records.py +0 -0
  132. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/rows.py +0 -0
  133. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/shell.py +0 -0
  134. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/slides.py +0 -0
  135. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/table.py +0 -0
  136. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/timeline.py +0 -0
  137. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/render/tokens.py +0 -0
  138. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/schedule.py +0 -0
  139. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/store.py +0 -0
  140. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/tailnet.py +0 -0
  141. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/themes.py +0 -0
  142. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/vendor.py +0 -0
  143. {openproj-0.77.2 → openproj-0.78.0}/src/openproj/web.py +0 -0
  144. {openproj-0.77.2 → openproj-0.78.0}/static/SHA256SUMS +0 -0
  145. {openproj-0.77.2 → openproj-0.78.0}/static/VENDOR.md +0 -0
  146. {openproj-0.77.2 → openproj-0.78.0}/static/ace-LICENSE.txt +0 -0
  147. {openproj-0.77.2 → openproj-0.78.0}/static/ace.js +0 -0
  148. {openproj-0.77.2 → openproj-0.78.0}/static/cytoscape.min.js +0 -0
  149. {openproj-0.77.2 → openproj-0.78.0}/static/datepicker-LICENSE.txt +0 -0
  150. {openproj-0.77.2 → openproj-0.78.0}/static/datepicker.min.js +0 -0
  151. {openproj-0.77.2 → openproj-0.78.0}/static/elk-LICENSE.txt +0 -0
  152. {openproj-0.77.2 → openproj-0.78.0}/static/elk.bundled.js +0 -0
  153. {openproj-0.77.2 → openproj-0.78.0}/static/excalidraw-LICENSE.txt +0 -0
  154. {openproj-0.77.2 → openproj-0.78.0}/static/excalidraw-fonts-LICENSE.txt +0 -0
  155. {openproj-0.77.2 → openproj-0.78.0}/static/excalidraw.js +0 -0
  156. {openproj-0.77.2 → openproj-0.78.0}/static/inter-LICENSE.txt +0 -0
  157. {openproj-0.77.2 → openproj-0.78.0}/static/inter-latin-wght-normal.woff2 +0 -0
  158. {openproj-0.77.2 → openproj-0.78.0}/static/keybinding-vim.js +0 -0
  159. {openproj-0.77.2 → openproj-0.78.0}/static/mermaid-LICENSE.txt +0 -0
  160. {openproj-0.77.2 → openproj-0.78.0}/static/mermaid.min.js +0 -0
  161. {openproj-0.77.2 → openproj-0.78.0}/static/mode-python.js +0 -0
  162. {openproj-0.77.2 → openproj-0.78.0}/static/mode-sh.js +0 -0
  163. {openproj-0.77.2 → openproj-0.78.0}/static/mode-yaml.js +0 -0
  164. {openproj-0.77.2 → openproj-0.78.0}/static/yjs-LICENSE.txt +0 -0
  165. {openproj-0.77.2 → openproj-0.78.0}/static/yjs.bundle.mjs +0 -0
  166. {openproj-0.77.2 → openproj-0.78.0}/tests/browser.py +0 -0
  167. {openproj-0.77.2 → openproj-0.78.0}/tests/cascade.py +0 -0
  168. {openproj-0.77.2 → openproj-0.78.0}/tests/conftest.py +0 -0
  169. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/README.md +0 -0
  170. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/config/cycles.yaml +0 -0
  171. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/config/defaults.yaml +0 -0
  172. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/config/holidays.yaml +0 -0
  173. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/cycles/0037.md +0 -0
  174. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/cycles/0038.md +0 -0
  175. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/issues/issue-8e1a37.md +0 -0
  176. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/issues/issue-9f2b48.md +0 -0
  177. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/notes/note-a03c59.md +0 -0
  178. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/notes/note-b14d6a.md +0 -0
  179. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-1b3f9a--mpi-on-ci-verify-with-serial.md +0 -0
  180. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-2a7f3e--transport-port-blend-coeffs.md +0 -0
  181. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-3c9a41--throughflow-1d-cpu-single-node.md +0 -0
  182. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-48ea9e--transport-needs-exchange.md +0 -0
  183. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-5e7b1c--ci-standalone-driver-v1-5.md +0 -0
  184. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-6f2d18--scan-operator-on-the-gpu-backend.md +0 -0
  185. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/pitches/pitch-7b3e94--year-end-backend-hardening.md +0 -0
  186. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/products/prod-6d1a70--kiln4py.md +0 -0
  187. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/products/prod-7c2b81--hearth.md +0 -0
  188. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/projects/proj-7e57a0--testing.md +0 -0
  189. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/projects/proj-9a4c25--hearth-backend-for-the-bed-solver.md +0 -0
  190. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-0e4b7a--add-unit-tests-for-bed2drum.md +0 -0
  191. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-2b6c94--cleanup-mesh-shape-compute-coeffs-interface.md +0 -0
  192. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-31f6c4--verify-the-throughflow-scheme-in-kiln4py-using-recorded-test-data.md +0 -0
  193. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-3a52d8--compile-the-wrapper-with-f2py-to-generate-the-bedstep-f2py-module.md +0 -0
  194. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-3d84e9--create-the-interface-for-running-throughflow-in-kiln4py.md +0 -0
  195. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-3e07b2--generate-python-bindings-with-f2py-for-bedstep-setup-config-and-bedstep-run.md +0 -0
  196. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-53a9f0--reproduce-2gpu-seam-artefact.md +0 -0
  197. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-58d7c6--per-field-delta-tolerances.md +0 -0
  198. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-5a4e39--read-the-2014-stable-summation-paper.md +0 -0
  199. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-5c1d84--try-deterministic-means.md +0 -0
  200. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-5f062b--downgrade-numpy-for-global-sums.md +0 -0
  201. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-6a5c02--lower-the-scan-operator.md +0 -0
  202. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-6b7d31--bench-the-scan-against-the-cpu-reference.md +0 -0
  203. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-7c8e40--freeze-the-backend-api.md +0 -0
  204. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/corpus/tasks/task-7d9f52--rerun-the-backend-suite-after-the-shutdown.md +0 -0
  205. {openproj-0.77.2 → openproj-0.78.0}/tests/fixtures/roundtrip.md +0 -0
  206. {openproj-0.77.2 → openproj-0.78.0}/tests/js/drive.js +0 -0
  207. {openproj-0.77.2 → openproj-0.78.0}/tests/js/yjs-seed.js +0 -0
  208. {openproj-0.77.2 → openproj-0.78.0}/tests/load/adversarial.py +0 -0
  209. {openproj-0.77.2 → openproj-0.78.0}/tests/load/churn.py +0 -0
  210. {openproj-0.77.2 → openproj-0.78.0}/tests/load/coedit_same_room.py +0 -0
  211. {openproj-0.77.2 → openproj-0.78.0}/tests/load/corpus.py +0 -0
  212. {openproj-0.77.2 → openproj-0.78.0}/tests/load/counters.py +0 -0
  213. {openproj-0.77.2 → openproj-0.78.0}/tests/load/detail_cost.py +0 -0
  214. {openproj-0.77.2 → openproj-0.78.0}/tests/load/diverge.py +0 -0
  215. {openproj-0.77.2 → openproj-0.78.0}/tests/load/divergence.py +0 -0
  216. {openproj-0.77.2 → openproj-0.78.0}/tests/load/drive.py +0 -0
  217. {openproj-0.77.2 → openproj-0.78.0}/tests/load/harness.py +0 -0
  218. {openproj-0.77.2 → openproj-0.78.0}/tests/load/herd.py +0 -0
  219. {openproj-0.77.2 → openproj-0.78.0}/tests/load/index_warm.py +0 -0
  220. {openproj-0.77.2 → openproj-0.78.0}/tests/load/lockout.py +0 -0
  221. {openproj-0.77.2 → openproj-0.78.0}/tests/load/lost_line.py +0 -0
  222. {openproj-0.77.2 → openproj-0.78.0}/tests/load/measure.py +0 -0
  223. {openproj-0.77.2 → openproj-0.78.0}/tests/load/merge_probe.py +0 -0
  224. {openproj-0.77.2 → openproj-0.78.0}/tests/load/micro.py +0 -0
  225. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_ceiling.py +0 -0
  226. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_emoji.py +0 -0
  227. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_fanout.py +0 -0
  228. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_manyrooms.py +0 -0
  229. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_saverace.py +0 -0
  230. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_seats.py +0 -0
  231. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_shutdown.py +0 -0
  232. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_twoinstances.py +0 -0
  233. {openproj-0.77.2 → openproj-0.78.0}/tests/load/probe_writecost.py +0 -0
  234. {openproj-0.77.2 → openproj-0.78.0}/tests/load/queueing.py +0 -0
  235. {openproj-0.77.2 → openproj-0.78.0}/tests/load/readload.py +0 -0
  236. {openproj-0.77.2 → openproj-0.78.0}/tests/load/room.py +0 -0
  237. {openproj-0.77.2 → openproj-0.78.0}/tests/load/rooms.py +0 -0
  238. {openproj-0.77.2 → openproj-0.78.0}/tests/load/run.py +0 -0
  239. {openproj-0.77.2 → openproj-0.78.0}/tests/load/run.sh +0 -0
  240. {openproj-0.77.2 → openproj-0.78.0}/tests/load/serve_load.py +0 -0
  241. {openproj-0.77.2 → openproj-0.78.0}/tests/load/server.py +0 -0
  242. {openproj-0.77.2 → openproj-0.78.0}/tests/load/users.py +0 -0
  243. {openproj-0.77.2 → openproj-0.78.0}/tests/load/verify.py +0 -0
  244. {openproj-0.77.2 → openproj-0.78.0}/tests/load/write_same.py +0 -0
  245. {openproj-0.77.2 → openproj-0.78.0}/tests/load/writer_ceiling.py +0 -0
  246. {openproj-0.77.2 → openproj-0.78.0}/tests/marionette.py +0 -0
  247. {openproj-0.77.2 → openproj-0.78.0}/tests/pages.py +0 -0
  248. {openproj-0.77.2 → openproj-0.78.0}/tests/plans.py +0 -0
  249. {openproj-0.77.2 → openproj-0.78.0}/tests/test_auth.py +0 -0
  250. {openproj-0.77.2 → openproj-0.78.0}/tests/test_calendar.py +0 -0
  251. {openproj-0.77.2 → openproj-0.78.0}/tests/test_card.py +0 -0
  252. {openproj-0.77.2 → openproj-0.78.0}/tests/test_cascade.py +0 -0
  253. {openproj-0.77.2 → openproj-0.78.0}/tests/test_cli.py +0 -0
  254. {openproj-0.77.2 → openproj-0.78.0}/tests/test_coedit.py +0 -0
  255. {openproj-0.77.2 → openproj-0.78.0}/tests/test_config.py +0 -0
  256. {openproj-0.77.2 → openproj-0.78.0}/tests/test_credential.py +0 -0
  257. {openproj-0.77.2 → openproj-0.78.0}/tests/test_deck.py +0 -0
  258. {openproj-0.77.2 → openproj-0.78.0}/tests/test_delete.py +0 -0
  259. {openproj-0.77.2 → openproj-0.78.0}/tests/test_edges.py +0 -0
  260. {openproj-0.77.2 → openproj-0.78.0}/tests/test_exclusion.py +0 -0
  261. {openproj-0.77.2 → openproj-0.78.0}/tests/test_facets.py +0 -0
  262. {openproj-0.77.2 → openproj-0.78.0}/tests/test_gitdoor.py +0 -0
  263. {openproj-0.77.2 → openproj-0.78.0}/tests/test_graph_layout.py +0 -0
  264. {openproj-0.77.2 → openproj-0.78.0}/tests/test_harness.py +0 -0
  265. {openproj-0.77.2 → openproj-0.78.0}/tests/test_headers.py +0 -0
  266. {openproj-0.77.2 → openproj-0.78.0}/tests/test_help.py +0 -0
  267. {openproj-0.77.2 → openproj-0.78.0}/tests/test_highlight.py +0 -0
  268. {openproj-0.77.2 → openproj-0.78.0}/tests/test_hill.py +0 -0
  269. {openproj-0.77.2 → openproj-0.78.0}/tests/test_identity.py +0 -0
  270. {openproj-0.77.2 → openproj-0.78.0}/tests/test_index.py +0 -0
  271. {openproj-0.77.2 → openproj-0.78.0}/tests/test_injection.py +0 -0
  272. {openproj-0.77.2 → openproj-0.78.0}/tests/test_issues.py +0 -0
  273. {openproj-0.77.2 → openproj-0.78.0}/tests/test_mermaid.py +0 -0
  274. {openproj-0.77.2 → openproj-0.78.0}/tests/test_model.py +0 -0
  275. {openproj-0.77.2 → openproj-0.78.0}/tests/test_notes.py +0 -0
  276. {openproj-0.77.2 → openproj-0.78.0}/tests/test_parse.py +0 -0
  277. {openproj-0.77.2 → openproj-0.78.0}/tests/test_payload.py +0 -0
  278. {openproj-0.77.2 → openproj-0.78.0}/tests/test_pop.py +0 -0
  279. {openproj-0.77.2 → openproj-0.78.0}/tests/test_product.py +0 -0
  280. {openproj-0.77.2 → openproj-0.78.0}/tests/test_records.py +0 -0
  281. {openproj-0.77.2 → openproj-0.78.0}/tests/test_remote.py +0 -0
  282. {openproj-0.77.2 → openproj-0.78.0}/tests/test_render.py +0 -0
  283. {openproj-0.77.2 → openproj-0.78.0}/tests/test_schedule.py +0 -0
  284. {openproj-0.77.2 → openproj-0.78.0}/tests/test_search.py +0 -0
  285. {openproj-0.77.2 → openproj-0.78.0}/tests/test_seats.py +0 -0
  286. {openproj-0.77.2 → openproj-0.78.0}/tests/test_socket_offer.py +0 -0
  287. {openproj-0.77.2 → openproj-0.78.0}/tests/test_status_gate.py +0 -0
  288. {openproj-0.77.2 → openproj-0.78.0}/tests/test_store.py +0 -0
  289. {openproj-0.77.2 → openproj-0.78.0}/tests/test_tailnet.py +0 -0
  290. {openproj-0.77.2 → openproj-0.78.0}/tests/test_teaching.py +0 -0
  291. {openproj-0.77.2 → openproj-0.78.0}/tests/test_themes.py +0 -0
  292. {openproj-0.77.2 → openproj-0.78.0}/tests/test_validate.py +0 -0
  293. {openproj-0.77.2 → openproj-0.78.0}/tests/test_web.py +0 -0
  294. {openproj-0.77.2 → openproj-0.78.0}/tests/test_writes.py +0 -0
  295. {openproj-0.77.2 → openproj-0.78.0}/tests/wsclient.py +0 -0
  296. {openproj-0.77.2 → openproj-0.78.0}/tools/README.md +0 -0
  297. {openproj-0.77.2 → openproj-0.78.0}/tools/build-excalidraw.mjs +0 -0
  298. {openproj-0.77.2 → openproj-0.78.0}/tools/excalidraw-entry.js +0 -0
  299. {openproj-0.77.2 → openproj-0.78.0}/tools/excalidraw-package-lock.json +0 -0
  300. {openproj-0.77.2 → openproj-0.78.0}/tools/excalidraw-package.json +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: openproj
3
- Version: 0.77.2
3
+ Version: 0.78.0
4
4
  Summary: Shape Up planning kept as markdown records in a git repository
5
5
  Project-URL: Homepage, https://github.com/jcanton/openproj
6
6
  Project-URL: Source, https://github.com/jcanton/openproj
@@ -9,7 +9,8 @@ directory.
9
9
  A button above the editor opens a menu: **+ drawing**, and under it the drawings
10
10
  this body already embeds, listed by id in the order they appear. Press one and
11
11
  Excalidraw opens over the editor with that drawing in it. Save, and the file is
12
- rewritten in place; the body is not touched at all.
12
+ rewritten in place; the body is not touched at all. Save keeps the drawing open — Close
13
+ is the one way back to the record.
13
14
 
14
15
  An embed is ordinary image markdown:
15
16
 
@@ -352,10 +353,10 @@ existing drawing and closing it untouched, and drawing, saving, then closing.
352
353
  The first holds because the comparison's baseline is `initial.elements` — what
353
354
  was actually handed to Excalidraw to mount, not a second read taken back off
354
355
  it — so a fresh, untouched mount reads as identical to itself. The second
355
- holds structurally: a successful save calls the raw `teardown()` directly
356
- rather than the close-attempt path that asks, because there is nothing left
357
- in the popup for the person to lose once their strokes are already on the
358
- server. Escape is two levels, matching the delete flow's own
356
+ holds because a successful save makes what it saved the new baseline, so Close
357
+ straight after it compares the scene against itself. (Until 2026-10-20 it held
358
+ structurally instead: a successful save called the raw `teardown()` and there
359
+ was no Close left to press — see "Save is a checkpoint".) Escape is two levels, matching the delete flow's own
359
360
  (`detail.py:1959-1962`): with the question up it backs out of the question,
360
361
  and only with no question up does it close the popup — bound as one branch of
361
362
  the same `document`-level `keydown` listener the popup already had, rather
@@ -626,6 +627,37 @@ already zlib-compressed so git cannot delta it and every save is a full new blob
626
627
  Cloud Run the filesystem is memory. `MAX_DRAWING_BYTES`' sentence now names images first,
627
628
  because images are the only thing that gets a drawing near it.
628
629
 
630
+ ## Save is a checkpoint
631
+
632
+ jcanton, 2026-10-20: "clicking 'save' on an excalidraw drawing closes the drawing and goes
633
+ back to the record. can we only make it save instead?" Closing on save made every
634
+ checkpoint cost a reopen through the menu. Save no longer calls `teardown()`; four things
635
+ that close-on-save had been hiding came with it.
636
+
637
+ - **A new drawing becomes an existing one at its first save.** `entry` is set from the
638
+ POST's answer and the etag kept, so the next Save is a PUT against the version just
639
+ written and splices nothing. Without it a second Save would mint a second drawing and
640
+ splice a second embed.
641
+ - **One save in flight.** Save is disabled from press to answer: a double click on a new
642
+ drawing would otherwise POST twice before the first answer arrived.
643
+ - **The sentence is said inside the popup.** `#state` is in the commit bar under the
644
+ overlay — dimmed at the smaller size and covered at full page. That cost nothing while a
645
+ successful save uncovered it. `#draw-said`, between the size toggle and Save, carries the
646
+ same sentence for the eyes; `#state` stays the live region, so it is announced once. It
647
+ empties at the first real stroke after a save, through `onChange` gated on `isDirty`,
648
+ because a bar that still says "saved" over unsaved strokes is lying. The check runs only
649
+ while the sentence is up, so it costs one comparison per save, not one per pointer move.
650
+ - **`api.focusContainer()` never existed.** The size toggle, Keep drawing and now Save
651
+ hand the keyboard back to the drawing. All three called `api.focusContainer()`, and the
652
+ object `excalidrawAPI` hands over has no such key — `focusContainer` is a method of
653
+ Excalidraw's internal `App`. Every call threw a TypeError that nobody saw: the tests
654
+ pressed those buttons with `.click()`, which never moves focus off the drawing in the
655
+ first place. Found when a save started calling it and the probe read "that drawing was
656
+ not saved — api.focusContainer is not a function". `focusDrawing` focuses
657
+ `.excalidraw-container` (`tabIndex: 0`, the element `App.focusContainer` focuses), and
658
+ `test_save_keeps_the_drawing_open_and_saving_again_rewrites_the_same_file` presses Save
659
+ with a trusted click so it can tell.
660
+
629
661
  ## A re-save has to say so
630
662
 
631
663
  The path is stable and a re-save does not touch the body — that is the design, and it
@@ -194,6 +194,7 @@ in the same commit that marks the source. **Delete** asks first.
194
194
 
195
195
  The button beside the image button opens a drawing canvas; what you draw is saved as a PNG in the
196
196
  plan repository and referenced from the body, so a sketch on a pitch is versioned with the pitch.
197
+ Save keeps the canvas open, so you can save as you go; Close takes you back to the record.
197
198
  You can drop or paste a picture straight into the canvas and draw on top of it — a photograph is
198
199
  scaled down to 1440px on the way in, so one fits comfortably inside the 2 MB a drawing may weigh.
199
200
  Three or four full-size pictures in the same drawing will not, and the Save button says so and
@@ -41,7 +41,7 @@ name = "openproj"
41
41
  # uploaded, so a missing README is missing until the next release.
42
42
  readme = "README.md"
43
43
  requires-python = ">=3.12"
44
- version = "0.77.2"
44
+ version = "0.78.0"
45
45
 
46
46
  # The one entry point, and what makes `uvx openproj new …` work without anything
47
47
  # being installed: uv builds the wheel into a throwaway environment and runs this.
@@ -1,3 +1,3 @@
1
1
  """openproj: Shape Up planning kept as markdown records in a git repository."""
2
2
 
3
- __version__ = "0.77.2"
3
+ __version__ = "0.78.0"
@@ -2677,6 +2677,17 @@ function drawPopup(label) {
2677
2677
  bigger.type = 'button';
2678
2678
  bigger.id = 'draw-size';
2679
2679
  bigger.className = 'grow';
2680
+ // What the last press of Save came to, said inside the popup. `#state` is
2681
+ // where every sentence of `openDrawing`'s goes and where a screen reader
2682
+ // hears it, and it is in the commit bar UNDER the overlay — invisible at full
2683
+ // page and dimmed behind the backdrop at the smaller size. That cost nothing
2684
+ // while a successful save closed the popup and uncovered it; with Save
2685
+ // leaving the drawing open, the confirmation has to be where the person is
2686
+ // looking. No `role` of its own: `#state` already announces the same
2687
+ // sentence, and two live regions would say it twice.
2688
+ const said = document.createElement('span');
2689
+ said.id = 'draw-said';
2690
+ said.className = 'said';
2680
2691
  const save = document.createElement('button');
2681
2692
  save.type = 'button';
2682
2693
  save.id = 'draw-save';
@@ -2694,7 +2705,7 @@ function drawPopup(label) {
2694
2705
  // bar is `justify-content: flex-end`, so a plain `order` would have moved all
2695
2706
  // three. Apart from the two that END the session, because this one only
2696
2707
  // changes how much room they have.
2697
- head.append(bigger, save, close);
2708
+ head.append(bigger, said, save, close);
2698
2709
  // The question a close attempt over unsaved strokes raises, in place of
2699
2710
  // Save and Close rather than beside them — built once, here, so it exists
2700
2711
  // before there is ever anything to ask about. See `openDrawing`'s own
@@ -2721,7 +2732,7 @@ function drawPopup(label) {
2721
2732
  stage.className = 'drawstage';
2722
2733
  box.append(head, stage);
2723
2734
  overlay.append(box);
2724
- return {overlay, box, stage, head, bigger, save, close, ask, keep, discard};
2735
+ return {overlay, box, stage, head, bigger, said, save, close, ask, keep, discard};
2725
2736
  }
2726
2737
 
2727
2738
  // One popup at a time. Nothing stops a second `openproj:draw` firing while the
@@ -2756,10 +2767,25 @@ async function openDrawing(surface, status, entry) {
2756
2767
  }
2757
2768
  DRAWING_OPEN = true;
2758
2769
  const button = document.getElementById('drawing');
2759
- const {overlay, box, stage, head, bigger, save, close, ask, keep, discard} = drawPopup(
2770
+ const {overlay, box, stage, head, bigger, said, save, close, ask, keep, discard} = drawPopup(
2760
2771
  entry ? `Editing ${entry.id}` : 'A new drawing'
2761
2772
  );
2762
2773
  document.body.appendChild(overlay);
2774
+ // Every sentence below, in the two places it has to be: `#state` for the
2775
+ // page and the screen reader, and the popup's own bar for the eyes.
2776
+ const say = text => {
2777
+ status.textContent = text;
2778
+ said.textContent = text;
2779
+ };
2780
+ // The keyboard back into the drawing, after a press on the popup's own
2781
+ // chrome. The container and not `api.focusContainer()`, which is what this
2782
+ // called until 2026-10-20 and which does not exist: `focusContainer` is a
2783
+ // method of Excalidraw's internal `App`, and the object `excalidrawAPI` hands
2784
+ // over carries no such key. Every call threw a TypeError that nothing saw,
2785
+ // because the tests pressed these buttons with `.click()`, which never moves
2786
+ // focus off the drawing in the first place. `.excalidraw-container` is the
2787
+ // element `App.focusContainer` focuses — `tabIndex: 0`, Excalidraw's own.
2788
+ const focusDrawing = () => stage.querySelector('.excalidraw-container')?.focus();
2763
2789
 
2764
2790
  // Which size the popup opens at, remembered the way the theme, the palette and
2765
2791
  // the table's widths are: somebody who wants the drawing editor big wants it
@@ -2789,17 +2815,20 @@ async function openDrawing(surface, status, entry) {
2789
2815
  // Excalidraw sizes its canvas from its container and watches it, so the
2790
2816
  // resize needs no telling — but the keyboard does: the press left focus on
2791
2817
  // this button, and the point of the press was to draw in the bigger box.
2792
- if (api) api.focusContainer();
2818
+ focusDrawing();
2793
2819
  };
2794
2820
 
2795
2821
  let root = null, api = null, etag = null, closed = false, mounted = null;
2822
+ // Whether the popup's bar is showing "saved" — the one sentence that a
2823
+ // later stroke makes untrue. See `onChange` below.
2824
+ let savedShown = false;
2796
2825
 
2797
2826
  // The raw close: unmounts and removes the overlay, no question asked. Every
2798
2827
  // caller below that already told the person what happened — a fetch that
2799
- // failed, a response that was refused, a save that just succeeded — calls
2800
- // THIS directly, because there is nothing of theirs left in the popup to
2801
- // lose. `closeAttempt`, further down, is the only path that asks first, and
2802
- // it is the one wired to Close and to Escape.
2828
+ // failed, a drawing that would not read back — calls THIS directly, because
2829
+ // there is nothing of theirs in the popup to lose. `closeAttempt`, further
2830
+ // down, is the only path that asks first, and it is the one wired to Close
2831
+ // and to Escape.
2803
2832
  function teardown() {
2804
2833
  if (closed) return;
2805
2834
  closed = true;
@@ -2857,6 +2886,7 @@ async function openDrawing(surface, status, entry) {
2857
2886
  // native `confirm()` would.
2858
2887
  const asking = state => {
2859
2888
  ask.hidden = !state;
2889
+ said.hidden = state;
2860
2890
  save.hidden = state;
2861
2891
  close.hidden = state;
2862
2892
  if (state) keep.focus();
@@ -2864,7 +2894,7 @@ async function openDrawing(surface, status, entry) {
2864
2894
  // Backing out of the question hands the keyboard back to the drawing, not to
2865
2895
  // a button that has just been hidden — without this, `document.activeElement`
2866
2896
  // falls to `<body>` and the next Escape is nobody's.
2867
- keep.onclick = () => { asking(false); if (api) api.focusContainer(); };
2897
+ keep.onclick = () => { asking(false); focusDrawing(); };
2868
2898
  discard.onclick = () => teardown();
2869
2899
 
2870
2900
  // The close a person actually presses: Close, or Escape with no question
@@ -2932,7 +2962,7 @@ async function openDrawing(surface, status, entry) {
2932
2962
  try {
2933
2963
  lib = await excalidraw(status);
2934
2964
  } catch (error) {
2935
- status.textContent = `the drawing editor could not be loaded — ${error.message}`;
2965
+ say(`the drawing editor could not be loaded — ${error.message}`);
2936
2966
  teardown();
2937
2967
  return;
2938
2968
  }
@@ -2940,18 +2970,18 @@ async function openDrawing(surface, status, entry) {
2940
2970
 
2941
2971
  let initial = {elements: [], appState: {}, files: {}};
2942
2972
  if (entry) {
2943
- status.textContent = `opening ${entry.id}…`;
2973
+ say(`opening ${entry.id}…`);
2944
2974
  let response;
2945
2975
  try {
2946
2976
  response = await fetch(`/${entry.path}`);
2947
2977
  } catch (error) {
2948
- status.textContent = `${entry.path} could not be opened — ${error.message}`;
2978
+ say(`${entry.path} could not be opened — ${error.message}`);
2949
2979
  teardown();
2950
2980
  return;
2951
2981
  }
2952
2982
  if (closed) return;
2953
2983
  if (!response.ok) {
2954
- status.textContent = `${entry.path} could not be opened`;
2984
+ say(`${entry.path} could not be opened`);
2955
2985
  teardown();
2956
2986
  return;
2957
2987
  }
@@ -2965,12 +2995,12 @@ async function openDrawing(surface, status, entry) {
2965
2995
  try {
2966
2996
  loaded = await lib.loadSceneOrLibraryFromBlob(blob, null, null);
2967
2997
  } catch (error) {
2968
- status.textContent = `${entry.path} does not read back as a drawing — ${error.message}`;
2998
+ say(`${entry.path} does not read back as a drawing — ${error.message}`);
2969
2999
  teardown();
2970
3000
  return;
2971
3001
  }
2972
3002
  if (loaded.type !== lib.MIME_TYPES.excalidraw) {
2973
- status.textContent = `${entry.path} is a library file, not a drawing`;
3003
+ say(`${entry.path} is a library file, not a drawing`);
2974
3004
  teardown();
2975
3005
  return;
2976
3006
  }
@@ -3030,8 +3060,20 @@ async function openDrawing(surface, status, entry) {
3030
3060
  // call, which was written first and measured doing nothing at all:
3031
3061
  // `root.render` is React 18's, so it returns before the tree commits and
3032
3062
  // `api` is still `null` on the next line. `document.activeElement` was
3033
- // `<body>` and `r` did not pick the rectangle.
3063
+ // `<body>` and `r` did not pick the rectangle. (Nor would it have later:
3064
+ // `api` has no `focusContainer` at all — see `focusDrawing`.)
3034
3065
  autoFocus: true,
3066
+ // "saved" stops being true at the first real stroke after it, and a bar
3067
+ // that goes on saying it is the bar lying. Gated on `isDirty` and not on
3068
+ // `onChange` firing at all, which it does on pointer-move, selection and
3069
+ // scroll too (see `isDirty`'s own comment). Skipped entirely unless the
3070
+ // sentence is up, so a long session pays for the comparison once per
3071
+ // save, not once per pointer-move.
3072
+ onChange: () => {
3073
+ if (!savedShown || !isDirty()) return;
3074
+ savedShown = false;
3075
+ said.textContent = '';
3076
+ },
3035
3077
  }));
3036
3078
  // The baseline `isDirty` compares against: `initial.elements` is exactly
3037
3079
  // what Excalidraw was just told to mount — `[]` for a new drawing,
@@ -3040,10 +3082,28 @@ async function openDrawing(surface, status, entry) {
3040
3082
  // rather than "did the PERSON change anything".
3041
3083
  mounted = signature(initial.elements);
3042
3084
  save.disabled = false;
3043
- status.textContent = entry ? `editing ${entry.id}` : 'drawing a new picture';
3085
+ say(entry ? `editing ${entry.id}` : 'drawing a new picture');
3044
3086
 
3087
+ // One save in flight at a time. While a successful save closed the popup a
3088
+ // second press had nothing to land on; now that the drawing stays open, a
3089
+ // double click on a NEW drawing would POST twice — two files, two embeds
3090
+ // spliced at the caret — before the first answer turned `entry` into the
3091
+ // drawing it made.
3045
3092
  save.onclick = async () => {
3093
+ save.disabled = true;
3094
+ try {
3095
+ await saveScene();
3096
+ } finally {
3097
+ save.disabled = false;
3098
+ }
3099
+ };
3100
+
3101
+ async function saveScene() {
3046
3102
  const elements = api.getSceneElements();
3103
+ // Read now, before any `await`: Excalidraw mutates its elements in place,
3104
+ // so a signature taken after the round trip would count strokes drawn
3105
+ // DURING it as saved.
3106
+ const saving = signature(elements);
3047
3107
  const files = api.getFiles();
3048
3108
  const blob = await lib.exportToBlob({
3049
3109
  elements, files, mimeType: 'image/png',
@@ -3063,12 +3123,12 @@ async function openDrawing(surface, status, entry) {
3063
3123
  // — so the advice names them first. A dropped photograph is downscaled to
3064
3124
  // 1440px on the way in and one of those fits with room to spare; three or
3065
3125
  // four in one drawing do not.
3066
- status.textContent = `that drawing is ${Math.ceil(blob.size / 1024)} KB; the limit `
3126
+ say(`that drawing is ${Math.ceil(blob.size / 1024)} KB; the limit `
3067
3127
  + `is ${MAX_DRAWING_BYTES / 1024} KB — use fewer or smaller images, simplify it, `
3068
- + `or ask for the ceiling to be raised`;
3128
+ + `or ask for the ceiling to be raised`);
3069
3129
  return;
3070
3130
  }
3071
- status.textContent = 'saving…';
3131
+ say('saving…');
3072
3132
  // An upload is a commit like any other, so the shell's banner is told
3073
3133
  // before it starts and told its sha afterwards — both save paths commit,
3074
3134
  // a re-save of an existing drawing as much as a new one, and without this
@@ -3093,11 +3153,11 @@ async function openDrawing(surface, status, entry) {
3093
3153
  // open with the drawing still in it: a conflict dialog that also
3094
3154
  // throws away the work it refused would be the worse of the two
3095
3155
  // losses, and there is nothing else here that could show it again.
3096
- status.textContent = refusal(answer, 409);
3156
+ say(refusal(answer, 409));
3097
3157
  return;
3098
3158
  }
3099
3159
  if (!response.ok) {
3100
- status.textContent = refusal(answer, response.status);
3160
+ say(refusal(answer, response.status));
3101
3161
  return;
3102
3162
  }
3103
3163
  committed = answer.commit;
@@ -3110,29 +3170,39 @@ async function openDrawing(surface, status, entry) {
3110
3170
  // undo-safe boundary `attachUploads` writes an upload's path through.
3111
3171
  const {from, to} = surface.caret();
3112
3172
  surface.splice(from, to, `![](${answer.path})`);
3113
- } else {
3114
- etag = `"${answer.etag}"`;
3173
+ // From here on this popup is editing an EXISTING drawing: the next
3174
+ // Save is a PUT against the version just written, and splices nothing.
3175
+ entry = {id: answer.id, path: answer.path};
3176
+ overlay.setAttribute('aria-label', `Editing ${answer.id}`);
3115
3177
  }
3116
- status.textContent = `${answer.path} saved`;
3117
- // Said before `teardown`, and for both arms rather than only the re-save
3118
- // that needs it: a brand-new drawing has no picture on the page yet, so
3119
- // this finds nothing and costs a walk of `document.images`. One call at
3120
- // the one place the bytes change beats a condition that has to stay
3121
- // true.
3178
+ etag = `"${answer.etag}"`;
3179
+ // **Save saves; it does not close.** jcanton, 2026-10-20: "clicking
3180
+ // 'save' on an excalidraw drawing closes the drawing and goes back to
3181
+ // the record. can we only make it save instead?" A save mid-drawing is a
3182
+ // checkpoint, and closing on it made every checkpoint cost a reopen
3183
+ // through the menu. Close is still the one way out.
3184
+ //
3185
+ // What was saved is the new baseline for `isDirty`, so Close straight
3186
+ // after a save asks nothing — there is nothing left to lose — and
3187
+ // strokes drawn after it are unsaved again.
3188
+ mounted = saving;
3189
+ say(`${answer.path} saved`);
3190
+ savedShown = true;
3191
+ // For both arms rather than only the re-save that needs it: a brand-new
3192
+ // drawing has no picture on the page yet, so this finds nothing and
3193
+ // costs a walk of `document.images`. One call at the one place the bytes
3194
+ // change beats a condition that has to stay true.
3122
3195
  refreshDrawing(answer.path);
3123
- // `teardown`, not `closeAttempt`: a save that just succeeded put every
3124
- // stroke on the server, so there is nothing left for `isDirty` to
3125
- // protect — asking here would be asking whether to discard work that
3126
- // is already safe. This is also draw-Save-then-Close's whole answer:
3127
- // Save already closes the popup on success, so there is no separate
3128
- // Close press left for a question to interrupt.
3129
- teardown();
3196
+ // The press left the keyboard on Save; the person saving mid-drawing
3197
+ // wants it back in the drawing, for the same reason the size toggle
3198
+ // hands it back.
3199
+ focusDrawing();
3130
3200
  } catch (error) {
3131
- status.textContent = `that drawing was not saved — ${error.message}`;
3201
+ say(`that drawing was not saved — ${error.message}`);
3132
3202
  } finally {
3133
3203
  dispatchEvent(new CustomEvent('openproj:wrote', {detail: committed}));
3134
3204
  }
3135
- };
3205
+ }
3136
3206
  }
3137
3207
 
3138
3208
  // Every picture on the page showing `path`, asked for again.
@@ -1747,6 +1747,12 @@ article.record .toolrow .commitbar {
1747
1747
  justify-content: center; line-height: 0;
1748
1748
  }
1749
1749
  .drawhead .grow svg { display: block; width: 15px; height: 15px; }
1750
+ /* What the last Save came to, between the size toggle and Save — the toggle's
1751
+ `margin-right: auto` puts it against Save rather than against the left edge.
1752
+ `min-width: 0` so a long refusal wraps inside the bar instead of pushing Save
1753
+ and Close off it. No `display` here, so the UA's `[hidden]` still wins while
1754
+ the unsaved-strokes question has the bar. */
1755
+ .drawhead .said { min-width: 0; font-size: 13px; color: var(--muted); }
1750
1756
  .drawhead .drawask { display: flex; align-items: center; gap: .5rem; }
1751
1757
  .drawhead .drawask[hidden] { display: none; }
1752
1758
  .drawhead .drawask .asking { margin: 0; font-size: 13px; color: var(--danger); }
@@ -10198,6 +10198,30 @@ def _until(call, expression: str, seconds: float = 20) -> object:
10198
10198
  raise AssertionError(f"never became true within {seconds}s: {expression}")
10199
10199
 
10200
10200
 
10201
+ SAVED = (
10202
+ "/^drawings\\/draw-[0-9a-f]{6}\\.png saved$/"
10203
+ ".test(document.getElementById('draw-said').textContent)"
10204
+ )
10205
+
10206
+
10207
+ def _saved_and_closed(call, seconds: float = 20) -> None:
10208
+ """Save, wait for the popup's own bar to say it landed, then Close. Save
10209
+ leaves the drawing open since jcanton asked for it to on 2026-10-20, so the
10210
+ tests that drove a save and waited for the popup to vanish now wait for the
10211
+ sentence instead — and Close straight after a save must close outright,
10212
+ with no unsaved-strokes question, or the save did not reset the baseline."""
10213
+ _evaluated(call, "document.getElementById('draw-save').click()")
10214
+ try:
10215
+ _until(call, SAVED, seconds=seconds)
10216
+ except AssertionError:
10217
+ said = _evaluated(call, "document.getElementById('draw-said').textContent")
10218
+ raise AssertionError(f"the save did not land: {said!r}") from None
10219
+ _evaluated(call, "document.getElementById('draw-close').click()")
10220
+ assert _until(call, "!document.querySelector('.drawpopup')"), (
10221
+ "Close straight after a save did not close the popup"
10222
+ )
10223
+
10224
+
10201
10225
  def _png_text_chunks(data: bytes) -> dict[bytes, bytes]:
10202
10226
  """Every `tEXt` chunk's key and value, read by walking the file's own
10203
10227
  chunk structure rather than trusted from a comment about what
@@ -10777,10 +10801,7 @@ def test_a_drawing_is_created_reopened_and_a_resave_touches_no_markdown(
10777
10801
  original_body = _evaluated(call, "SURFACE.text()")
10778
10802
  assert "drawings/draw-" not in original_body, "the body already named a drawing"
10779
10803
 
10780
- _evaluated(call, "document.getElementById('draw-save').click()")
10781
- assert _until(call, "!document.querySelector('.drawpopup')"), (
10782
- "the popup did not close itself after a successful save"
10783
- )
10804
+ _saved_and_closed(call)
10784
10805
  after_create = _evaluated(call, "SURFACE.text()")
10785
10806
  match = re.search(r"draw-[0-9a-f]{6}", after_create)
10786
10807
  assert match, f"no drawing id landed in the body: {after_create!r}"
@@ -10874,6 +10895,127 @@ def test_a_drawing_is_created_reopened_and_a_resave_touches_no_markdown(
10874
10895
  assert not [line for line in said if "Content Security Policy" in line], said
10875
10896
 
10876
10897
 
10898
+ def test_save_keeps_the_drawing_open_and_saving_again_rewrites_the_same_file(
10899
+ live_server: str, # noqa: F811 — a fixture, shadowing its own import by design
10900
+ tmp_path: Path,
10901
+ ):
10902
+ """jcanton, 2026-10-20: "clicking 'save' on an excalidraw drawing closes the
10903
+ drawing and goes back to the record. can we only make it save instead?"
10904
+
10905
+ Save is a checkpoint now, and staying open is the easy half. The four
10906
+ things that come with it are what this walks, each of which the old
10907
+ close-on-save made unreachable:
10908
+
10909
+ 1. a double press on a NEW drawing posts once — two POSTs would be two
10910
+ files and two embeds spliced at the caret;
10911
+ 2. "saved" is said inside the popup, where it can be seen, and not only in
10912
+ `#state`, which is under the overlay;
10913
+ 3. a second save from the same popup rewrites the file the first one made —
10914
+ a PUT, splicing nothing — rather than minting a second drawing;
10915
+ 4. "saved" goes away at the next stroke, the keyboard goes back into the
10916
+ drawing, and Close straight after a save asks nothing, because what was
10917
+ saved is the new baseline.
10918
+ """
10919
+ url = f"{live_server}/detail/{TASK}?both"
10920
+ with _devtools(chrome(), url, tmp_path / "profile", DRAWING_WINDOW) as (call, said):
10921
+ time.sleep(2)
10922
+ _evaluated(call, "document.getElementById('drawing').click()")
10923
+ _evaluated(call, "document.querySelector('.drawmenu button').click()")
10924
+ _until(call, "!!document.querySelector('.drawpopup .excalidraw')")
10925
+ _evaluated(call, "document.querySelector('[data-testid=\"toolbar-rectangle\"]').click()")
10926
+ _drag(call, *FIRST_SHAPE)
10927
+ time.sleep(0.2)
10928
+ original_body = _evaluated(call, "SURFACE.text()")
10929
+
10930
+ _evaluated(
10931
+ call,
10932
+ "document.getElementById('draw-save').click();"
10933
+ "document.getElementById('draw-save').click();",
10934
+ )
10935
+ _until(call, SAVED)
10936
+ stayed = _evaluated(
10937
+ call,
10938
+ """
10939
+ (() => {
10940
+ const line = document.getElementById('draw-said');
10941
+ const box = line.getBoundingClientRect();
10942
+ const hit = document.elementFromPoint(box.left + box.width / 2, box.top + box.height / 2);
10943
+ return {
10944
+ open: !!document.querySelector('.drawpopup .excalidraw'),
10945
+ seen: box.width > 0 && hit === line,
10946
+ saveUsable: !document.getElementById('draw-save').disabled,
10947
+ label: document.querySelector('.drawpopup').getAttribute('aria-label'),
10948
+ };
10949
+ })()
10950
+ """,
10951
+ )
10952
+ body = _evaluated(call, "SURFACE.text()")
10953
+ embeds = re.findall(r"drawings/(draw-[0-9a-f]{6})\.png", body)
10954
+ assert len(embeds) == 1, f"one double-pressed Save spliced {len(embeds)} embeds: {body!r}"
10955
+ drawing_id = embeds[0]
10956
+ assert body == f"![](drawings/{drawing_id}.png){original_body}", body
10957
+ assert stayed == {
10958
+ "open": True,
10959
+ "seen": True,
10960
+ "saveUsable": True,
10961
+ "label": f"Editing {drawing_id}",
10962
+ }, stayed
10963
+
10964
+ _evaluated(call, "document.querySelector('[data-testid=\"toolbar-ellipse\"]').click()")
10965
+ _drag(call, *SECOND_SHAPE)
10966
+ assert _until(call, "document.getElementById('draw-said').textContent === ''"), (
10967
+ "the popup went on saying 'saved' over a stroke that was not"
10968
+ )
10969
+
10970
+ # Pressed for real this time, not with `.click()`: only a trusted press
10971
+ # puts the keyboard on Save, and handing it back to the drawing is the
10972
+ # point of saving mid-drawing. It is also what found `api.focusContainer`
10973
+ # did not exist — every `.click()` left focus where it already was.
10974
+ x, y = _evaluated(
10975
+ call,
10976
+ "(() => { const b = document.getElementById('draw-save').getBoundingClientRect();"
10977
+ " return [b.left + b.width / 2, b.top + b.height / 2]; })()",
10978
+ )
10979
+ for kind, buttons in (("mousePressed", 1), ("mouseReleased", 0)):
10980
+ call(
10981
+ "Input.dispatchMouseEvent",
10982
+ {
10983
+ "type": kind,
10984
+ "x": x,
10985
+ "y": y,
10986
+ "button": "left",
10987
+ "buttons": buttons,
10988
+ "clickCount": 1,
10989
+ },
10990
+ )
10991
+ _until(call, SAVED)
10992
+ assert _evaluated(
10993
+ call, "!!(document.activeElement && document.activeElement.closest('.excalidraw'))"
10994
+ ), "a save left the keyboard on Save rather than handing it back to the drawing"
10995
+ assert _evaluated(call, "SURFACE.text()") == body, (
10996
+ "the second save from the same popup touched the markdown — it minted a "
10997
+ "new drawing instead of rewriting the one the first save made"
10998
+ )
10999
+ round_trip = _evaluated(
11000
+ call,
11001
+ f"""
11002
+ (async () => {{
11003
+ const blob = await (await fetch('/drawings/{drawing_id}.png')).blob();
11004
+ const loaded = await EXCALIDRAW.loadSceneOrLibraryFromBlob(blob, null, null);
11005
+ return loaded.data.elements.map(e => e.type);
11006
+ }})()
11007
+ """,
11008
+ )
11009
+ assert round_trip == ["rectangle", "ellipse"], round_trip
11010
+
11011
+ _evaluated(call, "document.getElementById('draw-close').click()")
11012
+ assert _evaluated(call, "!document.querySelector('.drawpopup')"), (
11013
+ "Close straight after a save asked about unsaved strokes — the save "
11014
+ "did not become the baseline"
11015
+ )
11016
+ assert not [line for line in said if "Content Security Policy" in line], said
11017
+
11018
+
10877
11019
  def test_a_stale_save_is_refused_and_the_popup_keeps_the_work(
10878
11020
  live_server: str, # noqa: F811 — a fixture, shadowing its own import by design
10879
11021
  tmp_path: Path,
@@ -10898,8 +11040,7 @@ def test_a_stale_save_is_refused_and_the_popup_keeps_the_work(
10898
11040
  _evaluated(call, "document.querySelector('[data-testid=\"toolbar-rectangle\"]').click()")
10899
11041
  _drag(call, *FIRST_SHAPE)
10900
11042
  time.sleep(0.2)
10901
- _evaluated(call, "document.getElementById('draw-save').click()")
10902
- assert _until(call, "!document.querySelector('.drawpopup')")
11043
+ _saved_and_closed(call)
10903
11044
 
10904
11045
  body = _evaluated(call, "SURFACE.text()")
10905
11046
  drawing_id = re.search(r"draw-[0-9a-f]{6}", body).group(0)
@@ -11005,10 +11146,7 @@ def test_closing_unsaved_strokes_asks_first_and_keep_drawing_preserves_them(
11005
11146
  )
11006
11147
  assert backed_out == {"popupThere": True, "asking": False, "saveHidden": False}, backed_out
11007
11148
 
11008
- _evaluated(call, "document.getElementById('draw-save').click()")
11009
- assert _until(call, "!document.querySelector('.drawpopup')"), (
11010
- "keep drawing left the popup unable to save cleanly afterward"
11011
- )
11149
+ _saved_and_closed(call)
11012
11150
  body = _evaluated(call, "SURFACE.text()")
11013
11151
  match = re.search(r"draw-[0-9a-f]{6}", body)
11014
11152
  assert match, f"no drawing id landed in the body: {body!r}"
@@ -11378,19 +11516,9 @@ def test_a_dropped_image_is_resized_and_saved_into_the_drawing(
11378
11516
  )
11379
11517
 
11380
11518
  # And the round trip, through the seam a person presses.
11381
- _evaluated(call, "document.getElementById('draw-save').click()")
11382
- try:
11383
- _until(call, "!document.querySelector('.drawpopup')", seconds=30)
11384
- except AssertionError:
11385
- # The popup staying open IS the refusal on this page, and the
11386
- # sentence it refused with is in the commit bar — read out here
11387
- # rather than left for somebody to go and find after a bare "the
11388
- # popup did not close". `MAX_DRAWING_BYTES` is the one this would
11389
- # most likely be.
11390
- said_so = _evaluated(call, "document.getElementById('upload').textContent")
11391
- raise AssertionError(
11392
- f"the save of the dropped {kind} was refused: {said_so!r}"
11393
- ) from None
11519
+ # A refusal is read out by the helper rather than left for somebody to
11520
+ # go and find; `MAX_DRAWING_BYTES` is the one this would most likely be.
11521
+ _saved_and_closed(call, seconds=30)
11394
11522
  body = _evaluated(call, "SURFACE.text()")
11395
11523
  match = re.search(r"draw-[0-9a-f]{6}", body)
11396
11524
  assert match, f"no drawing id landed in the body: {body[:120]!r}"
@@ -11454,8 +11582,7 @@ def test_resaving_a_drawing_refreshes_the_picture_beside_the_writing(
11454
11582
  _evaluated(call, "document.querySelector('[data-testid=\"toolbar-rectangle\"]').click()")
11455
11583
  _drag(call, *FIRST_SHAPE)
11456
11584
  time.sleep(0.2)
11457
- _evaluated(call, "document.getElementById('draw-save').click()")
11458
- _until(call, "!document.querySelector('.drawpopup')")
11585
+ _saved_and_closed(call)
11459
11586
 
11460
11587
  # The preview has to have DRAWN the picture before anything can be said
11461
11588
  # about it changing — `complete` alone is true for an image that failed,
@@ -11472,8 +11599,7 @@ def test_resaving_a_drawing_refreshes_the_picture_beside_the_writing(
11472
11599
  _evaluated(call, "document.querySelector('[data-testid=\"toolbar-ellipse\"]').click()")
11473
11600
  _drag(call, *SECOND_SHAPE)
11474
11601
  time.sleep(0.2)
11475
- _evaluated(call, "document.getElementById('draw-save').click()")
11476
- _until(call, "!document.querySelector('.drawpopup')")
11602
+ _saved_and_closed(call)
11477
11603
 
11478
11604
  # The body is untouched, which is the whole reason this bug existed: if
11479
11605
  # a re-save ever starts splicing, the preview refreshes for a different
@@ -5473,7 +5473,12 @@ def test_a_reparent_leaves_no_derived_column_stale(client: TestClient, page: str
5473
5473
  # DOM does not gather a nested span's text into its parent's `textContent`
5474
5474
  # the way a browser does, so the year may or may not be in what comes back.
5475
5475
  assert got["start"].startswith(f"{day}.{month}"), got["start"]
5476
- assert year[:2] not in got["start"], "the century is still being drawn"
5476
+ # Asked of what FOLLOWS the day and month, never of the whole cell: the
5477
+ # start here is derived from today, and on the twentieth of any month the
5478
+ # day itself is `20` — so `'20' not in '20.10'` failed on 2026-10-20 with
5479
+ # nothing drawn wrong. A century, if one were drawn, can only be after it.
5480
+ trailing = got["start"][len(f"{day}.{month}") :]
5481
+ assert year[:2] not in trailing, "the century is still being drawn"
5477
5482
 
5478
5483
 
5479
5484
  def test_a_column_is_dragged_in_the_header_and_a_row_in_the_body(page: str):