The `exceptionx` is a flexible and convenient Python exception handling library that allows you to dynamically create exception classes and provides various exception handling mechanisms.
TryExcept and TryContext now support handling exceptions based on exception message strings and have added the functionality to negate exception types.
Both @Retry and @Retry() are now supported as valid syntax, as well as TryExcept.
Fixed an issue: The retry counter in Retry incorrectly started from zero. #4
Fixed an issue: The stacklevel positioning of the logger object was sometimes inaccurate. #5
Optimized exception output for Retry, adding display for limit_time and event.
Fixed a serious issue in Retry where exception information might be "spammed" output.
Added type checking for the parameter etype.
The internal default value for retry events has been changed to None.
Updated annotations, comments, and documentation files for the above changes.
TryExcept
andTryContext
now support handling exceptions based on exception message strings and have added the functionality to negate exception types.@Retry
and@Retry()
are now supported as valid syntax, as well asTryExcept
.Retry
incorrectly started from zero. #4stacklevel
positioning of the logger object was sometimes inaccurate. #5Retry
, adding display forlimit_time
andevent
.Retry
where exception information might be "spammed" output.etype
.None
.Updated annotations, comments, and documentation files for the above changes.
TryExcept
和TryContext
现在支持按异常消息字符串处理异常,并新增了异常类型取反的功能。@Retry
和@Retry()
作为有效语法,亦TryExcept
。Retry
中重试计数器错误地从零开始。 #4stacklevel
定位有时不准确。 #5Retry
的异常输出,增加了对limit_time
和event
显示。Retry
中可能会 “疯狂输出” 异常信息的严重问题。etype
的类型校验。None
。