AI SummaryWhen reviewing code, focus on: Always prioritize security vulnerabilities and performance issues that could impact users. Always suggest changes to improve readability and testability. For example, this suggestion seeks to make the code more readable, reusable, and testable:
Install
Copy this and paste it into Claude Code, Cursor, or any AI assistant:
I want to add the "mongo-python-driver — Copilot Instructions" prompt rules to my project. Repository: https://github.com/mongodb/mongo-python-driver Please read the repo to find the rules/prompt file, then: 1. Download it to the correct location (.cursorrules, .windsurfrules, .github/prompts/, or project root — based on the file type) 2. If there's an existing rules file, merge the new rules in rather than overwriting 3. Confirm what was added
Description
PyMongo - the Official MongoDB Python driver
Security Critical Issues
• Check for hardcoded secrets, API keys, or credentials. • Check for instances of potential method call injection, dynamic code execution, symbol injection or other code injection vulnerabilities.
Performance Red Flags
• Spot inefficient loops and algorithmic issues. • Check for memory leaks and resource cleanup.
Code Quality Essentials
• Methods should be focused and appropriately sized. If a method is doing too much, suggest refactorings to split it up. • Use clear, descriptive naming conventions. • Avoid encapsulation violations and ensure proper separation of concerns. • All public classes, modules, and methods should have clear documentation in Sphinx format.
PyMongo-specific Concerns
• Do not review files within pymongo/synchronous or files in test/ that also have a file of the same name in test/asynchronous unless the reviewed changes include a _IS_SYNC statement. PyMongo generates these files from pymongo/asynchronous and test/asynchronous using tools/synchro.py. • All asynchronous functions must not call any blocking I/O.
Discussion
Health Signals
My Fox Den
Community Rating
Sign in to rate this booster
Works With
Any AI assistant that accepts custom rules or system prompts