Skip to content

Commit

Permalink
Version 0.6.0 with asyncio support
Browse files Browse the repository at this point in the history
  • Loading branch information
sobolevn committed Jun 7, 2019
1 parent 88566df commit c9e1e5f
Show file tree
Hide file tree
Showing 10 changed files with 252 additions and 108 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Expand Up @@ -3,6 +3,14 @@
We follow Semantic Versions since the `0.1.0` release.


## Version 0.6.0

### Features

- `safe` and `pipeline` now supports `asyncio`
- `is_successful` now returns `Literal` types if possible


## Version 0.5.0

### Features
Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -15,7 +15,7 @@ Make your functions return something meaningful, typed, and safe!
- Enforces [Railway Oriented Programming](https://fsharpforfunandprofit.com/rop/)
- Fully typed with annotations and checked with `mypy`, [PEP561 compatible](https://www.python.org/dev/peps/pep-0561/)
- Pythonic and pleasant to write and to read (!)
- WIP: `asyncio` support
- Support functions and coroutines, framework agnostic


## Installation
Expand Down
11 changes: 8 additions & 3 deletions docs/pages/functions.rst
Expand Up @@ -29,7 +29,8 @@ pipeline
--------

What is a ``pipeline``?
It is a more user-friendly syntax to work with containers.
It is a more user-friendly syntax to work with containers
that support both async and regular functions.

Consider this task.
We were asked to create a method
Expand Down Expand Up @@ -162,6 +163,8 @@ safe
regular functions that can throw exceptions to functions
that return :class:`Result <returns.result.Result>` type.

Supports both async and regular functions.

.. code:: python
from returns.functions import safe
Expand Down Expand Up @@ -199,9 +202,9 @@ This effect can be reduced
with the help of `Design by Contract <https://en.wikipedia.org/wiki/Design_by_contract>`_
with these implementations:

- https://github.com/Parquery/icontract
- https://github.com/orsinium/deal
- https://github.com/deadpixi/contracts
- https://github.com/orsinium/deal
- https://github.com/Parquery/icontract


compose
Expand All @@ -221,6 +224,8 @@ Composition is also type-safe.
The only limitation is that we only support
functions with one argument and one return to be composed.

Only works with regular functions (not async).


raise_exception
---------------
Expand Down

0 comments on commit c9e1e5f

Please sign in to comment.