Add the Paratext 9 import service, storage, and commands - #268
Draft
jasonleenaylor wants to merge 2 commits into
Draft
Add the Paratext 9 import service, storage, and commands#268jasonleenaylor wants to merge 2 commits into
jasonleenaylor wants to merge 2 commits into
Conversation
Add an optional pt9Import provenance field (per-file hashes and the import timestamp) to InterlinearProject, and add the storage contract for imports: savePt9Import creates the source project's single import record or replaces it wholesale, keeping only id and createdAt; updateAnalysis and updateProjectMetadata reject pt9Import-carrying projects while deleteProject stays allowed; getPt9ImportForSource finds the one import for a source. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Add pt9ImportService.importPt9Project: fetch the source project's PT9 interlinear files through the platformScripture.Pt9Interlinear projectInterface, parse them, rebuild the text layer for each referenced book from the project's USJ, convert, and persist the outcome as the source's single frozen import project with a fixed localized name and description. An empty source aborts a first import and leaves an existing import unchanged with a warning. Register two commands: interlinearizer.importPt9Project (import or sync) and interlinearizer.createEditableCopy, which clones an import's analysis into a new editable project without import provenance. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
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 |
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.
Add the backend import pipeline for Paratext 9 interlinear data, stacked on
the converter (#240). Two commits: the storage layer, then the service and
commands.
hashes and the import timestamp). A project carrying it is frozen: storage
rejects every user write, and only the import's own save path replaces its
content. Deleting stays allowed.
project or replace it wholesale, keeping only id and createdAt),
getPt9ImportForSource, and createEditableCopy (clone an import's analysis
into a new editable project with no provenance).
platformScripture.Pt9Interlinear projectInterface (Add read-only PT9 interlinear projectInterface to the Paratext PDP paranext/paranext-core#2707),
parses them, rebuilds each referenced book's text layer from the project's
USJ, converts, and persists the result with a fixed localized name and
description. A source with no interlinear data aborts a first import and
leaves an existing import unchanged with a warning; only an explicit delete
removes an import.
and interlinearizer.createEditableCopy.
test-data XML fixtures verbatim while the real parsers and converter run,
so the tests exercise raw XML through to the persisted analysis and prove
the Pt9Interlinear wire shapes end to end.
Depends on paranext/paranext-core#2707 for the projectInterface at runtime;
the types compile against the local checkout.
🤖 Generated with Claude Code
This change is