Skip to content

refactor(json-document): unify replace validation#236

Open
developer-1px wants to merge 1 commit into
mainfrom
codex/reduce-patch-executors
Open

refactor(json-document): unify replace validation#236
developer-1px wants to merge 1 commit into
mainfrom
codex/reduce-patch-executors

Conversation

@developer-1px

Copy link
Copy Markdown
Owner

Summary

  • consolidate root-object, same-array, independent, and overlapping replace schema validation behind one final-target planner
  • remove the duplicate schema-side array and object replace executors and dead helpers, reducing production source by 610 LOC
  • preserve existing public failure ordering and fallback behavior while allowing later ancestor or descendant replacements to repair intermediate invalid values
  • harden schema introspection against inherited properties and custom standalone record-key checks

Verification

  • 538 tests passed, 4 skipped
  • typecheck, build, package smoke, layer check, standard conformance, and docs evaluation passed
  • differential checks: 48,400 independent batches and 19,872 dash/catchall batches with zero contract differences
  • adapter readiness passed: Editable p95 4.016ms / 14ms, Canvas single p95 0.328ms / 4ms, Canvas batch p95 5.107ms / 8ms
  • one noisy core wide-root sample measured 20.99ms / 20ms; 61-run interleaved comparison measured branch CPU p50 12.78ms versus main 15.36ms, indicating no refactor regression

Contract

  • no public API surface changes
  • legacy diagnostic ordering remains behind explicit compatibility fallbacks
  • overlapping replace batches validate effective final targets after one atomic apply

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant