Repository navigation
docs: three tutorials, each a complete programme we ran - #7
Merged
Merged
Conversation
The reference says what every name does; nothing showed the shape of a pipeline that uses them. Three worked examples: opening an image with Pillow checked first, with open_checked's two lines spelt out and the same wrapper written for a thumbnailer and for a reader with no formats argument; rendering a PDF with poppler at the dpi the check was made at, with a time budget per page once the count is known; and an inbox that quarantines what it refuses and writes the verdict beside each file. Every code block was run as written against the files it names, and the output quoted is what came back. The README points at the page. Co-authored-by: Yvette Mankerian <yvettekm@gmail.com> Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Ruff formats the Python inside Markdown too, and the aligned comments were not its style. The check runs on the whole tree in CI. Co-authored-by: Yvette Mankerian <yvettekm@gmail.com> Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
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.
Summary
open_checked's two lines spelt out; a refusal and its verdict; a PDF underopen_checked; an images-only policy; the same wrapper written for a thumbnailer and, for readers with noformatsargument (tifffile, imageio, OpenCV), the generic check-then-read shape; the same file underDEFAULTandSTRICT, and why a policy should be set from your own corpus.pdfinfotells the check without rendering;pdftoppmrun at the dpi the check was made at, with a time budget per page.acceptedorquarantineand writes the verdict beside it; checking a copy you own; keeping the policy and the decoder's limits in agreement; the--jsonand-q --strictcommand forms.Test plan
page.png, a GIF and a 63-megapixel JPEG); the output quoted in the prose is what came backzensical build --clean --strict: no issues; the anchors the page links to exist🤖 Generated with Claude Code