You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expand ruff configurations to enforce comprehensive code quality standards (#23)
## Summary
Enhances our `ruff` configurations to enforce comprehensive standards
across various aspects of code quality, including style, formatting,
structure, complexity, security, bug prevention, and documentation.
## Details
### Changes Implemented:
1. **Code Style and Formatting:**
- Enforced PEP 8 conventions, including spacing, indentation, and line
length.
- Included `isort` for consistent import sorting.
- Added rules for trailing commas, commented-out code, import
conventions, naming conventions, and quote usage.
2. **Code Structure and Complexity:**
- Simplified complex expressions and improved readability.
- Applied best practices for list, set, and dict comprehensions.
- Checked for overly complex code using cyclomatic complexity.
3. **Code Security and Bug Prevention:**
- Detected unused function arguments, boolean traps, and implicit string
concatenations.
- Prevented common programming mistakes and potential bugs.
- Enforced correct exception handling and detected security issues.
4. **Code Documentation:**
- Ensured adherence to documentation standards.
- Detected unresolved FIXMEs and other temporary comments.
### Files Modified:
- `.pre-commit-config.yaml`: Updated configurations to include new ruff
rules and standards.
- `pyproject.toml`: Extended ruff linting rules to cover additional
checks for various code quality aspects.
- Source and test files: Applied necessary changes to comply with the
new ruff configurations, including refactoring code, updating
documentation, and adding comments.
### Test Plan:
- **Automated Testing:**
- Automated tests updated to run the latest changes
- **Manual Testing:**
- Manually reviewed changes to ensure they align with the updated
linting standards.
- Manually ran tests and checks
0 commit comments