Intraspector decorator for python
Project description
# Python Intraspector
This project is currently under development. APIs will change.
## Example Usage
Declare Intraspector object
```python
from python-intraspector import Intraspector
global intraspector
intraspector = Intraspector()
```
Add Intraspector decorator to functions you want recorded.
```python
@intraspector.record()
def somefunction(args, kwargs):
secondCall(args)
@intraspector.record()
def secondCall(args):
dont_record_this()
def dont_record_this():
# Do something
```
Return Intraspector trace
```python
if intraspector.get_debug_mode:
value['intraspector_trace'] = intraspector.get_trace()
```
## Related Modules
[React Fluxible Intraspector](https://github.com/BespokeInsights/react-fluxible-intraspector)
This project is currently under development. APIs will change.
## Example Usage
Declare Intraspector object
```python
from python-intraspector import Intraspector
global intraspector
intraspector = Intraspector()
```
Add Intraspector decorator to functions you want recorded.
```python
@intraspector.record()
def somefunction(args, kwargs):
secondCall(args)
@intraspector.record()
def secondCall(args):
dont_record_this()
def dont_record_this():
# Do something
```
Return Intraspector trace
```python
if intraspector.get_debug_mode:
value['intraspector_trace'] = intraspector.get_trace()
```
## Related Modules
[React Fluxible Intraspector](https://github.com/BespokeInsights/react-fluxible-intraspector)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
intraspector-0.1.0.tar.gz
(1.8 kB
view hashes)
Built Distribution
Close
Hashes for intraspector-0.1.0-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1fcd1d3c65a6fba6fe089e0621308461f8cef7b3218d10bf96c71e01cb69c03f |
|
MD5 | d927dbc61c95813f9fa7bb5078eee347 |
|
BLAKE2b-256 | fae0cf1400bcc55c2938aa0c94f9a0542e2f5c4f8e2ec48aae375fdaca0c22e8 |