Promise

Latest version: v2.3

Safety actively analyzes 685525 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

2.3.0

Changelog

* Distribute type module maker for mypy 66
* Fix memory leak on dynamically created types 76
* Make `Dataloader` keep cache object 73
* Fix Python 3.7 deprecation warnings 79
* Make `Promise` and `Dataloader` thread-safe 81

2.2.0

(changelog to come soon)

2.2.0rc1

2.0.1

Changelog
* Fixed await blocked by context exit 26488d56c7bdba8ace8c75e63efe8c42b6217e82 (thanks to schrockn for the feedback!)
* Fixed `Promise.resolve(coroutine)` returning a `Task` instead of a `Promise` [code sample](https://github.com/syrusakbary/promise/commit/9f7282b18ca20572e8c78da6546b8f50d90ae4c2diff-1f1bd939eb0f45e21e3ee5e32c2df9d7R31)

2.0.0

Changelog

This is a completely rewritten version of `Promise` in python, based in the ultra-performant and low-memory [bluebird.js](https://github.com/petkaantonov/bluebird/) promise implementation.

* New [dataloader](https://github.com/syrusakbary/promise/blob/master/promise/dataloader.py) implementation
* `Promise.resolve` now acts the same as `Promise.cast`
* `Promise.reject` is now a static method (instead of a instance one, like in previous versions)
* New `Promise.all` fast implementation.
* `promise.get` raised exceptions now include traceback.
* Custom schedulers for `Promise` resolution.

Deprecation

* `Promise.promisify` is now a function wrapper, that executes the function, but returning a `Promise`. Calling `Promise.promisify` on a static value will be deprecated in next versions.
* `promise.fulfill` is renamed to `promise.do_fulfill`
* `promise.rejected`/`promise.reject` is renamed to `promise.do_reject`

1.0.1

Changelog
- `is_thenable` now returns `True` for coroutines. 8b0d5da3dca2d99671b820478ef74353ac24c97b

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.