mgedmin / mgedmin/profilehooks
Consider adding parameter for enabling/disabling profiling
- Dominant language
- Python
- Stars
- 338
- Forks
- 29
- PR merge metrics
- No merged PRs in 30d
Description
It would be nice if it was possible to disable profiling with just changing some package variable.
E.g.
```
PROFILING=False
@timecall(immediate=True, enabled=PROFILING)
def someFunction():
```
I assume you could in decorator just return decorated function if `enabled` is False.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at the timecall decorator entry point and inspect how its arguments are processed. Add an enabled option that leaves the decorated function unchanged when false, then verify that profiling remains active by default and can be disabled through a package variable as shown in the issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- performance
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100