MCPcopy Index your code
hub / github.com/RustPython/RustPython / with_traceback

Method with_traceback

crates/vm/src/exceptions.rs:681–684  ·  view source on GitHub ↗
(self, tb: Option<PyTracebackRef>)

Source from the content-addressed store, hash-verified

679impl PyRef<PyBaseException> {
680 #[pymethod]
681 fn with_traceback(self, tb: Option<PyTracebackRef>) -> PyResult<Self> {
682 *self.traceback.write() = tb;
683 Ok(self)
684 }
685
686 #[pymethod]
687 fn add_note(self, note: PyStrRef, vm: &VirtualMachine) -> PyResult<()> {

Callers 13

_showtracebackMethod · 0.80
throwMethod · 0.80
athrowMethod · 0.80
throwMethod · 0.80
resultMethod · 0.80
_convert_future_excFunction · 0.80
_call_matcherMethod · 0.80
__exit__Method · 0.80
testWithTracebackMethod · 0.80
fMethod · 0.80
taskFunction · 0.80

Calls 1

writeMethod · 0.45

Tested by 4

testWithTracebackMethod · 0.64
fMethod · 0.64
taskFunction · 0.64