Releases: pomponchik/cantok
Releases · pomponchik/cantok
0.0.31
0.0.30
Microscopic change.
- Now the
repr
forConditionToken
works not only with ordinary functions, but also with objects that have the__call__
method.
0.0.29
A small update, but recommended.
- The operation of summing two timeout tokens is optimized. Now, in some cases, the token with an earlier expiration will remain alone.
0.0.28
A useful little update.
- Text representations of various tokens are now shorter and more beautiful.
- Added a new optimization: now, if possible, the token sum operation does not create an additional
SimpleToken
. Due to this, the token graph becomes smaller and all operations on it are faster.
0.0.27
Purely stabilization update, the library's capabilities have not changed at all.
- Added some new tests.
- Improved code examples in the documentation: added output comments.
0.0.26
An important update dedicated to internal optimizations. The token interfaces have not changed in any way.
- Each token now caches information that one of the tokens embedded in it has been canceled. When the token status is requested again, it will not bypass the graph, but will immediately return the result.
- Added an optimization of the token summation operation: now, if you add a
SimpleToken()
object that has not been saved to any variable to any another token, this object will be ignored. Thus, the token tree becomes smaller. That is, the operationSimpleToken() + TimeoutToken(5)
now gives the resultSimpleToken(TimeoutToken(5))
, notSimpleToken(SimpleToken(), TimeoutToken(5))
like before. In addition, this leads to the fact that the sums of more than 3 tokens become "flat". - Fixed a bug where you could set the
cancelled
attribute of a token whose nested token was canceled toFalse
. - Added the
__slots__
attribute to the cancellation report object. This allowed you to save an extra 8 bytes on each such object, provided that you have Python 3.10 or later. - Type hints slightly improved. The file structure of the project is now more extensive. The package metadata was slightly expanded.
0.0.25
A little update.
- Added a small optimization. Now, when adding and embedding tokens,
DefaultToken
's are ignored. - Added a test coverage gate - 100%.
0.0.24
Technical release, library features have not changed.
- Expanded the number of checks that occur in CI. Now linters are applied to tests as well.
- Made some minor corrections (for example, removing unnecessary imports) to the tests.
- Added issue templates.
- Fixed a typo in the documentation.
0.0.23
A small but important update.
- Added a new type of tokens -
DefaultToken
. - Expanded the documentation.