chore: remove legacy compatibility and upgrade paths before release - #1541
Merged
Merged
Conversation
Nothing has shipped yet, so drop the code that only existed to carry data or callers forward from earlier builds: - Frontend: the startup IndexedDB document/worldbuilding storage migration, the localStorage elements import, the fixed 'cover' media key fallbacks, the pre-tabs opened-documents restore, the 'Local Mode' display-name alias, the cloud manifest's single 'profile' field, the unprefixed auth_token cleanup, and dead aliases/shims (createExtendedSchema, side-nav projects input, filteredProjects, timeline test aliases, hidden timeline combined inputs, unused image-grid styles). - Archives: reset ARCHIVE_VERSION to 1 with an empty migration registry; the v1 format now includes time systems and per-element schema copies. - Backend: drop the owner-only access path for Durable Objects without a D1 binding (fail closed instead), the node /providers endpoint and the deprecated computeStreaks/findTombstones helpers. - Reword comments that called live behaviour 'legacy'.
Contributor
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Repository: bobbyquantum/inkweld/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
- E2E: seed covers under cover-<ms> ids and expect archive version 1. - Drop the empty archive migration registry; import accepts only the current ARCHIVE_VERSION until a format change needs an upgrade step. - Move the DO HTTP access check into authorizeHttpAccess to keep the handler's complexity down, with tests for the no-D1, forbidden and read-only-write responses. - Cover the id-keyed cover cache, the export's cover download and the import's cover upload. - Leave the OpenRouter modality comment as it was.
…ompat-cleanup # Conflicts: # backend/src/durable-objects/yjs-project.do.ts # frontend/src/app/services/local/document-storage-migration.service.ts # frontend/src/app/services/local/local-storage.service.ts # frontend/src/app/services/publish/epub-generator.service.ts # frontend/src/app/services/publish/html-generator.service.ts # frontend/src/app/services/publish/pdf-generator.service.ts
|
This branch was successfully 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.



Nothing has been released yet, so this removes code that only existed to carry data or callers forward from earlier builds.
Removed
Frontend local data
DocumentStorageMigrationServiceand its app initializer (copied bare-named IndexedDB prose/worldbuilding databases into profile-prefixed ones).localStorage(inkweld-local-elements) into Yjs.'cover'media-key fallbacks in the cover component, edit dialog, export, import and the EPUB/HTML/PDF generators, plus theLocalStorageServiceproject-cover convenience methods. Covers are now only addressed by theircover-<ms>media id.ProjectService.getProjectCoverno longer caches when it has no id.openedDocumentslist save/restore fallback.'Local Mode'→'Browser'display-name alias and the unprefixedauth_tokencleanup.profilefield.profilesis now the only list, and a manifest without one is rejected.Archives
ARCHIVE_VERSIONis reset to 1 and the archive migration registry (archive-migrations.ts,MIN_SUPPORTED_VERSION) is removed. Import accepts only the current version. The v1 format now includes time systems and per-element schema copies. When the format next changes, add an upgrade step to the import.Dead code and shims
createExtendedSchemaalias, the side-navprojectsinput,HomeComponent.filteredProjects, the timelinetrackHeight/axisYtest aliases, the hiddentimeline-event-start/endinputs, and unused.image-gridstyles./providersendpoint,computeStreaksandProjectService.findTombstones.Backend access
checkAccessLegacypath for a Durable Object with no D1 binding is gone. Withoutenv.DB, WebSocket auth is refused with 4403 and the DO HTTP API returns 503.Kept on purpose
MigrationService(moving Browser projects to a server) andProjectRenameMigrationService(project rename). Both are live features; only their misleading "legacy" comments changed.number[]rows and the trailing-slash diagnostics. The preview deployment's DO data predates theUint8Arrayformat and is being kept.SESSION_SECRETis the primary secret andDATABASE_KEYits override. The comments calling one "legacy" were wrong.media:scheme is the current prose-image form, not a legacy one.Comments that described live behaviour as "legacy" were reworded, and AGENTS.md and the archive docs were updated.
Testing
npm test, 391 files and 9,344 tests pass. Coverage thresholds are met.bun test, 1,787 pass.