88
99class MySQLError (Exception ):
1010 """Exception related to operation with MySQL."""
11+ __module__ = "MySQLdb"
1112
1213
1314class Warning (Warning , MySQLError ):
1415 """Exception raised for important warnings like data truncations
1516 while inserting, etc."""
17+ __module__ = "MySQLdb"
1618
1719
1820class Error (MySQLError ):
1921 """Exception that is the base class of all other error exceptions
2022 (not Warning)."""
23+ __module__ = "MySQLdb"
2124
2225
2326class InterfaceError (Error ):
2427 """Exception raised for errors that are related to the database
2528 interface rather than the database itself."""
29+ __module__ = "MySQLdb"
2630
2731
2832class DatabaseError (Error ):
2933 """Exception raised for errors that are related to the
3034 database."""
35+ __module__ = "MySQLdb"
3136
3237
3338class DataError (DatabaseError ):
3439 """Exception raised for errors that are due to problems with the
3540 processed data like division by zero, numeric value out of range,
3641 etc."""
42+ __module__ = "MySQLdb"
3743
3844
3945class OperationalError (DatabaseError ):
@@ -42,28 +48,33 @@ class OperationalError(DatabaseError):
4248 e.g. an unexpected disconnect occurs, the data source name is not
4349 found, a transaction could not be processed, a memory allocation
4450 error occurred during processing, etc."""
51+ __module__ = "MySQLdb"
4552
4653
4754class IntegrityError (DatabaseError ):
4855 """Exception raised when the relational integrity of the database
4956 is affected, e.g. a foreign key check fails, duplicate key,
5057 etc."""
58+ __module__ = "MySQLdb"
5159
5260
5361class InternalError (DatabaseError ):
5462 """Exception raised when the database encounters an internal
5563 error, e.g. the cursor is not valid anymore, the transaction is
5664 out of sync, etc."""
65+ __module__ = "MySQLdb"
5766
5867
5968class ProgrammingError (DatabaseError ):
6069 """Exception raised for programming errors, e.g. table not found
6170 or already exists, syntax error in the SQL statement, wrong number
6271 of parameters specified, etc."""
72+ __module__ = "MySQLdb"
6373
6474
6575class NotSupportedError (DatabaseError ):
6676 """Exception raised in case a method or database API was used
6777 which is not supported by the database, e.g. requesting a
6878 .rollback() on a connection that does not support transaction or
6979 has transactions turned off."""
80+ __module__ = "MySQLdb"
0 commit comments