From c09020c2fb01da24d5befbed78ce3b73b5efbe4c Mon Sep 17 00:00:00 2001 From: Lukasz Kasprzak Date: Mon, 14 Sep 2026 23:39:37 +0200 Subject: content tests are three-valued: unknown when unreadable or read in part --- internal/extract/extract.go | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'internal/extract/extract.go') diff --git a/internal/extract/extract.go b/internal/extract/extract.go index 7e3adec..0843c42 100644 --- a/internal/extract/extract.go +++ b/internal/extract/extract.go @@ -23,6 +23,11 @@ var ( // ErrUnsupported is returned when the format carries no text krino // knows how to extract. ErrUnsupported = errors.New("no text in this format") + // ErrPartial wraps the error of a document read only in part (an + // archive entry that would not open or parse). Text returns the text it + // did read along with it: a keyword found there is found, but one not + // found may be in the part that could not be read (plan 11). + ErrPartial = errors.New("part of it could not be read") // ErrTooLarge is returned when the file is larger than the configured // max-read; nothing is read in that case. ErrTooLarge = errors.New("larger than max-read") -- cgit v1.3