Skip to content

Releases: gqylpy/exceptionx

4.1.4

31 Jul 00:56
84c25e4
Compare
Choose a tag to compare
  1. Remove the verification statement for anti-static imports.
  2. Optimize a small number of code snippets to improve efficiency and readability.

  1. 移除反静态导入的校验语句。
  2. 优化少量代码片段,提升效率和可读性。

4.1.3

26 Jul 02:40
10d695e
Compare
Choose a tag to compare
  1. Fix the issue of time2second matching empty strings.
  2. Optimize time2second regular expression matching to ignore case.
  3. Improve the description of two exception messages to make the semantics more accurate.

  1. 修复 time2second 匹配空字符串的问题。
  2. 优化 time2second 正则匹配时忽略大小写。
  3. 改进两个异常描述信息,使语义更准确。

4.1.2

24 Jul 01:00
4e318da
Compare
Choose a tag to compare
  1. Optimize the implementation of the inner function time2second.
  2. Update the example code to provide examples in a recommended way.

  1. 优化内部函数 time2second 的实现。
  2. 更新示例代码以更推荐的方式提供示例。

4.1.1

23 Jul 00:43
219b970
Compare
Choose a tag to compare
  1. The time parameter in Retry supports passing in the format of unit time (e.g., "1h2m3s").
  2. Optimize a small amount of other code.

  1. Retry 中的时间参数支持以单位时间(如 "1h2m3s")的格式传递。
  2. 优化其它少量代码。

4.1

22 Jul 00:54
d332769
Compare
Choose a tag to compare
4.1
  1. TryExcept and TryContext now support handling exceptions based on exception message strings and have added the functionality to negate exception types.
  2. Both @Retry and @Retry() are now supported as valid syntax, as well as TryExcept.
  3. Fixed an issue: The retry counter in Retry incorrectly started from zero. #4
  4. Fixed an issue: The stacklevel positioning of the logger object was sometimes inaccurate. #5
  5. Optimized exception output for Retry, adding display for limit_time and event.
  6. Fixed a serious issue in Retry where exception information might be "spammed" output.
  7. Added type checking for the parameter etype.
  8. The internal default value for retry events has been changed to None.
  9. Updated annotations, comments, and documentation files for the above changes.

  1. TryExceptTryContext 现在支持按异常消息字符串处理异常,并新增了异常类型取反的功能。
  2. 同时支持 @Retry@Retry() 作为有效语法,亦 TryExcept
  3. 修复问题:Retry 中重试计数器错误地从零开始。 #4
  4. 修复问题:日志记录器对象 stacklevel 定位有时不准确。 #5
  5. 优化了 Retry 的异常输出,增加了对 limit_timeevent 显示。
  6. 修复了 Retry 中可能会 “疯狂输出” 异常信息的严重问题。
  7. 添加对参数 etype 的类型校验。
  8. 重试事件的内部默认值修改为 None
  9. 针对以上改动更新注解,注释及自述文件。

4.0

15 Jul 01:18
Compare
Choose a tag to compare
4.0
  1. This update mainly focuses on extensive functional enhancements and optimizations to the Retry decorator.
  2. The Retry decorator now subtracts the runtime of the program from the interval time before each retry.
  3. The Retry decorator by removing the type conversion for parameters count and sleep.
  4. The Retry decorator adds a retry mechanism based on total execution time. #1
  5. The Retry decorator adds a retry mechanism based on external event. #2
  6. The Retry decorator Adds a retry mechanism based on exception message. #3
  7. Completely remove the deprecated decorators TryExceptAsync and RetryAsync.
  8. Add more detailed descriptions of internal exceptions.
  9. Refactor module descriptions and update the readme file.

  1. 此次更新主要对 Retry 装饰器进行了大量的功能增强和优化改动。
  2. Retry 装饰器现在会在每次重试时,从间隔时间中减去程序的运行时间。
  3. Retry 装饰器中移除对参数 countsleep 的类型转换,若类型错误将直接抛出异常。
  4. Retry 装饰器中添加基于总执行时间的重试机制。 #1
  5. Retry 装饰器中添加基于外部条件(或事件)的重试机制。 #2
  6. Retry 装饰器中添加基于异常消息的重试机制。 #3
  7. 彻底移除已弃用的装饰器 TryExceptAsyncRetryAsync
  8. 增加更详细的内部异常描述。
  9. 重构模块描述,更新自述文件,确保准确反映当前功能和用途。