-
Notifications
You must be signed in to change notification settings - Fork 0
Errors
Vinicius Reif Biavatti edited this page Jul 25, 2022
·
1 revision
- Use a good representation name
- Do not use underscore to separate
- Use camel case
- Do not use special symbols
- Do not use letters to represent the type like "E" for Error
- Use the 'Error' suffix in the exception class name
- Extends the Exception class or subclass
- Never extend the "BaseException" class. Use it for an specific situation only
✅ Do
class ValidationError(Exception):
...
❌ Don't
class ValidationException(Exception):
...
class EValidation(Exception):
...
- Home
- Structural Naming Conventions
- Format Conventions
- Code Naming Conventions
- Inheritance
- Access Modifiers
- Importation
- Functions and Methods
- Documentation
- Resources