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

codespell: add config and action to codespell the code to avoid known typos #1006

Closed
wants to merge 4 commits into from

Conversation

yarikoptic
Copy link

No description provided.

=== Do not change lines below ===
{
 "chain": [],
 "cmd": "codespell -w",
 "exit": 0,
 "extra_inputs": [],
 "inputs": [],
 "outputs": [],
 "pwd": "."
}
^^^ Do not change lines above ^^^
@carsen-stringer
Copy link
Member

thanks I did not know about this tool, does this only check in comments / non-code? I am very wary of any tool that can change actual code (which is why we don't use black)

@codecov
Copy link

codecov bot commented Aug 2, 2023

Codecov Report

Merging #1006 (437631d) into main (9808eca) will not change coverage.
Report is 20 commits behind head on main.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #1006   +/-   ##
=======================================
  Coverage   58.69%   58.69%           
=======================================
  Files          40       40           
  Lines        4551     4551           
=======================================
  Hits         2671     2671           
  Misses       1880     1880           
Files Changed Coverage Δ
suite2p/__init__.py 100.00% <ø> (ø)
suite2p/__main__.py 40.98% <ø> (ø)
suite2p/classification/__init__.py 100.00% <ø> (ø)
suite2p/classification/classifier.py 88.88% <ø> (ø)
suite2p/classification/classify.py 100.00% <ø> (ø)
suite2p/default_ops.py 100.00% <ø> (ø)
suite2p/detection/__init__.py 100.00% <ø> (ø)
suite2p/detection/anatomical.py 12.66% <ø> (ø)
suite2p/detection/chan2detect.py 86.84% <ø> (ø)
suite2p/detection/denoise.py 19.35% <ø> (ø)
... and 30 more

@yarikoptic
Copy link
Author

It does check everything, including code. I did have cases of finding/fixing typos in scripts not covered through tests. It doesn't change any code unless you ask it when you run it locally - action just checks

@carsen-stringer
Copy link
Member

thanks it was helpful to see the typos, but I don't feel comfortable with it being able to change code

yarikoptic added a commit to yarikoptic/suite2p that referenced this pull request Aug 7, 2023
note -- this is just a single commit from a full(er) collection
which was proposed in MouseLand#1006
and carried configuration for codespell and also github action.

This commit is just typo fixes done by codespell when it had that config.

=== Do not change lines below ===
{
 "chain": [],
 "cmd": "codespell -w",
 "exit": 0,
 "extra_inputs": [],
 "inputs": [],
 "outputs": [],
 "pwd": "."
}
^^^ Do not change lines above ^^^
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