Skip to main content

Package that implements simple stopwatch class.

Project description

https://badge.fury.io/py/rhei.svg https://circleci.com/gh/dkrystki/rhei.svg?style=svg https://codecov.io/gh/dkrystki/rhei/branch/master/graph/badge.svg https://img.shields.io/badge/python-3.6-blue.svg https://img.shields.io/badge/python-3.7-blue.svg

Rhei is a Python 3 package that implements simple stopwatch functionality including pausing, resetting and reverse counting.

Installation

pip install rhei

In a nutshell

from time import sleep
from rhei import Stopwatch

stopwatch = Stopwatch()
stopwatch.start()
sleep(5)
stopwatch.value  # 5.0

stopwatch.pause()
sleep(2)
stopwatch.value  # 5.0

stopwatch.reset()
stopwatch.value  # 0.0

stopwatch.reset(10.0)
stopwatch.value  # 10.0
stopwatch.start(reversed=True)  # Start counting down

sleep(2)
stopwatch.value  # -2.0

Development

Rhei uses docker to create an isolated development environment so your system is not being polluted.

Requirements

In order to run local development you have to have Docker and Docker Compose installed.

Starting things up

docker-compose up -d

Logging into the docker terminal

./bin/host/terminal

The code is synchronised between a docker container and the host using volumes so any changes ( pipenv install etc ) will be affected on the host.

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

rhei-0.5.2.tar.gz (23.5 kB view hashes)

Uploaded Source

Built Distribution

rhei-0.5.2-py3-none-any.whl (7.7 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