Expert in Django Python web development with best practices
Install
npx skills add https://github.com/mindrally/skills --skill django-pythonSKILL.md
Django Python
You are an expert in Django and Python web development.
Core Principles
- Write clear, technical responses with precise Django examples
- Leverage Django's built-in features and tools extensively
- Maintain PEP 8 compliance and readability
- Use descriptive naming (lowercase with underscores)
- Structure projects modularly using Django apps
Django/Python Guidelines
- Prefer class-based views for complex logic; function-based views for simpler tasks
- Leverage Django's ORM for database interactions; avoid raw SQL queries unless necessary
- Use Django's built-in authentication and user management
- Implement form and model form classes for validation
- Follow the MVT (Model-View-Template) pattern strictly
- Apply middleware judiciously for cross-cutting concerns
Error Handling & Validation
- Implement error handling at the view level
- Use Django's validation framework to validate form and model data
- Use try-except blocks for business logic exceptions
- Customize error pages (404, 500) for better UX
- Employ Django signals for decoupled error handling
Key Dependencies
- Django
- Django REST Framework
- Celery (background tasks)
- Redis (caching/queues)
- PostgreSQL or MySQL
Performance Optimization
- Use
select_related()andprefetch_related()for efficient queries - Implement database indexing and query optimization techniques
- Leverage Django's caching framework with Redis/Memcached
- Use Celery for I/O-bound operations
- Optimize static files with WhiteNoise or CDN
Related skills
entra-app-registrationmicrosoft606KGuides Microsoft Entra ID app registration, OAuth 2.0 authentication, and MSAL integration. USE FOR: create app registration, register Azure AD app, configure OAuth, set up authentication, add API permissions, generate service principal, MSAL example, console app auth, Entra ID setup, Azure AD authentication. DO NOT USE FOR: Key Vault secrets (use azure-keyvault-expiration-audit), general Azure resource security guidance.azure-messagingmicrosoft595KTroubleshoot and resolve issues with Azure Messaging SDKs for Event Hubs and Service Bus. Covers connection failures, authentication errors, message processing issues, and SDK configuration problems. WHEN: event hub SDK error, service bus SDK issue, messaging connection failure, AMQP error, event processor host issue, message lock lost, message lock expired, lock renewal, lock renewal batch, send timeout, receiver disconnected, SDK troubleshooting, azure messaging SDK, event hub consumer, servicentra-agent-idmicrosoft328KProvision Microsoft Entra Agent Identity Blueprints, BlueprintPrincipals, and per-instance Agent Identities via Microsoft Graph, and configure OAuth 2.0 token exchange (fmi_path, OBO, cross-tenant) including the Microsoft Entra SDK for AgentID sidecar. USE FOR: Agent Identity Blueprint, BlueprintPrincipal, agent OAuth, fmi_path token exchange, agent OBO, Workload Identity Federation for agents, polyglot agent auth, Microsoft.Identity.Web.AgentIdentities. DO NOT USE FOR: standard Entra app registsupabasesupabase298KUse when doing ANY task involving Supabase. Triggers: Supabase products (Database, Auth, Edge Functions, Realtime, Storage, Vectors, Cron, Queues); client libraries and SSR integrations (supabase-js, @supabase/ssr) in Next.js, React, SvelteKit, Astro, Remix; auth issues (login, logout, sessions, JWT, cookies, getSession, getUser, getClaims, RLS); Supabase CLI or MCP server; schema changes, migrations, declarative schemas, security audits, Postgres extensions (pg_graphql, pg_cron, pg_vector); deb