python
Google Python Style Guide
Official Google Python coding standards extending PEP 8.
Golden Rules
- Follow PEP 8 as baseline — Google's guide extends it
- Use type annotations for all public functions and methods
- 4-space indentation — no tabs
- Maximum line length: 80 characters
- Docstrings mandatory for all public modules, functions, classes, methods
- Prefer comprehensions over
map()/filter() - Use f-strings for string formatting (Python 3.6+)
Quick Reference
Naming Conventions
| Element | Convention | Example |
More from testdino-hq/google-styleguides-skills
shell
Google's official Shell scripting style guide. Covers Bash scripting, naming conventions, error handling, portability, and shell best practices.
3google-styleguides-skills
Complete collection of Google's official style guides for 17 languages. Includes TypeScript, JavaScript, Python, Java, Go, C++, C#, Swift, Objective-C, HTML/CSS, AngularJS, Shell, R, Common Lisp, Vim Script, JSON, and Markdown. Production-ready coding standards used across Google's engineering organization, formatted for AI agent consumption.
3cpp
Google's official C++ style guide. Covers headers, naming conventions, formatting, classes, memory management, RAII, smart pointers, and modern C++ features.
2java
Google's official Java style guide. Covers 2-space indentation, 100-char line limit, naming conventions, braces, imports, Javadoc, exception handling, lambdas, and streams. Enforces @Override annotations and specific imports.
2typescript
Google's official TypeScript style guide. Covers strict mode, type annotations, interfaces vs types, null handling, naming conventions, imports, and common mistakes. Enforces explicit return types, readonly properties, and avoidance of any/non-null assertions.
1