Each problem has its own frame, stacktrace and thread type (for problems that can have multiple threads).
Warning
The GdbFrame, GdbThread, and GdbStacktrace have rather limited functionality, cannot be used in reports, and will probably be removed in the future.
Stack frame corresponds to a function invocation saved on the stack. All frame types are derived from the BaseFrame.
satyr.CoreFrame - class representing a frame in a native executable
Usage: satyr.CoreFrame() - creates an empty frame
Address of the machine code in memory (long)
Build ID of the ELF file (string)
Offset of the instruction pointer from the start of the executable segment (long)
Usage: frame.dup()
Returns: satyr.CoreFrame - a new clone of the frame
Clones the frame object. All new structures are independent of the original object.
Name of the executable or shared library (string)
Fingerprint of the current function (string)
True if fingerprint is already hashed (bool)
Function name (string)
satyr.JavaFrame - class representing a java frame
Usage:
satyr.JavaFrame() - creates an empty frame
satyr.JavaFrame(str) - parses str and fills the frame object
Class path (string)
Usage: frame.dup()
Returns: satyr.JavaFrame - a new clone of frame
Clones the frame object. All new structures are independent of the original object.
File line (positive integer)
File name (string)
True if frame is an exception frame (bool)
True if method is native, always false if frame is an exception (bool)
Exception message (string)
Fully qualified domain name (string)
satyr.KerneloopsFrame - class representing a frame in a kerneloops
Usage:
satyr.KerneloopsFrame() - creates an empty frame
satyr.KerneloopsFrame(str) - parses str and fills the frame object
Address of the current instruction (long)
Usage: frame.dup()
Returns: satyr.KerneloopsFrame - a new clone of frame
Clones the frame object. All new structures are independent of the original object.
Address of the caller’s instruction (long)
Caller function length (long)
Caller function name (string)
Caller function offset (long)
Module owning the caller function (string)
Function length (long)
Function name (string)
Function offset (long)
Module owning the function (string)
True if the the frame is guaranteed to be real (bool)
satyr.PythonFrame - class representing a python frame
Usage:
satyr.PythonFrame() - creates an empty frame
satyr.PythonFrame(str) - parses str and fills the frame object
Usage: frame.dup()
Returns: satyr.PythonFrame - a new clone of frame
Clones the frame object. All new structures are independent of the original object.
Source line number (positive integer)
Source file name (string)
Function name (string)
Remaining line contents (string)
True if the frame is not a real file, like stdin or eval’d string (bool)
True if the frame doesn’t belong to a named function, e.g. lambda or a module
satyr.GdbFrame - class representing a frame in a thread
Usage:
satyr.GdbFrame() - creates an empty frame
satyr.GdbFrame(str) - parses str and fills the frame object
Address of the current instruction (long)
Usage: frame.calls_func(name)
name: string - function name
Returns: integer - 0 = False, 1 = True
Checks whether the frame represents a call to a function with given name.
Usage: frame.calls_func_in_file(name, filename)
name: string - function name
filename: string - file name
Returns: integer - 0 = False, 1 = True
Checks whether the frame represents a call to a function with given name from a given file.
Usage: frame.dup()
Returns: satyr.GdbFrame - a new clone of the frame
Clones the frame object. All new structures are independent of the original object.
Function name (string)
Function type (string)
Executable file name (string)
Frame number (positive integer)
True if the frame is signal handler (bool)
Source file name (string)
Source line number (positive integer)
Thread classes are defined only for problems that can have multiple thread. They all have BaseThread as a base class.
satyr.BaseThread - base class for threads
Usage: thread.distance(other, dist_type=DISTANCE_LEVENSHTEIN)
other: other thread
dist_type (optional): one of DISTANCE_LEVENSHTEIN, DISTANCE_JARO_WINKLER, DISTANCE_JACCARD or DISTANCE_DAMERAU_LEVENSHTEIN
Returns: positive float - distance between the two threads
A list containing objects representing frames in a thread.
Usage: thread.get_duphash(frames=0, flags=DUPHASH_NORMAL, prefix=’‘)
Returns: string - thread’s duplication hash
frames: integer - number of frames to use (default 0 means use all)
flags: integer - bitwise sum of flags (DUPHASH_NORMAL, DUPHASH_NOHASH, DUPHASH_NONORMALIZE)
prefix: string - string to be prepended in front of the text before hashing
satyr.CoreThread - class representing a thread in a stacktrace
Usage: satyr.CoreThread() - creates an empty thread
Usage: thread.dup()
Returns: satyr.CoreThread - a new clone of thread
Clones the thread object. All new structures are independent of the original object.
satyr.JavaThread - class representing a thread in a stacktrace
Usage:
satyr.JavaThread() - creates an empty thread
satyr.JavaThread(str) - parses str and fills the thread object
Usage: thread.dup()
Returns: satyr.JavaThread - a new clone of thread
Clones the thread object. All new structures are independent of the original object.
Usage: thread.format_funs()
Returns: string
Thread name (string)
Usage: thread.quality()
Returns: float - 0..1, thread quality
Computes the ratio #good / #all. See quality_counts method for more.
Usage: thread.quality_counts()
Returns: tuple (ok, all) - ok representing number of ‘good’ frames, all representing total number of frames
Counts the number of ‘good’ frames and the number of all frames. ‘Good’ means the function name is known (not just ‘??’).
satyr.GdbThread - class representing a thread in a stacktrace
Usage:
satyr.GdbThread() - creates an empty thread
satyr.GdbThread(str) - parses str and fills the thread object
satyr.GdbThread(str, only_funs=True) - parses list of function names
Usage: thread.dup()
Returns: satyr.GdbThread - a new clone of thread
Clones the thread object. All new structures are independent of the original object.
Usage: thread.format_funs()
Returns: string
Thread number (positive integer)
Usage: thread.quality()
Returns: float - 0..1, thread quality
Computes the ratio #good / #all. See quality_counts method for more.
Usage: thread.quality_counts()
Returns: tuple (ok, all) - ok representing number of ‘good’ frames, all representing total number of frames
Counts the number of ‘good’ frames and the number of all frames. ‘Good’ means the function name is known (not just ‘??’).
Single threaded stacktraces have SingleThreadStacktrace as their base class, which is in turn derived from BaseThread. This means that SingleThreadStacktrace can be treated as a thread:
Stacktrace types with the possibility of multiple threads are derived from MultiThreadStacktrace:
satyr.SingleThreadStacktrace - base class for stacktrace with single thread
Reference to the thread that caused the crash, if known
Usage: SomeStacktrace.from_json(json_string) (class method)
Returns: stacktrace (of SomeStacktrace class) deserialized from json_string
json_string: string - json input
Usage: stacktrace.get_bthash([flags])
Returns: string - hash of the stacktrace
flags: integer - bitwise sum of flags (BTHASH_NORMAL, BTHASH_NOHASH)
Usage: stacktrace.to_short_text([max_frames])
Returns short text representation of the stacktrace. If max_frames is specified, the result includes only that much topmost frames.
satyr.MultiThreadStacktrace - base class for stacktrace with multiple threads
Reference to the thread that caused the crash, if known
Usage: SomeStacktrace.from_json(json_string) (class method)
Returns: stacktrace (of SomeStacktrace class) deserialized from json_string
json_string: string - json input
Usage: stacktrace.get_bthash([flags])
Returns: string - hash of the stacktrace
flags: integer - bitwise sum of flags (BTHASH_NORMAL, BTHASH_NOHASH)
A list containing the objects representing threads in the stacktrace.
Usage: stacktrace.to_short_text([max_frames])
Returns short text representation of the stacktrace. If max_frames is specified, the result includes only that much topmost frames.
satyr.CoreStacktrace - class representing a core stacktrace
Usage:
satyr.CoreStacktrace() - creates an empty stacktrace
satyr.CoreStacktrace(json) - creates stacktrace object from JSON string
Usage: stacktrace.dup()
Returns: satyr.CoreStacktrace - a new clone of core stacktrace
Clones the stacktrace object. All new structures are independent of the original object.
Name of the executable (string)
Signal number (int)
satyr.JavaStacktrace - class representing a java stacktrace
Usage:
satyr.JavaStacktrace() - creates an empty stacktrace
satyr.JavaStacktrace(str) - parses str and fills the stacktrace object
Usage: stacktrace.dup()
Returns: satyr.JavaStacktrace - a new clone of java stacktrace
Clones the stacktrace object. All new structures are independent of the original object.
satyr.Kerneloops - class representing a kerneloops stacktrace
Usage:
satyr.Kerneloops() - creates an empty kerneloops stacktrace
satyr.Kerneloops(str) - parses str and fills the kerneloops stacktrace object
Usage: stacktrace.dup()
Returns: satyr.Kerneloops - a new clone of kerneloops stacktrace
Clones the kerneloops object. All new structures are independent of the original object.
Modules loaded at the time of the event (list of strings)
Usage: stacktrace.normalize()
Normalizes the stacktrace.
Original text of the kerneloops (string)
Dictionary of kernel taint flags. Keys are the flag names, values are booleans indicating whether the flag is set.
Kernel version (string)
satyr.PythonStacktrace - class representing a python stacktrace
Usage:
satyr.PythonStacktrace() - creates an empty python stacktrace
satyr.PythonStacktrace(str) - parses str and fills the python stacktrace object
Usage: stacktrace.dup()
Returns: satyr.PythonStacktrace - a new clone of python stacktrace
Clones the PythonStacktrace object. All new structures are independent of the original object.
Exception type (string)
satyr.GdbStacktrace - class representing a stacktrace
Usage:
satyr.GdbStacktrace() - creates an empty stacktrace
satyr.GdbStacktrace(str) - parses str and fills the stacktrace object
Readonly. By default the field contains None. After calling the find_crash_frame method, a reference to satyr.Frame object is stored into the field.
Usage: stacktrace.dup()
Returns: satyr.GdbStacktrace - a new clone of stacktrace
Clones the stacktrace object. All new structures are independent of the original object.
Usage: stacktrace.find_address(address)
address: long - address to find
Returns: satyr.Sharedlib object or None if not found
Looks whether the given address belongs to a shared library.
Usage: stacktrace.find_crash_frame()
Returns: satyr.Frame - crash frame
Finds crash frame in the stacktrace. Also sets the stacktrace.crashframe field.
A list containing the satyr.Sharedlib objects representing shared libraries loaded at the moment of crash.
Usage: stacktrace.limit_frame_depth(N)
N: positive integer - frame depth
Crops all threads to only contain first N frames.
Usage: stacktrace.normalize()
Normalizes all threads in the stacktrace.
Usage: stacktrace.quality_complex()
Returns: float - 0..1, stacktrace quality
Computes the quality from stacktrace, crash thread and frames around the crash.
Usage: stacktrace.quality_simple()
Returns: float - 0..1, stacktrace quality
Computes the quality from stacktrace itself.
Usage: stacktrace.set_libnames()
Sets library names according to sharedlibs data.
Usage: stacktrace.to_short_text([max_frames])
Returns short text representation of the crash thread. If max_frames is specified, the result includes only that much topmost frames.