Skip to main content

mitchallen-roll

PyPI version Python versions License Downloads CI codecov

A simple dice rolling random number generator for Python.

Installation

pip install mitchallen-roll

Or with uv:

uv add mitchallen-roll

Usage

from mitchallen.roll import roll, d6, d20

# Roll a standard 6-sided die
result = roll()  # Returns 1-6

# Roll a custom die
result = roll(20)  # Returns 1-20

# Convenience functions
result = d6()   # Roll a 6-sided die
result = d20()  # Roll a 20-sided die

API Reference

roll(sides=6) -> int

Roll a die with the specified number of sides.

Parameters:

  • sides (int): Number of sides on the die (default: 6, minimum: 1)

Returns:

  • int: A random integer from 1 to sides (inclusive)

Raises:

  • ValueError: If sides is less than 1

d6() -> int

Convenience function to roll a 6-sided die.

Returns:

  • int: A random integer from 1 to 6

d20() -> int

Convenience function to roll a 20-sided die.

Returns:

  • int: A random integer from 1 to 20

Development

See the main repository README for development setup instructions.

License

MIT License - see LICENSE file for details

Metadata

Release files for mitchallen-roll 1.0.14

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

Source distribution (sdist)

Source distribution for mitchallen-roll 1.0.14
File Size Uploaded Provenance
mitchallen_roll-1.0.14.tar.gz 31.5 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for mitchallen-roll 1.0.14
File Interpreter ABI Platform
mitchallen_roll-1.0.14-py3-none-any.whl Python 3 none any Details

Total release size: 35.0 kB

Release files / mitchallen_roll-1.0.14.tar.gz

Download URL mitchallen_roll-1.0.14.tar.gz
Size 31.5 kB
Tags Source
SHA-256 checksum
How to use checksums
90536d80cde2a6753ee64a0f9ac89a25dc7d10d5bb4bdd80799275baf42fb2af
BLAKE2b-256 checksum
How to use checksums
446f780184f43bff40313fa02bee24ccd9890af7995414edfc409cc0946cd2c4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Nov 19, 2025.

Transparency log

Release files / mitchallen_roll-1.0.14-py3-none-any.whl

Download URL mitchallen_roll-1.0.14-py3-none-any.whl
Size 3.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5b397d1a40708463c9ec16a4bf8aa9348de97b874fd034dae465d04f18f09672
BLAKE2b-256 checksum
How to use checksums
38333ff839d6bae0e55fe55f3f455d54c58f4911cecd0787908560159016e468
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

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 Nov 19, 2025.

Transparency log

Security for mitchallen-roll 1.0.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.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for mitchallen_roll-1.0.14.tar.gz

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 Nov 19, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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