Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decorator that can issue a pre and post hook function. #28

Open
thecodenomad opened this issue Jul 19, 2021 · 0 comments
Open

Decorator that can issue a pre and post hook function. #28

thecodenomad opened this issue Jul 19, 2021 · 0 comments

Comments

@thecodenomad
Copy link
Contributor

It would be nice to have a decorator that can check for "before_hook" and "after_hook" to provide a simple hook mechanism for specific functions.

The idea would be to look at kwargs to pull out values for before_hook and after_hook as tuples. These would then get executed prior to the main function execution and after the main function execution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant