PT9 import fails when interlinear data names a book the project has no text for

Aperta Adatta ai principianti
#655 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
78/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
typescript
Ambito
backend, testing

Direzione di ricerca

Inizia da importPt9Project in src/services/pt9ImportService.ts e segui come vengono gestiti gli errori di getBookUSJ quando manca un libro. La issue indica la fixture PIB e Interlinear_es_JAS.xml come riproduzione; controlla il rapporto di importazione per confermare che gli altri libri vengono convertiti e che JAS è segnalato con bookFound: false.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Importing a Paratext 9 project fails outright when one of its interlinear files is for a book that the project has no text for. The PIB test project reproduces it with Interlinear_es_JAS.xml.

Steps: in the select dialog for PIB, choose Import from Paratext 9.

Expected: the import converts the other books, and the report names JAS as a book with no text (bookFound: false). The PIB fixture is documented to produce exactly that.

Actual: the modal says the import failed, and the log shows:

Interlinearizer: failed to import Paratext 9 interlinear data
JSON-RPC Request error (-32000): Book number 59 not found in project B2B2…B2.

Where: importPt9Project in src/services/pt9ImportService.ts expects getBookUSJ to return nothing for a missing book and skips the book when it does. The platform throws instead, so the error escapes and fails the whole import. Treating that error as a missing book would restore the documented behavior. The unit tests mock getBookUSJ, so they don't catch this.

Found while testing #643 in-app.

Lingua principale
TypeScript
Stelle
2
Fork
0
Merge medio
1g 1h
PR unite (30g)
107

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di sillsdev/interlinearizer-extension

Tutte le issue di sillsdev/interlinearizer-extension

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.