Repository navigation
Migrate Writer to the production SDK-only backend - #43
Open
callumalpass wants to merge 1 commit into
Open
callumalpass wants to merge 1 commit into
callumalpass wants to merge 1 commit into
Conversation
This branch has not been deployed
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.
Summary
Migrate Writer to its existing SDK-only backend so weekly production-verified repins need no backend migration. UI and i18n are now exactly
0.1.0-beta.148.Legacy callers and their replacements
LegacyApp,ConnectBackend, its Connect application session, gates/picker and unused sign-in/popup preparation. All ordinary builds use the SDK application entry andNativeWriterBackend; absent environment defaults to production, as the manifest builder does. Explicit environment/origin checks still refuse mismatches. No fallback or opt-in backend flag.connect-testing/ synthetic legacy queries to the retained SDK'sMemoryReplica, using the same native backend. Fixture-only catalog and array-type derivation fill gaps in MemoryReplica, not in the production SDK. Browser fault injection now uses public SDK/replica APIs.DraftStoreconsumes persisted browser backups. Connected namespaces remain collection IDs; the demo namespace remainsdemo. This is application data, not a protocol compatibility shim.The SDK original
sdk-eaa4e697-production-beta141.tgzis unchanged (SHA256e64771a90bed2fb3837d4b65df8930fcd124d3059fcb0bcbaf9d64dbfb148205). No SDK changes or repacking. The matching protocol original remains for manifest validation and publisher custody checks. Removed the beta.125 Connect dependency/override, connect-dev/testing dependencies, both query-patched archives and their patch/pin sidecars. No unrelated dependencies changed.PR #16 was inspected. Its structural workspace session interface is already present on main and retained; its older SDK, proposed control plane, custom session engine and opt-in dual-backend design are not revived.
Flow corrections found during migration
Publisher inputs
config/native-publish/production.jsonbinds npm UI beta.148's exact version, SHA512 SRI and tarball SHA256. Native intake supports that registry pin and checks its frozen importer/resolution and installed package identity; SDK/protocol complete-member and producer provenance/trust checks remain intact. The npm UI install is SRI-verified, rather than claiming an archived UI member inventory. Tamper tests cover version, SRI and protected-hash substitutions. Synthetic CI-unit verification uses the current production inputs without hard-coded member counts that would obstruct later SDK repins.Before a future authorized production publication, the protected
writer-productionenvironment'sNATIVE_UI_SHA256must match the new approved value56f51e9dce7cd83149fe99efbbbdb43203288f724ed6b6e019886e1c3d65ad75. This PR does not mutate GitHub environment variables or release branches.Historical staging package/lock snapshots intentionally remain unchanged: they are frozen publisher-test inputs, not Writer's active dependency graph. The separately qualified staging publisher still requires its own staging original intake; this PR does not retarget the production SDK to staging.
Verification completed before opening this PR
Finite pnpm checks/builds used the repo's pinned pnpm
11.15.1throughrpnpm(remote build runner); browser/local-service tests ran locally. Node22.22.0.pnpm install --lockfile-onlyandpnpm install --frozen-lockfile— passed; only the requested dependency changes in the lock.rpnpm check— passed strict ten-locale completeness/composition/source checks, typecheck and all normal suites: 646 passed, 7 existing skips (core 65 passed/4 skipped; app Node 80/2; app Vitest 274/1; root Node 227/0). Existing skips are optional Pandoc parity/materialization, sibling Reader/contracts checkout comparisons, and ZIP integration coverage; the real browser export tests also passed.rpnpm --pull apps/writer/dist build— passed, including manifest generation/validation and optimized production build.rpnpm ... build:productionalso passed.rpnpm --class build test:publisher:ci-unit— 282 passed, zero skipped, including original/provenance/installer/forgery tests and the actual current production intake.rpnpm --pull apps/writer/dist --filter @mdbase-writer/app build:editing-testand localtest:browser:editing— passed optimized React editing, cursor movement and undo/redo with a real Preview canvas.pnpm dev:test:browser— 56 baseline/reliability scenarios passed, including real PDF/DOCX/ZIP exports, typed-note adoption, annotations, conflicts, drafts, failures and recovery.test:browser:i18n— passed all ten locales, language negotiation/persistence, formatting, CodeMirror and failed-chunk retention.test:browser:a11y— passed 375px/1280px axe and keyboard/dialog focus scenarios.build:feedback-testplus local loopback preview andtest:feedback— passed desktop/mobile feedback; all delivery intercepted.rpnpm --class build --filter @mdbase-writer/app test --config scripts/perf/vitest.config.ts) — passed.git diff --checkand emptypnpm whyfor connect/connect-dev/connect-testing — passed.Independent static review completed; its adoption preservation findings were fixed directly with regression tests. No remaining migration blocker identified. These are deterministic/demo checks, not live connected-collection or native-device acceptance.
No merge, release/publish workflow dispatch, publication or deployment.