Liking cljdoc? Tell your friends :D
Clojure only.

libpython-clj.jna.concrete.err


def-err-symbolcljmacro

(def-err-symbol sym-name)
source

PyErr_BadArgumentclj

(PyErr_BadArgument)

This is a shorthand for PyErr_SetString(PyExc_TypeError, message), where message indicates that a built-in operation was invoked with an illegal argument. It is mostly for internal use.

This is a shorthand for PyErr_SetString(PyExc_TypeError, message), where message
indicates that a built-in operation was invoked with an illegal argument. It is mostly
for internal use.
sourceraw docstring

PyErr_BadInternalCallclj

(PyErr_BadInternalCall)

This is a shorthand for PyErr_SetString(PyExc_SystemError, message), where message indicates that an internal operation (e.g. a Python/C API function) was invoked with an illegal argument. It is mostly for internal use.

This is a shorthand for PyErr_SetString(PyExc_SystemError, message), where message
indicates that an internal operation (e.g. a Python/C API function) was invoked with
an illegal argument. It is mostly for internal use.
sourceraw docstring

PyErr_Clearclj

(PyErr_Clear)

Clear the error indicator. If the error indicator is not set, there is no effect.

Clear the error indicator. If the error indicator is not set, there is no effect.
sourceraw docstring

PyErr_Fetchclj

(PyErr_Fetch ptype pvalue ptraceback)

Retrieve the error indicator into three variables whose addresses are passed. If the error indicator is not set, set all three variables to NULL. If it is set, it will be cleared and you own a reference to each object retrieved. The value and traceback object may be NULL even when the type object is not.

Note

This function is normally only used by code that needs to catch exceptions or by code that needs to save and restore the error indicator temporarily, e.g.:

{ PyObject *type, *value, *traceback; PyErr_Fetch(&type, &value, &traceback);

 /* ... code that might produce other errors ... */

 PyErr_Restore(type, value, traceback);

}

Retrieve the error indicator into three variables whose addresses are passed. If the
error indicator is not set, set all three variables to NULL. If it is set, it will be
cleared and you own a reference to each object retrieved. The value and traceback
object may be NULL even when the type object is not.

 Note

 This function is normally only used by code that needs to catch exceptions or by code
 that needs to save and restore the error indicator temporarily, e.g.:

  {
     PyObject *type, *value, *traceback;
     PyErr_Fetch(&type, &value, &traceback);

     /* ... code that might produce other errors ... */

     PyErr_Restore(type, value, traceback);
  }
sourceraw docstring

PyErr_NoMemoryclj

(PyErr_NoMemory)

Return value: Always NULL.

This is a shorthand for PyErr_SetNone(PyExc_MemoryError); it returns NULL so an object allocation function can write return PyErr_NoMemory(); when it runs out of memory.

Return value: Always NULL.

This is a shorthand for PyErr_SetNone(PyExc_MemoryError); it returns NULL so an
object allocation function can write return PyErr_NoMemory(); when it runs out of
memory.
sourceraw docstring

PyErr_Occurredclj

(PyErr_Occurred)

Check if the error indicator is set. If so, return the exception type.

Check if the error indicator is set.  If so, return the exception type.
sourceraw docstring

PyErr_Printclj

(PyErr_Print)

Alias for PyErr_PrintEx(1).

Alias for PyErr_PrintEx(1).
sourceraw docstring

PyErr_PrintExclj

(PyErr_PrintEx set-sys-last-vars)

Print a standard traceback to sys.stderr and clear the error indicator. Unless the error is a SystemExit. In that case the no traceback is printed and Python process will exit with the error code specified by the SystemExit instance.

Call this function only when the error indicator is set. Otherwise it will cause a fatal error!

If set_sys_last_vars is nonzero, the variables sys.last_type, sys.last_value and sys.last_traceback will be set to the type, value and traceback of the printed exception, respectively.

Print a standard traceback to sys.stderr and clear the error indicator. Unless the
error is a SystemExit. In that case the no traceback is printed and Python process
will exit with the error code specified by the SystemExit instance.

 Call this function only when the error indicator is set. Otherwise it will cause a
 fatal error!

 If set_sys_last_vars is nonzero, the variables sys.last_type, sys.last_value and
 sys.last_traceback will be set to the type, value and traceback of the printed
 exception, respectively.
sourceraw docstring

PyErr_Restoreclj

(PyErr_Restore value traceback)

