Skip to main content

dbx-tools-node-runtime

Run dbx-tools Python packages that contain generated PythonMonkey bindings in managed Python environments without a system Node.js or npm installation.

Install the runtime

%pip install dbx-tools-node-runtime

Most users don't import this package directly. Packages with generated dbx-tools Node bindings depend on it and initialize it when the first binding loads.

On first use, the runtime installs PythonMonkey 1.3.2 into the active Python environment. It uses an available npm executable. If npm is unavailable, it installs nodejs-wheel>=22.20,<23 and creates temporary Node and npm launchers from that wheel.

An existing npm executable or installed nodejs-wheel package is reused without an exact wheel-version check. The version range applies when this package installs the wheel.

Prewarm the environment

Run the project script to install or verify PythonMonkey before an application loads generated bindings:

dbx-tools-node-runtime

The command prints the resolved PythonMonkey package path. You can also run a CommonJS file through PythonMonkey:

dbx-tools-node-runtime ./hello.js

If the environment has no pip, bootstrap uses CPython's bundled ensurepip before it installs PythonMonkey.

Use generated bindings

Generated packages call the shared runtime through load_bundle(). You can also load a generated CommonJS bundle directly:

from dbx_tools.node_runtime.runtime import load_bundle

bundle = load_bundle("./generated-runtime.cjs", bundle_id="example")
module = bundle.module("config")

The runtime loads one process-wide compatibility registry and caches each bundle by ID. Generated wrappers convert supported records, arrays, dataclasses, promises, and JavaScript class instances between Python and JavaScript.

Use Databricks authentication

The package also installs the Databricks SDK for Python. In notebooks and Jobs, its shared runtime exposes the SDK's default WorkspaceClient authentication to generated Node auth bindings. Empty auth options use that runtime credential source automatically. Explicit profiles, hosts, and credentials continue through the normal Node auth providers.

In a Databricks notebook or Lakeflow Job, you can omit a profile when the default Python SDK credential source is correct for that runtime. Pass an explicit profile when you need to select a local Databricks CLI profile.

Configure installation locks

Node-wheel and PythonMonkey installation use separate check-lock-check sequences scoped to the active Python environment. Concurrent processes wait for the lock, recheck the environment, and skip a second installation when the first process completed it.

Lock files contain no runtime packages. Set DBX_TOOLS_NODE_RUNTIME_LOCK_DIRECTORY only when the default per-user cache directory is unavailable or isn't shared correctly by the processes that use the same Python environment.

Understand runtime limits

  • PythonMonkey must be version 1.3.2. Loading another PythonMonkey version in the process raises an error.
  • First use can install Python packages into the active environment. Prewarm images or managed services that must not install packages during startup.
  • The package provides compatibility only for Node built-ins imported by a generated dbx-tools bundle.
  • Bundles must use the same runtime ABI as the installed package.
  • The runtime doesn't provide a general Node package manager or a replacement for arbitrary Node applications.

Contribute runtime changes

build-runtime.ts bundles the bootstrap and shims into src/dbx_tools/node_runtime/runtime.js. It adds a generated-file header, avoids rewriting unchanged output, and leaves the committed artifact read-only. Edit build-runtime.ts or shims/, then build or verify the artifact:

bun packages/py/node-runtime/build-runtime.ts
bun packages/py/node-runtime/build-runtime.ts --check

In this repository, use the root tasks:

bun run python-node-runtime
bun run python-node-runtime:check
bun run python-node-runtime:watch

bun run sync --watch supervises python-node-runtime:watch with the shared Python binding, barrel, and Projen configuration watchers. Don't edit the generated runtime.js file directly.

Metadata

Release files for dbx-tools-node-runtime 0.9.132

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

Source distribution (sdist)

Source distribution for dbx-tools-node-runtime 0.9.132
File Size Uploaded
dbx_tools_node_runtime-0.9.132.tar.gz 157.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for dbx-tools-node-runtime 0.9.132
File Interpreter ABI Platform
dbx_tools_node_runtime-0.9.132-py3-none-any.whl Python 3 none any Details

Total release size: 317.0 kB

Release files / dbx_tools_node_runtime-0.9.132.tar.gz

Download URL dbx_tools_node_runtime-0.9.132.tar.gz
Size 157.3 kB
Tags Source
SHA-256 checksum
How to use checksums
40a2b9e1d64189c5f22686451f6e0ac9625ff7d7c31288eef55f5062ac80306c
BLAKE2b-256 checksum
How to use checksums
c21bf5047ce854bc4fc77292a9345efe4f9b1b0eb38fbd49e8f2466c48bf0ee1
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 Oct 15, 2026.

Transparency log

Release files / dbx_tools_node_runtime-0.9.132-py3-none-any.whl

Download URL dbx_tools_node_runtime-0.9.132-py3-none-any.whl
Size 159.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a8d28a93fbe4a432e39a09bba384a064147a0efb73f371d0a05436c590049b11
BLAKE2b-256 checksum
How to use checksums
d5f2a142defc5744017fe0f3e34362499ae8035e39eb32514c193f5768f725b5
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 Oct 15, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.9.132 This release

2 release files

0.9.99

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