py Documentation - Read the Docs
py Documentation - Read the Docs
py Documentation - Read the Docs
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
<strong>py</strong> <strong>Documentation</strong>, Release 1.4.27.dev1<br />
this allows cutting <strong>the</strong> first part of a Traceback instance e.g. for formatting reasons (removing some<br />
uninteresting bits that deal with handling of <strong>the</strong> exception/traceback)<br />
filter(fn=)<br />
return a Traceback instance with certain items removed<br />
fn is a function that gets a single argument, a TracebackItem instance, and should return True when <strong>the</strong><br />
item should be added to <strong>the</strong> Traceback, False when not<br />
by default this removes all <strong>the</strong> TracebackItems which are hidden (see ishidden() above)<br />
getcrashentry()<br />
return last non-hidden traceback entry that lead to <strong>the</strong> exception of a traceback.<br />
recursionindex()<br />
return <strong>the</strong> index of <strong>the</strong> frame/TracebackItem where recursion originates if appropriate, None if no recursion<br />
occurred<br />
append()<br />
L.append(object) – append object to end<br />
count(value) → integer – return number of occurrences of value<br />
extend()<br />
L.extend(iterable) – extend list by appending elements from <strong>the</strong> iterable<br />
index(value[, start[, stop]]) → integer – return first index of value.<br />
Raises ValueError if <strong>the</strong> value is not present.<br />
insert()<br />
L.insert(index, object) – insert object before index<br />
pop([index]) → item – remove and return item at index (default last).<br />
Raises IndexError if list is empty or index is out of range.<br />
remove()<br />
L.remove(value) – remove first occurrence of value. Raises ValueError if <strong>the</strong> value is not present.<br />
reverse()<br />
L.reverse() – reverse IN PLACE<br />
sort()<br />
L.sort(cmp=None, key=None, reverse=False) – stable sort IN PLACE; cmp(x, y) -> -1, 0, 1<br />
24 Chapter 3. <strong>py</strong>.code: higher level <strong>py</strong>thon code and introspection objects