MCPcopy Create free account
hub / github.com/blacklanternsecurity/bbot / success

Method success

bbot/modules/base.py:1631–1645  ·  view source on GitHub ↗

Logs a success message, and optionally the stack trace of the most recent exception. Args: *args: Variable-length argument list to pass to the logger. trace (bool, optional): Whether to log the stack trace of the most recently caught exception. Defaults to False.

(self, *args, trace=False, **kwargs)

Source from the content-addressed store, hash-verified

1629 self.trace()
1630
1631 def success(self, *args, trace=False, **kwargs):
1632 """Logs a success message, and optionally the stack trace of the most recent exception.
1633
1634 Args:
1635 *args: Variable-length argument list to pass to the logger.
1636 trace (bool, optional): Whether to log the stack trace of the most recently caught exception. Defaults to False.
1637 **kwargs: Arbitrary keyword arguments to pass to the logger.
1638
1639 Examples:
1640 >>> self.success("Operation completed successfully")
1641 >>> self.success("Operation completed with a trace", trace=True)
1642 """
1643 self.log.success(*args, extra={"scan_id": self.scan.id}, **kwargs)
1644 if trace:
1645 self.trace()
1646
1647 def hugesuccess(self, *args, trace=False, **kwargs):
1648 """Logs a whole message in emboldened green text, and optionally the stack trace of the most recent exception.

Callers 6

_mainFunction · 0.45
reportMethod · 0.45
reportMethod · 0.45
setupMethod · 0.45
loadMethod · 0.45
ensure_rootMethod · 0.45

Calls 1

traceMethod · 0.95

Tested by

no test coverage detected