kurtosis-tech.github.io


Project maintained by kurtosis-tech Hosted on GitHub Pages — Theme by mattgraham

Kurtosis Sandbox

Often, Kurtosis is used for its testing ability: run a testsuite, where each test spins up a test network that the test logic runs against. However, it can sometimes be valuable to spin up a test network for freeform manipulation without any test logic. This is the Kurtosis sandbox: a testnet that can be freeform manipulated with a Javascript REPL with the same tools for interacting with the Kurtosis engine.

To start a Kurtosis sandbox, install the Kurtosis CLI and run:

kurtosis sandbox

The Javascript REPL that starts will 1) have await available and 2) have a networkCtx variable instance of the NetworkContext object from the documentation.

E.g. starting an Ethereum network using the Ethereum module:

Starting an Ethereum network

The commands from above, for copy-pasting:

kurtosis sandbox
loadModuleResult = await networkCtx.loadModule("my-module", "kurtosistech/ethereum-kurtosis-module", "{}")
moduleCtx = loadModuleResult.value
executeResult = await moduleCtx.execute("{}")
executeResultObj = JSON.parse(executeResult.value)
console.log(executeResultObj)

Back to index