Python 开发专家

Audit Python code for PEP8 compliance, type hints, and error handling.

Updated Sep 5, 2021
One-click install
npx skills add https://github.com/a747895159/spring-cloud-study-alibaba --skill python-a747895159
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Python 开发专家
Source: https://github.com/a747895159/spring-cloud-study-alibaba/tree/main/.agent/skills/python-expert
Command: npx skills add https://github.com/a747895159/spring-cloud-study-alibaba --skill python-a747895159

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Python 开发专家帮助团队在Python代码的开发、审查和优化中遵循 Pythonic 风格与最佳实践,从而提升代码质量和可维护性。

Core Features & Use Cases

  • 提供高质量代码指南,覆盖命名、类型注解、异常处理、性能优化等方面。
  • 支持代码审查、重构和性能提升的实际场景,包括大型代码库和跨团队协作。
  • 示例驱动:通过示例展示最佳实践和常见陷阱,帮助开发者快速应用。

Quick Start

请将需要评审的 Python 模块提交给模型,并请求其对风格、类型提示、可读性和性能提出改进建议。

Frequently Asked Questions about Python 开发专家

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I perform a Python code review to check for PEP8 and type hints?

Python code review checks your module against PEP8, type hints, and Pythonic best practices to improve quality and readability. You submit your Python module to receive actionable suggestions and example patterns for robust error handling and maintainability.

What is the best way to refactor Python code for better performance and readability?

Refactoring Python code involves enforcing type hints, PEP8, and Pythonic best practices to optimize performance and readability. The process provides actionable suggestions and example patterns to address common pitfalls and improve maintainability across project domains.

Can I use this for large Python codebases and cross-team collaboration?

Yes, it supports code reviews, refactoring, and optimization tasks across large codebases and cross-team collaboration. It enforces consistent coding best practices, robust error handling, and Pythonic standards to ensure maintainability across projects of varying sizes and domains.

How do I add type hints and handle exceptions in Python properly?

To add type hints and handle exceptions, you apply Pythonic best practices and PEP8 standards. The Skill audits your code to provide actionable suggestions and example patterns demonstrating proper type annotations and robust error handling mechanisms.

Does Python code optimization work for legacy modules without type annotations?

Python code optimization applies to legacy modules by auditing existing code for style, readability, and performance. It provides actionable suggestions to refactor existing logic, enforce PEP8, introduce type hints, and implement robust error handling.