SyntaxErrorSyntaxError
Python encountered invalid syntax that cannot be parsed.
Sfoglia tutti i 80 codici di errore Eccezioni Python con cause, soluzioni ed esempi.
SyntaxErrorPython encountered invalid syntax that cannot be parsed.
IndentationErrorThe code has incorrect indentation, which is syntactically significant in Python.
TabErrorIndentation uses an inconsistent mix of tabs and spaces.
TypeErrorAn operation or function was applied to an object of an inappropriate type.
ValueErrorA function received an argument of the right type but an inappropriate value.
KeyErrorA dictionary key was not found in the dictionary.
IndexErrorA sequence index is out of the valid range for the given sequence.
AttributeErrorAn object does not have the requested attribute or method.
NameErrorA local or global name was referenced that has not been defined.
UnboundLocalErrorA local variable was referenced before it was assigned a value.
ImportErrorAn import statement failed to find or load the specified module or name.
ModuleNotFoundErrorPython could not find the specified module to import.
FileNotFoundErrorThe specified file or directory does not exist.
FileExistsErrorAn operation failed because the file or directory already exists.
PermissionErrorThe operation is not permitted due to insufficient file system permissions.
OSErrorA system-level error occurred during an I/O operation.
IOErrorAn I/O operation failed. IOError is an alias for OSError in Python 3.
IsADirectoryErrorA file operation was attempted on a path that is a directory.
NotADirectoryErrorA directory operation was attempted on a path that is not a directory.
ZeroDivisionErrorA division or modulo operation was attempted with zero as the divisor.
ArithmeticErrorBase class for arithmetic errors including ZeroDivisionError, OverflowError, and FloatingPointError.
OverflowErrorThe result of an arithmetic operation is too large to be represented.
FloatingPointErrorA floating point operation failed. Rarely seen unless fpectl is enabled.
StopIterationRaised by the next() function to indicate that there are no further items in an iterator.
StopAsyncIterationRaised by an async iterator's __anext__() method to signal that iteration is complete.
GeneratorExitRaised when a generator's close() method is called, allowing cleanup.
KeyboardInterruptThe user pressed Ctrl+C to interrupt the running program.
SystemExitRaised by sys.exit() to request program termination.
MemoryErrorThe Python interpreter ran out of available memory.
RecursionErrorThe maximum recursion depth was exceeded.
RuntimeErrorA generic runtime error that does not fall into any other category.
NotImplementedErrorA method that should be implemented by a subclass has not been implemented yet.
LookupErrorBase class for errors raised when a key or index is not found (KeyError, IndexError).
AssertionErrorAn assert statement failed because the condition evaluated to False.
EOFErrorThe input() function or raw_input() hit end-of-file without reading any data.
UnicodeEncodeErrorA Unicode string could not be encoded to the target encoding.
UnicodeDecodeErrorA byte sequence could not be decoded using the specified encoding.
UnicodeTranslateErrorA Unicode translation operation failed for a specific character.
ConnectionErrorA connection-related error occurred during a network operation.
ConnectionRefusedErrorThe connection was refused because no server is listening on the target address.
ConnectionResetErrorThe connection was forcibly closed by the remote server.
ConnectionAbortedErrorThe connection was aborted by the local machine.
BrokenPipeErrorAn attempt was made to write to a pipe or socket whose reading end has been closed.
TimeoutErrorA system-level timeout occurred during a blocking operation.
ChildProcessErrorA child process operation failed.
ProcessLookupErrorThe specified process does not exist.
InterruptedErrorA system call was interrupted by an incoming signal.
BlockingIOErrorAn I/O operation would block on a non-blocking object.
EnvironmentErrorAn alias for OSError. Exists for backward compatibility with Python 2.
BufferErrorAn operation on a buffer object failed.
DeprecationWarningA warning about a deprecated feature that will be removed in a future version.
FutureWarningA warning about behavior that will change in a future version.
ResourceWarningA warning about improper resource management, such as unclosed files or connections.
ExceptionGroupA container for multiple exceptions, introduced in Python 3.11 for structured concurrency.
requests.exceptions.ConnectionErrorThe requests library failed to establish a connection to the target server.
requests.exceptions.TimeoutA request timed out while waiting for a response from the server.
requests.exceptions.HTTPErrorAn HTTP error response (4xx or 5xx) was received and raise_for_status() was called.
json.JSONDecodeErrorThe JSON decoder could not parse the provided string as valid JSON.
pickle.UnpicklingErrorThe pickle module could not deserialize the provided data.
asyncio.TimeoutErrorAn asyncio operation exceeded its timeout.
asyncio.CancelledErrorAn asyncio task was cancelled.
struct.errorAn error occurred while packing or unpacking binary data with the struct module.
re.errorThe regular expression pattern contains invalid syntax.
subprocess.CalledProcessErrorA subprocess exited with a non-zero return code.
TypeError: unhashable typeA mutable object was used where a hashable (immutable) object is required, such as a dictionary key or set element.
TypeError: missing required positional argumentA function was called without providing all required positional arguments.
TypeError: object is not subscriptableBracket notation ([]) was used on an object that does not support indexing.
TypeError: object is not callableAn object that is not a function was called with parentheses ().
TypeError: object is not iterableAn object that does not support iteration was used in a for loop, unpacking, or other iterable context.
django.core.exceptions.ImproperlyConfiguredDjango detected a misconfiguration in the project's settings.
Model.DoesNotExistA Django ORM query with .get() did not find a matching record.
sqlalchemy.exc.OperationalErrorA database operation failed due to a connection or database-level error.
pandas KeyError: column not foundA DataFrame column access failed because the specified column name does not exist.
numpy ValueError: shape mismatchA numpy operation failed because the array shapes are incompatible.
pip: ERROR: Could not install packagespip failed to install one or more Python packages.
ssl.SSLCertVerificationError: certificate verify failedSSL certificate verification failed during a secure connection.
socket.gaierror: Name or service not knownDNS resolution failed for the specified hostname.
concurrent.futures.TimeoutErrorA Future did not complete within the specified timeout period.
pydantic.ValidationErrorPydantic data validation failed because the input data does not match the model's schema.
multiprocessing.AuthenticationErrorAuthentication failed when connecting to a multiprocessing server.