Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add spellchecking with crate-ci/typos #3166

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

CoolCat467
Copy link
Member

In this pull request, we add https://github.com/crate-ci/typos as a pre-commit spellchecker and fix various typos found with this particular spellchecker.

They claim to have more features than codespell, but I don't really see a reason why we couldn't use both as long as they aren't fighting each other.

I learned about crate-ci/typos quite recently when looking through changes made to the mypy daemon as a part of mypy 1.14.0, so I'm not super familiar with how the configuration works, but I think it's at least mostly working as is. What I've tried to add as known "identifiers" with -s in them don't seem to be functioning as I intended however.

@CoolCat467 CoolCat467 requested review from jakkdl and A5rocks and removed request for jakkdl December 23, 2024 05:31
@CoolCat467 CoolCat467 added the skip newsfragment Newsfragment is not required label Dec 23, 2024
Copy link

codecov bot commented Dec 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00000%. Comparing base (a670d60) to head (0e6a93f).
Report is 24 commits behind head on main.

Additional details and impacted files
@@               Coverage Diff               @@
##                 main        #3166   +/-   ##
===============================================
  Coverage   100.00000%   100.00000%           
===============================================
  Files             124          124           
  Lines           18427        18427           
  Branches         1215         1215           
===============================================
  Hits            18427        18427           
Files with missing lines Coverage Δ
src/trio/_abc.py 100.00000% <ø> (ø)
src/trio/_core/_ki.py 100.00000% <100.00000%> (ø)
src/trio/_core/_parking_lot.py 100.00000% <ø> (ø)
src/trio/_core/_run.py 100.00000% <ø> (ø)
src/trio/_core/_windows_cffi.py 100.00000% <100.00000%> (ø)
src/trio/_tests/test_threads.py 100.00000% <100.00000%> (ø)
src/trio/_util.py 100.00000% <ø> (ø)

... and 1 file with indirect coverage changes

src/trio/_core/_run.py Outdated Show resolved Hide resolved
pyproject.toml Outdated Show resolved Hide resolved
``b"xn--caf-dma.com"``.

"""
``b"xn--caf-dma.com"``.""" # spellchecker:disable-line
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

xn--caf is both in extend-identifiers in pyproject.toml and has spellchecker:disable-line?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some reason extend-identifiers does does not work as I intended and continues to try replacing it, so I added spellchecker:disable-line there to solve the issue. If there would be a way to get extend-identifiers to do ignore that one like I intended, that would be a better solution.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in that case we should at least remove the non-functioning line in extend-identifiers, unless you wanna report it upstream.

@jakkdl
Copy link
Member

jakkdl commented Dec 24, 2024

with PARMETER->PARAMETER this needs a newsfragment

@CoolCat467 CoolCat467 removed the skip newsfragment Newsfragment is not required label Dec 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants