Skip to main content

My personal toolbox

Project description

Rousquille's tools

My personal toolbox 🛠

Python 🐍

Measurement of the time used by a function

import time
from rousquille_tools.decorators import time_def


@time_def
def func1():
    time.sleep(5)

Result:

>>> func1()
[time_def] Function: func1 Time: 5.0s

Detect if python is executed in screen session

>>> from rousquille_tools.shell import is_in_screen_session
>>> print(is_in_screen_session())
False

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rousquille_tools-0.1.1.tar.gz (1.6 kB view hashes)

Uploaded Source

Built Distribution

rousquille_tools-0.1.1-py3-none-any.whl (2.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page