Set the error indicator from the three objects. If the error indicator is already set, it is cleared first. If the objects are NULL, the error indicator is cleared. Do not pass a NULL type and non-NULL value or traceback. The exception type should be a class. Do not pass an invalid exception type or value. (Violating these rules will cause subtle problems later.) This call takes away a reference to each object: you must own a reference to each object before the call and after the call you no longer own these references. (If you don’t understand this, don’t use this function. I warned you.)

Note

This function is normally only used by code that needs to save and restore the error indicator temporarily. Use PyErr_Fetch() to save the current error indicator.

Set the error indicator from the three objects. If the error indicator is already
set, it is cleared first. If the objects are NULL, the error indicator is cleared. Do
not pass a NULL type and non-NULL value or traceback. The exception type should be a
class. Do not pass an invalid exception type or value. (Violating these rules will
cause subtle problems later.) This call takes away a reference to each object: you
must own a reference to each object before the call and after the call you no longer
own these references. (If you don’t understand this, don’t use this function. I warned
you.)

Note

This function is normally only used by code that needs to save and restore the error
indicator temporarily. Use PyErr_Fetch() to save the current error indicator.
sourceraw docstring

PyErr_SetFromErrnoclj

(PyErr_SetFromErrno type)

Return value: Always NULL.

This is a convenience function to raise an exception when a C library function has returned an error and set the C variable errno. It constructs a tuple object whose first item is the integer errno value and whose second item is the corresponding error message (gotten from strerror()), and then calls PyErr_SetObject(type, object). On Unix, when the errno value is EINTR, indicating an interrupted system call, this calls PyErr_CheckSignals(), and if that set the error indicator, leaves it set to that. The function always returns NULL, so a wrapper function around a system call can write return PyErr_SetFromErrno(type); when the system call returns an error.

Return value: Always NULL.

This is a convenience function to raise an exception when a C library function has
returned an error and set the C variable errno. It constructs a tuple object whose
first item is the integer errno value and whose second item is the corresponding
error message (gotten from strerror()), and then calls PyErr_SetObject(type,
object). On Unix, when the errno value is EINTR, indicating an interrupted system
call, this calls PyErr_CheckSignals(), and if that set the error indicator, leaves it
set to that. The function always returns NULL, so a wrapper function around a system
call can write return PyErr_SetFromErrno(type); when the system call returns an
error.
sourceraw docstring

PyErr_SetNoneclj

(PyErr_SetNone type)

This is a shorthand for PyErr_SetObject(type, Py_None).

This is a shorthand for PyErr_SetObject(type, Py_None).
sourceraw docstring

PyErr_SetObjectclj

(PyErr_SetObject type value)

This function is similar to PyErr_SetString() but lets you specify an arbitrary Python object for the “value” of the exception.

This function is similar to PyErr_SetString() but lets you specify an arbitrary
Python object for the “value” of the exception.
sourceraw docstring

PyErr_SetStringclj

(PyErr_SetString type message)

This is the most common way to set the error indicator. The first argument specifies the exception type; it is normally one of the standard exceptions, e.g. PyExc_RuntimeError. You need not increment its reference count. The second argument is an error message; it is decoded from 'utf-8’.

This is the most common way to set the error indicator. The first argument specifies
the exception type; it is normally one of the standard exceptions,
e.g. PyExc_RuntimeError. You need not increment its reference count. The second
argument is an error message; it is decoded from 'utf-8’.
sourceraw docstring

PyErr_WarnExclj

(PyErr_WarnEx category message stack_level)

Issue a warning message. The category argument is a warning category (see below) or NULL; the message argument is a UTF-8 encoded string. stack_level is a positive number giving a number of stack frames; the warning will be issued from the currently executing line of code in that stack frame. A stack_level of 1 is the function calling PyErr_WarnEx(), 2 is the function above that, and so forth.

Warning categories must be subclasses of PyExc_Warning; PyExc_Warning is a subclass of PyExc_Exception; the default warning category is PyExc_RuntimeWarning. The standard Python warning categories are available as global variables whose names are enumerated at Standard Warning Categories.

For information about warning control, see the documentation for the warnings module and the -W option in the command line documentation. There is no C API for warning control.

Issue a warning message. The category argument is a warning category (see below) or
NULL; the message argument is a UTF-8 encoded string. stack_level is a positive number
giving a number of stack frames; the warning will be issued from the currently
executing line of code in that stack frame. A stack_level of 1 is the function calling
PyErr_WarnEx(), 2 is the function above that, and so forth.

 Warning categories must be subclasses of PyExc_Warning; PyExc_Warning is a subclass
 of PyExc_Exception; the default warning category is PyExc_RuntimeWarning. The
 standard Python warning categories are available as global variables whose names are
 enumerated at Standard Warning Categories.

 For information about warning control, see the documentation for the warnings module
 and the -W option in the command line documentation. There is no C API for warning
 control.
