Repository navigation
⬆️ Upgrade configuration for Ruff v0.2.0 - #11075
Merged
Merged
Conversation
Kludex
approved these changes
Feb 2, 2024
|
In this PR, I'd also recommend:
|
Contributor
Author
|
Will do! v0.2.0 wasn't out yet when I put this up -- I'll update the PR to do the version bump too. |
charliermarsh
commented
Feb 7, 2024
| @app.get("/items/") | ||
| async def read_query( | ||
| query_or_default: Annotated[str, Depends(query_or_cookie_extractor)] | ||
| query_or_default: Annotated[str, Depends(query_or_cookie_extractor)], |
Contributor
Author
There was a problem hiding this comment.
This is a change that was also made in latest Black: psf/black#4164.
Member
|
📝 Docs preview for commit 312978b at: https://d38c0b0b.fastapitiangolo.pages.dev |
siavashyj
reviewed
Feb 24, 2024
| - id: trailing-whitespace | ||
| - repo: https://github.com/charliermarsh/ruff-pre-commit | ||
| rev: v0.1.2 | ||
| rev: v0.2.0 |
There was a problem hiding this comment.
v0.2.2 is out!
Suggested change
| rev: v0.2.0 | |
| rev: v0.2.2 |
| coverage[toml] >= 6.5.0,< 8.0 | ||
| mypy ==1.4.1 | ||
| ruff ==0.1.2 | ||
| ruff ==0.2.0 |
There was a problem hiding this comment.
Suggested change
| ruff ==0.2.0 | |
| ruff ==0.2.2 |
Member
|
Awesome, thank you @charliermarsh! 🚀 |
hsuanchi
pushed a commit
to hsuanchi/fastapi
that referenced
this pull request
May 26, 2024
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.
In Ruff v0.2.0 (upcoming), we start to warn about adding these settings under
[tool.ruff]instead of[tool.ruff.lint]. This PR just adjusts FastAPI's configuration to fix those warnings. (This works today, with the version of FastAPI uses now, and will also work with v0.2.0.)