File tree 6 files changed +805
-1
lines changed
6 files changed +805
-1
lines changed Original file line number Diff line number Diff line change @@ -23,3 +23,9 @@ lint-mypy: phony
23
23
24
24
test : phony
25
25
pytest
26
+
27
+ docs : phony
28
+ lazydocs \
29
+ --overview-file README.md \
30
+ --src-base-url https://github.com/rustedpy/result/blob/master/ \
31
+ ./src/result
Original file line number Diff line number Diff line change @@ -106,6 +106,9 @@ exceptions.
106
106
107
107
## API
108
108
109
+ Auto generated API docs are also available at
110
+ [ ./docs/README.md] ( ./docs/README.md ) .
111
+
109
112
Creating an instance:
110
113
111
114
``` python
@@ -434,7 +437,11 @@ from the non-unix shell you're using on Windows.
434
437
- ` make test `
435
438
- ` make lint `
436
439
- You can also start a Python REPL and import ` result `
437
- 5 . Git commit and create a new PR.
440
+ 5 . Update documentation
441
+ - Edit any relevant docstrings, markdown files
442
+ - Run ` make docs `
443
+ 6 . Add an entry to the [ changelog] ( ./CHANGELOG.md )
444
+ 5 . Git commit all your changes and create a new PR.
438
445
439
446
[ pydocs-venv ] : https://docs.python.org/3/library/venv.html
440
447
Original file line number Diff line number Diff line change
1
+ title: API Reference
2
+ nav:
3
+ - Overview: README.md
4
+ - ...
Original file line number Diff line number Diff line change
1
+ <!-- markdownlint-disable -->
2
+
3
+ # API Overview
4
+
5
+ ## Modules
6
+
7
+ - [ ` result ` ] ( ./result.md#module-result )
8
+
9
+ ## Classes
10
+
11
+ - [ ` result.DoException ` ] ( ./result.md#class-doexception ) : This is used to signal to ` do() ` that the result is an ` Err ` ,
12
+ - [ ` result.Err ` ] ( ./result.md#class-err ) : A value that signifies failure and which stores arbitrary data for the error.
13
+ - [ ` result.Ok ` ] ( ./result.md#class-ok ) : A value that indicates success and which stores arbitrary data for the return value.
14
+ - [ ` result.UnwrapError ` ] ( ./result.md#class-unwraperror ) : Exception raised from `` .unwrap_<...> `` and `` .expect_<...> `` calls.
15
+
16
+ ## Functions
17
+
18
+ - [ ` result.as_async_result ` ] ( ./result.md#function-as_async_result ) : Make a decorator to turn an async function into one that returns a `` Result `` .
19
+ - [ ` result.as_result ` ] ( ./result.md#function-as_result ) : Make a decorator to turn a function into one that returns a `` Result `` .
20
+ - [ ` result.do ` ] ( ./result.md#function-do ) : Do notation for Result (syntactic sugar for sequence of ` and_then() ` calls).
21
+ - [ ` result.do_async ` ] ( ./result.md#function-do_async ) : Async version of do. Example:
22
+ - [ ` result.is_err ` ] ( ./result.md#function-is_err ) : A typeguard to check if a result is an Err
23
+ - [ ` result.is_ok ` ] ( ./result.md#function-is_ok ) : A typeguard to check if a result is an Ok
24
+
25
+
26
+ ---
27
+
28
+ _ This file was automatically generated via [ lazydocs] ( https://github.com/ml-tooling/lazydocs ) ._
You can’t perform that action at this time.
0 commit comments