Flashes Home Search Notifications Sign in Post
Monty @ The Python Coding Place @thepythoncodingplace.com · Mar 22

Now, you need a counter to count how many times the decorated function–`wrapper()`–is called. You can add another data attribute

0 likes 1 replies

?

Replies

Monty @ The Python Coding Place · Mar 22

This data attribute, `.counter`, can also be accessed by the object. Finally, you can finish off `wrapper()`, which is the inner function in `.__call__()`

Legal

Privacy Policy Terms and Conditions

Contact

Support FAQs

Follow

Bluesky Instagram Threads
Flashes for Bluesky Get it on the App Store