sage.core.errors
Filename : errors.py Description : Short description of the file
Created on 2025-11-23 01:42:15
__author__ = Narenraju Nagarajan __copyright__ = Copyright 2025, ProjectName __license__ = MIT Licence __version__ = 0.0.1 __maintainer__ = Narenraju Nagarajan __affiliation__ = N/A __email__ = N/A __status__ = [‘inProgress’, ‘Archived’, ‘inUsage’, ‘Debugging’]
GitHub Repository: NULL
Documentation: NULL
Attributes
Functions
|
Call |
Module Contents
- safe_call(func, *args, fallback_return=None, **kwargs)[source]
Call
funcand suppress any exception, returning a fallback value instead.Logs the exception at ERROR level (with function name, args, kwargs, and traceback message) then returns
fallback_returnso the caller can continue gracefully.- Parameters:
func (callable) – Function to call.
*args – Positional arguments forwarded to
func.fallback_return (any) – Value returned if
funcraises (defaultNone).**kwargs – Keyword arguments forwarded to
func.
- Returns:
The return value of
func(*args, **kwargs), orfallback_returnif an exception was raised.- Return type:
any