python-anti-patterns
A checklist of Python anti-patterns to look for when reviewing code.
- Kind
- Skill
- Works with
- Claude Code, Codex
- Languages
- Python
- Source
- wshobson/agents @ 0874a27b17a2
- Path
- plugins/python-development/skills/python-anti-patterns/SKILL.md
- Jobs
- Review
- Topics
- Code review
Credit
- Made by
- wshobson
- Original
- github.com/wshobson/agents/blob/0874a27b17a22e2b7c2e2bcd72576…
- License
- MIT
Listed by Skill Manifest; not made by us.
InstallInstall it from a plugin marketplace.
/plugin install python-development@claude-code-workflows
Install factsScanned 3 Nov 2026
- Adds
- .claude/skills/python-anti-patterns/ (the skill folder)
- Runs scripts
- None found
- Uses the network
- Yes
- HTTP client calls
- Needs secrets
- Yes
- API_KEY
- Reads environment variables
- API_KEY
- Source revision
- 0874a27b17a2
- Licence
- MIT
- Last activity
- 24 Nov 2026
- Source changed after the scan
- Yes
- Last push 24 Nov 2026, scanned 3 Nov 2026; read it again before you rely on this scan
- Review
- Reviewed
Found by a static scan of the stored text; nothing is run. “None found” is not a guarantee, so read what you install before you run it.
# Python Anti-Patterns Checklist
A reference checklist of common mistakes and anti-patterns in Python code. Review this before finalizing implementations to catch issues early.
## When to Use This Skill
- Reviewing code before merge
- Debugging mysterious issues
- Teaching or learning Python best practices
- Establishing team coding standards
- Refactoring legacy code
**Note:** This skill focuses on what to avoid. For guidance on positive patterns and architecture, see the `python-design-patterns` skill.
## Infrastructure Anti-Patterns
### Scattered Timeout/Retry Logic
```python
# BAD: Timeout logic duplicated everywhere
def fetch_user(user_id):
try:
return requests.get(url, timeout=30)
except Timeout:
logger.warning("Timeout fetching user")
return None
def fetch_orders(user_id):
try:
return requests.get(url, timeout=30)
except Timeout:
logger.warning("Timeout fetching orders")
return None
```
**Fix:** Centralize in decorators or client wrappers.
```python
# GOOD: Centralized retry logic
@retry(stop=stop_after_attempt(3), wait=wait_exponential())
def http_get(url: str) -> Response:
…