sourceraw docstring

PyErr_WarnExplicitclj

(PyErr_WarnExplicit category message filename lineno module registry)

Similar to PyErr_WarnExplicitObject() except that message and module are UTF-8 encoded strings, and filename is decoded from the filesystem encoding (os.fsdecode()).

Similar to PyErr_WarnExplicitObject() except that message and module are UTF-8
encoded strings, and filename is decoded from the filesystem encoding (os.fsdecode()).
sourceraw docstring

PyErr_WriteUnraisableclj

(PyErr_WriteUnraisable obj)

This utility function prints a warning message to sys.stderr when an exception has been set but it is impossible for the interpreter to actually raise the exception. It is used, for example, when an exception occurs in an del() method.

The function is called with a single argument obj that identifies the context in which the unraisable exception occurred. If possible, the repr of obj will be printed in the warning message.

An exception must be set when calling this function.

This utility function prints a warning message to sys.stderr when an exception has
been set but it is impossible for the interpreter to actually raise the exception. It
is used, for example, when an exception occurs in an __del__() method.

The function is called with a single argument obj that identifies the context in
which the unraisable exception occurred. If possible, the repr of obj will be printed
in the warning message.

An exception must be set when calling this function.
sourceraw docstring

PyExc_ArithmeticErrorclj

(PyExc_ArithmeticError)
source

PyExc_AssertionErrorclj

(PyExc_AssertionError)
source

PyExc_AttributeErrorclj

(PyExc_AttributeError)
source

PyExc_BaseExceptionclj

(PyExc_BaseException)
source

PyExc_BlockingIOErrorclj

(PyExc_BlockingIOError)
source

PyExc_BrokenPipeErrorclj

(PyExc_BrokenPipeError)
source

PyExc_BufferErrorclj

(PyExc_BufferError)
source

PyExc_BytesWarningclj

(PyExc_BytesWarning)
source

PyExc_ChildProcessErrorclj

(PyExc_ChildProcessError)
source

PyExc_ConnectionAbortedErrorclj

(PyExc_ConnectionAbortedError)
source

PyExc_ConnectionErrorclj

(PyExc_ConnectionError)
source

PyExc_ConnectionRefusedErrorclj

(PyExc_ConnectionRefusedError)
source

PyExc_ConnectionResetErrorclj

(PyExc_ConnectionResetError)
source

PyExc_DeprecationWarningclj

(PyExc_DeprecationWarning)
source

PyExc_EOFErrorclj

(PyExc_EOFError)
source

PyExc_Exceptionclj

(PyExc_Exception)
source

PyExc_FileExistsErrorclj

(PyExc_FileExistsError)
source

PyExc_FileNotFoundErrorclj

(PyExc_FileNotFoundError)
source

PyExc_FloatingPointErrorclj

(PyExc_FloatingPointError)
source

PyExc_FutureWarningclj

(PyExc_FutureWarning)
source

PyExc_GeneratorExitclj

(PyExc_GeneratorExit)
source

PyExc_ImportErrorclj

(PyExc_ImportError)
source

PyExc_ImportWarningclj

(PyExc_ImportWarning)
source

PyExc_IndentationErrorclj

(PyExc_IndentationError)
source

PyExc_IndexErrorclj

(PyExc_IndexError)
source

PyExc_InterruptedErrorclj

(PyExc_InterruptedError)
source

PyExc_IsADirectoryErrorclj

(PyExc_IsADirectoryError)
source

PyExc_KeyboardInterruptclj

(PyExc_KeyboardInterrupt)
source

PyExc_KeyErrorclj

(PyExc_KeyError)
source

PyExc_LookupErrorclj

(PyExc_LookupError)
source

PyExc_MemoryErrorclj

(PyExc_MemoryError)
source

PyExc_ModuleNotFoundErrorclj

(PyExc_ModuleNotFoundError)
source

PyExc_NameErrorclj

(PyExc_NameError)
source

PyExc_NotADirectoryErrorclj

(PyExc_NotADirectoryError)
source

PyExc_NotImplementedErrorclj

(PyExc_NotImplementedError)
source

PyExc_OSErrorclj

(PyExc_OSError)
source

PyExc_OverflowErrorclj

(PyExc_OverflowError)
source

