skillfed

DafnyRuntimePython

Dafny runtime for Python

dafnyruntimepython v4.11.0 524.1K downloads/30d#6,191 on PyPI3,498
Permissive license Active released

What it is and what it does

DafnyRuntimePython is a support library that enables Python code compiled from Dafny programs to execute correctly. Dafny is a verification-ready programming language that lets you write code alongside formal specifications, then compiles to multiple targets including Python. This package provides the runtime layer—data structures, utility functions, and runtime support—that the compiled Python code depends on.

You would install this package if you are using Dafny to write formally verified programs and have chosen Python as your compilation target. The package itself is not a language or IDE; it is a dependency for the output of the Dafny compiler. It has no external runtime dependencies, installs cleanly, and is actively maintained by the Dafny project team.

Use it for:

  • Running formally verified algorithms compiled from Dafny to Python for production or research use.
  • Integrating Dafny-verified components into larger Python applications that require correctness guarantees.
  • Executing educational examples and tutorials that demonstrate Dafny verification in a Python environment.
  • Deploying verified cryptographic or mathematical routines written in Dafny as Python libraries.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides the Python runtime library needed to execute Dafny-compiled Python code, enabling verified programs written in Dafny to run on Python.

Yes, if you are compiling Dafny programs to Python. This is a lightweight, actively maintained runtime with no external dependencies, permissive licensing, and zero known vulnerabilities. Install it as a prerequisite for any Dafny-to-Python workflow. If you are not using Dafny, there is no reason to install it.

Install

dafnyruntimepython on PyPI

pip

pip install dafnyruntimepython

uv

uv add dafnyruntimepython

poetry

poetry add dafnyruntimepython

Installing DafnyRuntimePython

Before you install

Low friction installation with no runtime dependencies. The package is actively maintained, with recent releases and a healthy repository (3498 stars, last commit 2026-08-09). Python 3.8+ is required.

License in practice

Licensed under MIT (permissive), allowing free use, modification, and distribution with minimal restrictions.

Quickstart

pip install dafnyruntimepython

# Use the installed runtime as a dependency for Dafny-compiled Python code
import dafnyruntimepython

Requires Python 3.8 or later. This package is a runtime support library for code compiled by the Dafny compiler to Python.

Verify before relying

  • Whether this package is automatically installed as a dependency when using the main Dafny compiler, or must be installed separately.
  • Compatibility matrix between Dafny compiler versions and this runtime package version.
  • Specific runtime features and APIs provided by this package for compiled Dafny code.

Package facts

License not declared (permissive)
Python support supports the current Python release (>=3.8)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance actively maintained — 354 days since the last release
Last repo commit
First released
Downloads 524,125/month — #6,191 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: dafnyruntimepython-4.11.0-py3-none-any.whl

License :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3

Tags

dafny python runtimeverified code execution pythondafny compilation targetformal verification pythondafny runtime library
formal-verificationdafny-ecosystem

More Quality Assurance packages