We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
While working on a new charm canonical/github-profiles-automator#7 I realised that charmcraft init now is using ruff by default for lint and not flake8 canonical/charmcraft#1461
charmcraft init
ruff
flake8
As of 27 November 2024 the auto-created configuration for ruff in pyproject.toml is the following
pyproject.toml
# Linting tools configuration [tool.ruff] line-length = 99 lint.select = ["E", "W", "F", "C", "N", "D", "I001"] lint.extend-ignore = [ "D203", "D204", "D213", "D215", "D400", "D404", "D406", "D407", "D408", "D409", "D413", ] lint.ignore = ["D107"] extend-exclude = ["__pycache__", "*.egg_info"] lint.per-file-ignores = {"tests/*" = ["D100","D101","D102","D103","D104"]} [tool.ruff.lint.mccabe] max-complexity = 10
We should gradually replace flake8 in all our charms. Looking a bit around other teams have done this as well:
[tool.flake8]
[tool.ruff]
pyproject.yaml
unit
tox
.in
ruff check
When all of the Analytics charms are using ruff
The text was updated successfully, but these errors were encountered:
Thank you for reporting us your feedback!
The internal ticket has been created: https://warthogs.atlassian.net/browse/KF-6597.
This message was autogenerated
Sorry, something went wrong.
No branches or pull requests
Context
While working on a new charm canonical/github-profiles-automator#7 I realised that
charmcraft init
now is usingruff
by default for lint and notflake8
canonical/charmcraft#1461As of 27 November 2024 the auto-created configuration for
ruff
inpyproject.toml
is the followingWe should gradually replace flake8 in all our charms. Looking a bit around other teams have done this as well:
What needs to get done
[tool.flake8]
with[tool.ruff]
, if a repo contains apyproject.yaml
fileunit
environment oftox
to useruff
instead offlake8
.in
file (orpyproject.yaml
in case of poetry) to installruff
ruff check
and fix all the incompatibilitiesDefinition of Done
When all of the Analytics charms are using
ruff
The text was updated successfully, but these errors were encountered: