Python Anti Patterns
Helps with Python, patterns as part of developing backend services and APIs workflows.
Install on your platform
We auto-selected Claude Code based on this skill’s supported platforms.
Run in terminal (recommended)
claude mcp add python-anti-patterns npx -- -y @trustedskills/python-anti-patterns
Or manually add to ~/.claude/settings.json
{
"mcpServers": {
"python-anti-patterns": {
"command": "npx",
"args": [
"-y",
"@trustedskills/python-anti-patterns"
]
}
}
}Requires Claude Code (claude CLI). Run claude --version to verify your install.
About This Skill
What it does
The python-anti-patterns skill helps identify and avoid common poor coding practices in Python. It provides insights into anti-patterns such as overuse of global variables, excessive use of nested loops, or improper exception handling that can lead to bugs, maintenance challenges, or performance issues.
When to use it
- Reviewing legacy code for potential refactoring opportunities
- Teaching best practices during code reviews or training sessions
- Analyzing new code submissions to catch harmful patterns early
Key capabilities
- Detection of overuse of global variables
- Identification of excessive nested loops
- Recognition of improper exception handling
- Highlighting unnecessary use of singletons or static classes
Example prompts
- "Find all instances of global variable usage in this Python script."
- "Identify any anti-patterns related to exception handling in the provided code."
- "Review this function for nested loops that could be optimized."
Tips & gotchas
- This skill works best with well-documented and structured code. Poorly formatted or obfuscated scripts may yield incomplete results.
- While it identifies common anti-patterns, it does not provide automated fixes—manual review is still required for accurate refactoring.
Tags
TrustedSkills Verification
Unlike other registries that point to live repositories, TrustedSkills pins every skill to a verified commit hash. This protects you from malicious updates — what you install today is exactly what was reviewed and verified.
Security Audits
| Gen Agent Trust Hub | Pass |
| Socket | Pass |
| Snyk | Pass |
🌐 Community
Passed automated security scans.