Skip to content

CI: Enable XML in codespell and fix typos - #685

Closed
echoix wants to merge 2 commits into
mainfrom
fix/xml-codespell-typos
Closed

echoix wants to merge 2 commits into
mainfrom
fix/xml-codespell-typos

Conversation

@echoix

@echoix echoix commented Sep 4, 2026 •

Copy link
Copy Markdown
Owner

Summary

Enables XML file type in codespell, fixes typos found in XML files, and skips SVG files (which codespell/identify treats as XML) to avoid false positives from embedded base64 image data.

Changes

  • Enable XML in codespell: Removed xml from exclude_types in .pre-commit-config.yaml.
  • Fix typos: Corrected "co-ordinate" to "coordinate" in:
    • gui/wxpython/xml/wxgui_items.xml (1 occurrence)
    • gui/wxpython/core/testsuite/data/test_toolboxes_menudata_ref.xml (2 occurrences)
  • Skip SVG files: Added *.svg to codespell's skip list in pyproject.toml. SVG is tagged as an XML type by identify, so enabling XML also unexcluded SVG; gui/images/splash_screen.svg embeds a base64 JPEG that codespell misread as typos (e.g. "nd", "Ot", "tHt"), which failed CI.

Testing

  • pre-commit run codespell --all-files passes locally.

@echoix echoix changed the title xml: Fix codespell typos (co-ordinate → coordinate) CI: Enable XML in codespell and fix typos Sep 4, 2026
@echoix
echoix force-pushed the fix/xml-codespell-typos branch from 5563cdb to 9692743 Compare September 5, 2026 21:18
Enable XML file type in codespell by removing it from exclude_types
in .pre-commit-config.yaml. Fix all typos found in XML files:
- gui/wxpython/xml/wxgui_items.xml: coordinate (1 occurrence)
- gui/wxpython/core/testsuite/data/test_toolboxes_menudata_ref.xml: coordinate (2 occurrences)

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@echoix
echoix force-pushed the fix/xml-codespell-typos branch from 9692743 to 0bf72c2 Compare September 5, 2026 21:19
Enabling codespell for XML also covers SVG (identify tags it as an
XML type). gui/images/splash_screen.svg embeds a base64-encoded JPEG
that codespell misreads as misspelled words (e.g. "nd", "Ot", "tHt").
Skip *.svg via codespell's own skip list so the exclusion also
applies when codespell is run directly, not just through pre-commit.
@github-actions github-actions Bot added the Python label Sep 5, 2026
echoix added a commit that referenced this pull request Sep 6, 2026
* xml: Fix codespell typos (co-ordinate → coordinate)

Enable XML file type in codespell by removing it from exclude_types
in .pre-commit-config.yaml. Fix all typos found in XML files:
- gui/wxpython/xml/wxgui_items.xml: coordinate (1 occurrence)
- gui/wxpython/core/testsuite/data/test_toolboxes_menudata_ref.xml: coordinate (2 occurrences)

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>

* codespell: Skip SVG files to avoid false positives

Enabling codespell for XML also covers SVG (identify tags it as an
XML type). gui/images/splash_screen.svg embeds a base64-encoded JPEG
that codespell misreads as misspelled words (e.g. "nd", "Ot", "tHt").
Skip *.svg via codespell's own skip list so the exclusion also
applies when codespell is run directly, not just through pre-commit.

---------

Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>
@echoix echoix closed this Sep 6, 2026
@echoix
echoix deleted the fix/xml-codespell-typos branch September 6, 2026 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant