dvm-run
dvm.run's Python SDK.
pip install dvm-run
dvm-run login
dvm-run login opens dvm.run in your browser, where you approve an API key
for this machine; it saves the key in ~/.config/dvm/credentials.json, where
the SDK finds it. Over SSH, open the link it prints wherever you like. Where
no one is there to approve one, such as CI, make a key on
dvm.run's API keys page and set
DVM_API_KEY.
A sandbox is a VM made from an image: your agent sends it commands and files until it stops it. Everything it ran is its execution, which replays, the same, once it ends.
from dvm import Sandbox, Execution
with Sandbox.create("python:3.12", seed=7) as sbx:
sbx.files.write("/app/main.py", "print(1 + 1)\n")
r = sbx.commands.run("python main.py", cwd="/app", timeout=60)
print(r.stdout, r.exit_code)
server = sbx.commands.run(["python", "-m", "http.server"], background=True)
server.kill()
server.wait()
verdict = Execution.get(sbx.id).replay().wait()
assert verdict.same
It takes dvm.run's address as api_url=, else DVM_API_URL, and its key
as api_key=, else DVM_API_KEY, else the one dvm-run login saved for
that address. AsyncSandbox and AsyncExecution are the same API for
asyncio.
- A string runs in the sandbox's shell (
/bin/bash -lc, or/bin/sh -cin an image without bash); a list runs as it is. - A command's exit code is never an exception. A sandbox that ended raises
SandboxEndedError(SandboxFailedError, with dvm's reason, if it failed) on the next call. timeout=kills the command once it passes; its result says so, with code 137 and signal 9.
Metadata
Release files for dvm-run 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| dvm_run-0.1.0.tar.gz | 21.4 kB | With provenance | Details for dvm_run-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| dvm_run-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for dvm_run-0.1.0-py3-none-any.whl |
Total release size: 45.3 kB
Release files / dvm_run-0.1.0.tar.gz
| Download URL | dvm_run-0.1.0.tar.gz |
|---|---|
| Size | 21.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a13417db433fd5f0535d64ca260bfecab6ba27ffcd5a137de41c37e1f5e2e16b
|
|
BLAKE2b-256 checksum How to use checksums |
feadde444aaefde185a70c6dc56969f81580447ccdacb2112ece434bb39726c3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 7, 2026.
Transparency logRelease files / dvm_run-0.1.0-py3-none-any.whl
| Download URL | dvm_run-0.1.0-py3-none-any.whl |
|---|---|
| Size | 23.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8ab1e1b02bc2f9c1a1a42577e3195c3403587ef30c13adcd06eb9b786f6189e8
|
|
BLAKE2b-256 checksum How to use checksums |
6e3a8f577e24b040e0c592234803afdfeeacc60b4ffbf6d033d3ca8c9341d05e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 7, 2026.
Transparency logSecurity for dvm-run 0.1.0
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
Both files in this release have been uploaded with provenance metadata.
Attestation for dvm_run-0.1.0.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 7, 2026.
Transparency logA 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.