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.133

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.133
File Size Uploaded
dbx_tools_node_runtime-0.9.133.tar.gz 157.3 kB Details

Built distribution (wheel)

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

Total release size: 317.0 kB

Release files / dbx_tools_node_runtime-0.9.133.tar.gz

Download URL dbx_tools_node_runtime-0.9.133.tar.gz
Size 157.3 kB
Tags Source
SHA-256 checksum
How to use checksums
c682c38dd061742b926cb4b64d379a377c6d8bcdd27442e380c360784a6185fe
BLAKE2b-256 checksum
How to use checksums
b5fdabf55bc775ad7c67a5b20651b4fe3da7dfc8dded58836018bef6eb0cc26c
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.133-py3-none-any.whl

Download URL dbx_tools_node_runtime-0.9.133-py3-none-any.whl
Size 159.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
beba3165790f5027929be7c15318d3b1fbb0e15c476f826708ed1efdf4c550d0
BLAKE2b-256 checksum
How to use checksums
b1336903a128b230bfbd44fb008c6ff0fb20d5d85705adab02d76242f1c64958
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.133 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