fix(pdf,tests): report:compare escapes control characters, prints names and free text only with --full, stats before read, missing file as a per-file failure; inferRegionCode regression test; import.ts JSDoc reattached

This commit is contained in:
bchanot committed 2026-10-10 15:53:07 +02:00
1 parent dc78a00835
commit b1b3e4927e
6 files changed
+257 -72

No files matched your search

+3 -3
View File
@@ -26,14 +26,14 @@ export class ImportError extends Error {
}
}
/** A Faunosteo PDF weighs a few hundred KB; anything larger is not one. */
export const MAX_PDF_BYTES = 50 * 1024 * 1024
/**
* Reads a Faunosteo PDF back into a report document (v3, or v2 migrated
* through the reference sheet's map). The outcome says whether a migration
* happened and how many zones or findings it could not place.
*/
/** A Faunosteo PDF weighs a few hundred KB; anything larger is not one. */
export const MAX_PDF_BYTES = 50 * 1024 * 1024
export async function importReportFromPdf(
pdfBytes: Uint8Array,
map: ReportMigrationMap,