PyExc_PendingDeprecationWarningclj

(PyExc_PendingDeprecationWarning)
source

PyExc_PermissionErrorclj

(PyExc_PermissionError)
source

PyExc_ProcessLookupErrorclj

(PyExc_ProcessLookupError)
source

PyExc_RecursionErrorclj

(PyExc_RecursionError)
source

PyExc_ReferenceErrorclj

(PyExc_ReferenceError)
source

PyExc_ResourceWarningclj

(PyExc_ResourceWarning)
source

PyExc_RuntimeErrorclj

(PyExc_RuntimeError)
source

PyExc_RuntimeWarningclj

(PyExc_RuntimeWarning)
source

PyExc_StopAsyncIterationclj

(PyExc_StopAsyncIteration)
source

PyExc_StopIterationclj

(PyExc_StopIteration)
source

PyExc_SyntaxErrorclj

(PyExc_SyntaxError)
source

PyExc_SyntaxWarningclj

(PyExc_SyntaxWarning)
source

PyExc_SystemErrorclj

(PyExc_SystemError)
source

PyExc_SystemExitclj

(PyExc_SystemExit)
source

PyExc_TabErrorclj

(PyExc_TabError)
source

PyExc_TimeoutErrorclj

(PyExc_TimeoutError)
source

PyExc_TypeErrorclj

(PyExc_TypeError)
source

PyExc_UnboundLocalErrorclj

(PyExc_UnboundLocalError)
source

PyExc_UnicodeDecodeErrorclj

(PyExc_UnicodeDecodeError)
source

PyExc_UnicodeEncodeErrorclj

(PyExc_UnicodeEncodeError)
source

PyExc_UnicodeErrorclj

(PyExc_UnicodeError)
source

PyExc_UnicodeTranslateErrorclj

(PyExc_UnicodeTranslateError)
source

PyExc_UnicodeWarningclj

(PyExc_UnicodeWarning)
source

PyExc_UserWarningclj

(PyExc_UserWarning)
source

PyExc_ValueErrorclj

(PyExc_ValueError)
source

PyExc_Warningclj

(PyExc_Warning)
source

PyExc_ZeroDivisionErrorclj

(PyExc_ZeroDivisionError)
source

PyException_GetCauseclj

(PyException_GetCause ex)

Return value: New reference.

Return the cause (either an exception instance, or None, set by raise ... from ...) associated with the exception as a new reference, as accessible from Python through cause.

Return value: New reference.

Return the cause (either an exception instance, or None, set by raise ... from ...)
associated with the exception as a new reference, as accessible from Python through
__cause__.
sourceraw docstring

PyException_GetContextclj

(PyException_GetContext ex)

Return value: New reference.

Return the context (another exception instance during whose handling ex was raised) associated with the exception as a new reference, as accessible from Python through context. If there is no context associated, this returns NULL.

Return value: New reference.

Return the context (another exception instance during whose handling ex was raised)
associated with the exception as a new reference, as accessible from Python through
__context__. If there is no context associated, this returns NULL.
sourceraw docstring

PyException_GetTracebackclj

(PyException_GetTraceback ex)

Return value: New reference.

Return the traceback associated with the exception as a new reference, as accessible from Python through traceback. If there is no traceback associated, this returns NULL.

Return value: New reference.

Return the traceback associated with the exception as a new reference, as accessible
from Python through __traceback__. If there is no traceback associated, this returns
NULL.
sourceraw docstring

PyException_SetCauseclj

(PyException_SetCause ex cause)

Set the cause associated with the exception to cause. Use NULL to clear it. There is no type check to make sure that cause is either an exception instance or None. This steals a reference to cause.

suppress_context is implicitly set to True by this function.

Set the cause associated with the exception to cause. Use NULL to clear it. There is
no type check to make sure that cause is either an exception instance or None. This
steals a reference to cause.

 __suppress_context__ is implicitly set to True by this function.
sourceraw docstring

PyException_SetContextclj

(PyException_SetContext ex ctx)

Set the context associated with the exception to ctx. Use NULL to clear it. There is no type check to make sure that ctx is an exception instance. This steals a reference to ctx.

Set the context associated with the exception to ctx. Use NULL to clear it. There is
no type check to make sure that ctx is an exception instance. This steals a reference
to ctx.
sourceraw docstring

PyException_SetTracebackclj

(PyException_SetTraceback ex tb)

Set the traceback associated with the exception to tb. Use Py_None to clear it.

Set the traceback associated with the exception to tb. Use Py_None to clear it.
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close