replace yapf reference with instruction to use 'ruff format'#695
replace yapf reference with instruction to use 'ruff format'#695
Conversation
0d20fc2 to
2d2f525
Compare
2d2f525 to
ab31a4b
Compare
sverhoeven
left a comment
There was a problem hiding this comment.
Nice work, making things more consistent.
In README.dev.md the ruff commands are shown with ..
In template/{% if AddPreCommit %}.githooks{% endif %}/pre-commit and template/{% if HasWorkflows %}.github{% endif %}/workflows/{% if AddGitHubActionBuild %}build.yml{% endif %}.jinja the ruff commands are run without ..
Would be nice to be consistent with the commands by either using ruff check . or ruff check everywhere.
nitpick
When I do ruff format . I get
warning: The following rules have been removed and ignoring them has no effect:
- ANN101
- ANN102
warning: The following rule may cause conflicts when used with the formatter: `COM812`. To avoid unexpected behavior, we recommend disabling this rule, either by removing it from the `lint.select` or `lint.extend-select` configuration, or adding it to the `lint.ignore` configuration.
4 files left unchangedMight be nice to get rid of those warnings. This is with ruff v0.14.5.
|
@sverhoeven Thanks for the suggestions! I've updated the The warnings on ANN101 & 102 were already removed in a previous PR, I think you got those because copier uses the latest tag/release by default. My bad for not the relevant copier command to use when testing to the PR in the first place 😅 copier copy --vcs-ref 588-replace-yapf-with-ruff-format https://github.com/nlesc/python-template test_package |
Checklist before requesting a review
[ ] I have added tests that prove my fix is effective or that my feature works[ ] All user facing changes have been added to CHANGELOG.mdType of change
Please delete options that are not relevant.
List of related issues or pull requests**
Refs:
Describe the changes made in this pull request
Removed the reference to
yapffor formatting code, and replaced it with an instruction to useruff formatinstead.