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

Linting - add Ruff and Black #23

Merged
merged 15 commits into from
Jun 22, 2024
Merged

Linting - add Ruff and Black #23

merged 15 commits into from
Jun 22, 2024

Conversation

sneakers-the-rat
Copy link
Collaborator

builds off: #21
since it's about to be merged.

Seems like we're going to get into trouble with our linting sooner rather than later now that work has begun on this in earnest.

Added black and ruff checks in CI, and started getting the package in line with them. Will add docs on how to do this during development but it's super simple (we can set this up as a pre-commit action, but otherwise it's just black miniscope_io && ruff check ).

gotta run for now, but it's super mechanical work, nothing too tricky, and should all be totally function neutral.

@sneakers-the-rat
Copy link
Collaborator Author

@t-sasatani any objections to my linter rules here?

https://github.com/Aharoni-Lab/miniscope-io/blob/beec7d0983200ca96b5189457801e1c00580d717/pyproject.toml#L67-L106

lmk if there are any you find annoying or wish we had

https://docs.astral.sh/ruff/rules/

@t-sasatani
Copy link
Collaborator

t-sasatani commented Jun 21, 2024

Thanks, I looked into your code changes (which I believe indicate these rules), and I think they look good. I haven't used these before, so I'm not sure what coding with this will be like to be honest, but I think we can just start and think later.

@sneakers-the-rat
Copy link
Collaborator Author

Ill write some docs on how to set it up to be more or less automatic :) these integrate pretty well with most IDEs

@sneakers-the-rat sneakers-the-rat marked this pull request as ready for review June 22, 2024 00:26
@sneakers-the-rat
Copy link
Collaborator Author

I review this pull request and declare it to be good

@sneakers-the-rat sneakers-the-rat merged commit 56f821b into main Jun 22, 2024
11 checks passed
@sneakers-the-rat sneakers-the-rat deleted the linting branch December 13, 2024 03:27
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