Skip to content

[ruff] Ignore fstring-missing-syntax (RUF027) for fastAPI paths#12939

Merged
AlexWaygood merged 1 commit intomainfrom
alex/ruf027-fastapi
Aug 17, 2024
Merged

[ruff] Ignore fstring-missing-syntax (RUF027) for fastAPI paths#12939
AlexWaygood merged 1 commit intomainfrom
alex/ruf027-fastapi

Conversation

@AlexWaygood
Copy link
Copy Markdown
Member

Summary

As suggested by @MichaReiser in #12886 (review), this adds an exemption to RUF027 for fastAPI paths, which require template strings rather than eagerly evaluated f-strings.

Test Plan

I added a fixture that causes Ruff to emit a false-positive error on main but no longer does with this PR.

@AlexWaygood AlexWaygood added bug Something isn't working preview Related to preview mode features labels Aug 16, 2024
@github-actions
Copy link
Copy Markdown
Contributor

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

Copy link
Copy Markdown
Member

@MichaReiser MichaReiser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@AlexWaygood AlexWaygood merged commit 251efe5 into main Aug 17, 2024
@AlexWaygood AlexWaygood deleted the alex/ruf027-fastapi branch August 17, 2024 10:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working preview Related to preview mode features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants