| Total Complexity | 0 |
| Total Lines | 73 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | """Declare async btree api.""" |
||
| 2 | from pkg_resources import DistributionNotFound, get_distribution |
||
| 3 | |||
| 4 | from .analyze import Node, analyze, stringify_analyze |
||
| 5 | from .control import decision, fallback, repeat_until, selector, sequence |
||
| 6 | from .decorator import ( |
||
| 7 | alias, |
||
| 8 | always_failure, |
||
| 9 | always_success, |
||
| 10 | decorate, |
||
| 11 | inverter, |
||
| 12 | is_failure, |
||
| 13 | is_success, |
||
| 14 | retry, |
||
| 15 | retry_until_failed, |
||
| 16 | retry_until_success, |
||
| 17 | ignore_exception, |
||
| 18 | ) |
||
| 19 | from .definition import ( |
||
| 20 | FAILURE, |
||
| 21 | SUCCESS, |
||
| 22 | AsyncInnerFunction, |
||
| 23 | CallableFunction, |
||
| 24 | NodeMetadata, |
||
| 25 | node_metadata, |
||
| 26 | ControlFlowException, |
||
| 27 | ) |
||
| 28 | from .leaf import action, condition |
||
| 29 | from .parallele import parallele |
||
| 30 | from .utils import afilter, amap, run |
||
| 31 | |||
| 32 | |||
| 33 | __all__ = [ |
||
| 34 | 'Node', |
||
| 35 | 'analyze', |
||
| 36 | 'stringify_analyze', |
||
| 37 | 'decision', |
||
| 38 | 'fallback', |
||
| 39 | 'repeat_until', |
||
| 40 | 'selector', |
||
| 41 | 'sequence', |
||
| 42 | 'alias', |
||
| 43 | 'always_failure', |
||
| 44 | 'always_success', |
||
| 45 | 'ignore_exception', |
||
| 46 | 'decorate', |
||
| 47 | 'inverter', |
||
| 48 | 'is_failure', |
||
| 49 | 'is_success', |
||
| 50 | 'retry', |
||
| 51 | 'retry_until_failed', |
||
| 52 | 'retry_until_success', |
||
| 53 | 'FAILURE', |
||
| 54 | 'SUCCESS', |
||
| 55 | 'AsyncInnerFunction', |
||
| 56 | 'CallableFunction', |
||
| 57 | 'ExceptionDecorator', |
||
| 58 | 'NodeMetadata', |
||
| 59 | 'node_metadata', |
||
| 60 | 'ControlFlowException', |
||
| 61 | 'action', |
||
| 62 | 'condition', |
||
| 63 | 'parallele', |
||
| 64 | 'afilter', |
||
| 65 | 'amap', |
||
| 66 | 'run', |
||
| 67 | ] |
||
| 68 | |||
| 69 | try: |
||
| 70 | __version__ = get_distribution('async-btree').version |
||
| 71 | except DistributionNotFound: # pragma: no cover |
||
| 72 | __version__ = '(local)' |
||
| 73 |