Debugging
tap(item: T, label: Optional[str] = None) -> T
Prints the given item with an optional label and returns it.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
item |
T
|
The item to print. |
required |
label |
Optional[str]
|
The label to use. |
None
|
Returns:
Type | Description |
---|---|
T
|
The given item. |
Source code in src/funcs/debugging.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
|
inspect(function: Inspect[T], item: T) -> T
Inspects the given item with the function
and returns it.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
function |
Inspect[T]
|
The function to use. |
required |
item |
T
|
The item to inspect. |
required |
Returns:
Type | Description |
---|---|
T
|
The given item. |
Source code in src/funcs/debugging.py
34 35 36 37 38 39 40 41 42 43 44 45 46 |
|