Add machine-readable JSON spellcheck reports #24

Open
maciek wants to merge 1 commit from maciek/pospell:feat/json-reports into main
First-time contributor

Add --report FILE and --report-root DIR to export JSON spellcheck results while preserving normal text diagnostics and spelling-result exit status. This lets CI and other tools consume findings without parsing console output.

The versioned report includes catalog paths relative to the report root, file checksums, and findings grouped by PO entry with context, source strings, translation fingerprints, and unique misspelled words. Identities come from the input actually checked, so consumers can detect stale findings. Clean catalogs are included, and failed scans produce error reports; Hunspell failures now raise an error instead of silently appearing clean.

Document the schema, fingerprint calculation, and report limitations, and add regression coverage for entry identities, grouping, clean and failed scans, CLI behavior, path validation, and plural fingerprints.

Real multiprocessing/Hunspell checks also confirmed preserved text output and exit status, clean reports, and error reports for missing dictionaries.

I've used Codex with GPT-6.1-Sol and reviewed the code thoroughly.

Broader context: I would like to use this report in potodo-docs-priority, to report on spelling check errors.

Add `--report FILE` and `--report-root DIR` to export JSON spellcheck results while preserving normal text diagnostics and spelling-result exit status. This lets CI and other tools consume findings without parsing console output. The versioned report includes catalog paths relative to the report root, file checksums, and findings grouped by PO entry with context, source strings, translation fingerprints, and unique misspelled words. Identities come from the input actually checked, so consumers can detect stale findings. Clean catalogs are included, and failed scans produce error reports; Hunspell failures now raise an error instead of silently appearing clean. Document the schema, fingerprint calculation, and report limitations, and add regression coverage for entry identities, grouping, clean and failed scans, CLI behavior, path validation, and plural fingerprints. Real multiprocessing/Hunspell checks also confirmed preserved text output and exit status, clean reports, and error reports for missing dictionaries. I've used Codex with GPT-6.1-Sol and reviewed the code thoroughly. Broader context: I would like to use this report in [potodo-docs-priority](https://github.com/m-aciek/potodo-docs-priority), to report on spelling check errors.
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u feat/json-reports:maciek-feat/json-reports
git switch maciek-feat/json-reports

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff maciek-feat/json-reports
git switch maciek-feat/json-reports
git rebase main
git switch main
git merge --ff-only maciek-feat/json-reports
git switch maciek-feat/json-reports
git rebase main
git switch main
git merge --no-ff maciek-feat/json-reports
git switch main
git merge --squash maciek-feat/json-reports
git switch main
git merge --ff-only maciek-feat/json-reports
git switch main
git merge maciek-feat/json-reports
git push origin main
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
AFPy/pospell!24
No description provided.