Skip to main content

Social Card of Python Stopwatch 2

This is a fork from python-stopwatch, which adds static typing and a few other things.

PyPi Version PyPi Downloads Python Versions Repo Size MIT Licensed Stars Contributors

Tests Coverage Status

  • This package requires python 3.10 or higher.

Step 1. Install the library:

poetry add python-stopwatch2

Other platform? ➜ https://stopwatch2.vercel.app/guide/getting-started.html

Step 2. Import the Stopwatch class:

from stopwatch import Stopwatch

Step 3. Create a new Stopwatch object:

sw = Stopwatch()

Step 4. Place your code here:

from time import sleep
sleep(2)

Step 5. Stop the stopwatch:

sw.stop()

Step 6. Get the elapsed time:

print(f'Time elapsed: {sw.elapsed}')  # Time elapsed: 2.0031827000002522
# or
print(f'Time elapsed: {sw}')  # Time elapsed: 2.00s

You'll find installation instructions and full documentation on https://stopwatch2.vercel.app.

Run the tests with:

poetry run pytest --cov=stopwatch

Please see CHANGELOG for detailed changes for each release.

Please see CONTRIBUTING for details.

  • MIT

  • Copyright (c) 2021-2022 Jonghwan Hyeon, 2022-present Rafael

Release files for python-stopwatch2 2.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for python-stopwatch2 2.0.0
File Size Uploaded
python_stopwatch2-2.0.0.tar.gz 6.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for python-stopwatch2 2.0.0
File Interpreter ABI Platform
python_stopwatch2-2.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 15.8 kB

Release files / python_stopwatch2-2.0.0.tar.gz

Download URL python_stopwatch2-2.0.0.tar.gz
Size 6.9 kB
Tags Source
SHA-256 checksum
How to use checksums
4c2bb62d1374de97429c4f5ba1188fea10b2a7c34af89f173c28ae38d5206b90
BLAKE2b-256 checksum
How to use checksums
51cd29c1f059e1f0e18280f1439698ce39f91d088b90c19d38083efbd27552e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 2, 2026.

Transparency log

Release files / python_stopwatch2-2.0.0-py3-none-any.whl

Download URL python_stopwatch2-2.0.0-py3-none-any.whl
Size 8.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
42b4351addaffaa3a2b347b5f2ca2a53d80264c2a76ec1631dc60131b92ab66c
BLAKE2b-256 checksum
How to use checksums
46e13d129cf109abe17e0de6a989a92c7683c1f743bd24f7616316f81bbc7588
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 2, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

2.0.0 This release

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.11

2 release files

1.0.9

2 release files

1.0.8

2 release files

1.0.7

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page