A little box of Python tools.
Drop-in debugger that allows you to write code while you debug. ✏️
Pencil it in! Write code by debugging your code. Lines of code are automatically inserted into your file. Clean them up later and voilà!
Super simple drop-in profiler. ⏱
Context manager that counts how much time is spent across all executions of the contained code block, storing it in seconds to the specified global variable. Prints out the value of that variable each time it is run.
with pencilcase.timer('weaving_baskets'): weave_baskets()
Alternatively, apply as a decorator to a function to count time spent in that function.
@pencilcase.timer('weaving_baskets') def weave_baskets(): ...
This is a totally unnecessary feature, but who has a pencil case without an eraser??
Pretty-print the given dict as JSON. 🎞
blob = ... pencilcase.microfilm(blob)
Context manager that catches all exceptions raised within, doing nothing but printing their lovely exception traces and then letting them be free. 🦋
with pencilcase.butterfly_net(): ...
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Hashes for pencilcase-0.0.2-py3-none-any.whl