Repository navigation
Commit 5b563bb
committed
feat: collision-bumped w:date stamping at changeset granularity (ISSUES.md #53)
One changeset (a single edit call, or one whole batch_edit/batch_rewrite
call) stamps one whole-second w:date, bumped past the previous stamp when
the same author's changesets collide in one real second. Parse-time group
reconstruction (#46) therefore never merges two of our own changesets;
same-paragraph ops of one batch call share their date and merge by design.
- xml_editor: _next_changeset_timestamp() allocates collision-bumped
stamps (monotonic per author, also across clock regressions);
frozen_timestamp() becomes reentrant-by-reuse so nested per-op freezes
join the enclosing batch changeset.
- track_changes: batch_edit/batch_rewrite wrap the whole call in one
frozen_timestamp() scope — one date per batch call, one group per op.
- tests: TestChangesetDateStamping pins the contract (shared batch date
under a ticking clock, no bump when seconds differ, bounded drift,
distinct dates for two batches in one second, nested freeze reuse,
w16du:dateUtc parity); the former same-second over-merge relaxation
flips into test_same_paragraph_same_second_two_groups.1 parent 12ae649 commit 5b563bb
5 files changed
Lines changed: 258 additions & 43 deletions
File tree
- docs
- docx_editor
- skills/docx
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
653 | 653 | | |
654 | 654 | | |
655 | 655 | | |
656 | | - | |
657 | | - | |
658 | | - | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
659 | 663 | | |
660 | 664 | | |
661 | 665 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
346 | 346 | | |
347 | 347 | | |
348 | 348 | | |
349 | | - | |
350 | | - | |
351 | | - | |
352 | | - | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
353 | 356 | | |
354 | 357 | | |
355 | 358 | | |
| |||
584 | 587 | | |
585 | 588 | | |
586 | 589 | | |
587 | | - | |
588 | | - | |
589 | | - | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
590 | 596 | | |
591 | 597 | | |
592 | 598 | | |
| |||
856 | 862 | | |
857 | 863 | | |
858 | 864 | | |
859 | | - | |
| 865 | + | |
| 866 | + | |
| 867 | + | |
860 | 868 | | |
861 | 869 | | |
862 | 870 | | |
| |||
901 | 909 | | |
902 | 910 | | |
903 | 911 | | |
904 | | - | |
905 | | - | |
906 | | - | |
907 | | - | |
908 | | - | |
909 | | - | |
910 | | - | |
911 | | - | |
912 | | - | |
| 912 | + | |
| 913 | + | |
| 914 | + | |
| 915 | + | |
| 916 | + | |
| 917 | + | |
| 918 | + | |
| 919 | + | |
| 920 | + | |
| 921 | + | |
| 922 | + | |
| 923 | + | |
913 | 924 | | |
914 | 925 | | |
915 | 926 | | |
| |||
1053 | 1064 | | |
1054 | 1065 | | |
1055 | 1066 | | |
| 1067 | + | |
| 1068 | + | |
| 1069 | + | |
1056 | 1070 | | |
1057 | 1071 | | |
1058 | 1072 | | |
| |||
1099 | 1113 | | |
1100 | 1114 | | |
1101 | 1115 | | |
1102 | | - | |
| 1116 | + | |
| 1117 | + | |
| 1118 | + | |
| 1119 | + | |
| 1120 | + | |
1103 | 1121 | | |
1104 | | - | |
1105 | | - | |
1106 | | - | |
1107 | | - | |
1108 | | - | |
| 1122 | + | |
| 1123 | + | |
| 1124 | + | |
| 1125 | + | |
| 1126 | + | |
| 1127 | + | |
1109 | 1128 | | |
1110 | 1129 | | |
1111 | 1130 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
1239 | 1239 | | |
1240 | 1240 | | |
1241 | 1241 | | |
| 1242 | + | |
| 1243 | + | |
| 1244 | + | |
1242 | 1245 | | |
1243 | 1246 | | |
1244 | 1247 | | |
| |||
1276 | 1279 | | |
1277 | 1280 | | |
1278 | 1281 | | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
| 1287 | + | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
| 1297 | + | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
1279 | 1301 | | |
1280 | 1302 | | |
1281 | 1303 | | |
| |||
1285 | 1307 | | |
1286 | 1308 | | |
1287 | 1309 | | |
1288 | | - | |
1289 | | - | |
| 1310 | + | |
| 1311 | + | |
| 1312 | + | |
| 1313 | + | |
| 1314 | + | |
| 1315 | + | |
| 1316 | + | |
| 1317 | + | |
1290 | 1318 | | |
1291 | 1319 | | |
1292 | | - | |
1293 | | - | |
| 1320 | + | |
| 1321 | + | |
| 1322 | + | |
1294 | 1323 | | |
1295 | 1324 | | |
1296 | 1325 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
502 | 502 | | |
503 | 503 | | |
504 | 504 | | |
505 | | - | |
506 | | - | |
507 | | - | |
508 | | - | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
509 | 511 | | |
510 | 512 | | |
511 | 513 | | |
| |||
0 commit comments