Enable UP031: Convert % formatting to f-string
Open
- Dominant language
- Python
- Stars
- 670
- Forks
- 183
- Avg merge
- 17h 7m
- Merged PRs (30d)
- 358
Description
## Rule
**UP031**: `printf-string-formatting`
## Purpose
Convert legacy printf-style % string formatting to modern f-strings.
## Example
```python
# Before
name = "world"
message = "Hello, %s!" % name
# After
name = "world"
message = f"Hello, {name}!"
```
## Auto-fix
✅ Available
## Notes
- Part of Python 3.12 modernization effort
- f-strings are more readable and often faster
- Backend.AI uses BraceStyleAdapter for logging, so this doesn't conflict
JIRA Issue: BA-4025
Contributor guide
Assessment
This issue has not been assessed yet.