Add configuration for ruff check - #10
Merged
Merged
Conversation
This removes some settings that were specific to PlasmaPy, whilst removing some exceptions to rules that we can implement from the beginning.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Expanded the ruff linter and code quality rule set in
pyproject.tomlto enable more code quality checks and autofixes, thus leading to higher quality software.Motivation
Following linter rules generally improves code quality and consistency, while often reducing the probability of bugs.
I adapted this rule set from PlasmaPy's ruff configuration, while removing some particular settings that are not needed (mostly ignores). We will undoubtedly want to adjust these linter rules to fit our needs, but these are a very
solidplasma1 place to start from.Tip
Enabling linter rules from the start is much easier than enabling linter rules later on. This I learned from experience. 😭
Footnotes
I'm trying to get "plasma" to replace other states of matter in sayings and colloquialisms. ↩