python-code-style
Python code style, linting, formatting, naming conventions, and documentation standards. Use when writing new code, reviewing style, configuring linters, writing docstrings, or establishing project standards.
Security Assessment
Detected risks:
About python-code-style
The 'python-code-style' skill provides a comprehensive framework for maintaining consistent code style and clear documentation in Python projects. It addresses common challenges faced by developers when writing new code, reviewing existing code, and establishing coding standards within teams. By leveraging modern tools and adhering to established conventions, this skill helps ensure that codebases remain maintainable and collaborative, ultimately enhancing productivity and reducing technical debt.
This skill encompasses several key features, including automated formatting, consistent naming conventions, and documentation standards. It emphasizes the importance of using tools like 'ruff' for linting and formatting, which simplifies the process of maintaining code quality. Additionally, it advocates for the use of type annotations to improve code clarity and facilitate better collaboration among developers. By following these guidelines, teams can create a cohesive coding environment that fosters best practices and enhances overall code quality.
Target users of this skill include software developers, team leads, and project managers who are involved in Python development. It is particularly beneficial for those setting up new projects, reviewing code for style consistency, or establishing team coding standards. By implementing the practices outlined in this skill, users can ensure that their code is not only functional but also adheres to industry standards, making it easier to read, understand, and maintain over time.
FAQ
How do I set up linting and formatting for my project?
You can set up linting and formatting by installing 'ruff' and configuring it in your 'pyproject.toml' file.
Is this skill compatible with Python 3.12?
Yes, the skill is designed to work with modern Python versions, including Python 3.12.
What are the limitations of using 'ruff'?
While 'ruff' is an all-in-one tool, it may not cover every specific use case that other specialized tools might address.
Can I use other type checkers instead of 'mypy'?
Yes, you can use 'pyright' as an alternative for type checking.
What naming conventions should I follow?
You should follow PEP 8 conventions, using descriptive names for files, classes, functions, and constants.
Install python-code-style
Quick Setup:
- Copy the skill folder to
.claude/skills/ - Claude will automatically detect and use the skill
Repository
wshobson/agents