@tlockney/cdp-kernel 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,6 +18,7 @@
18
18
  import { formatWithOptions, inspect } from "node:util";
19
19
  import { createJupyter } from "./display.mjs";
20
20
  import { createHandler } from "./evaluator.mjs";
21
+ import { describeValue, inspectPath, resolvePath } from "./introspect.mjs";
21
22
 
22
23
  const BUILTIN = /^(?:node|cloudflare|workerd):/;
23
24
 
@@ -96,6 +97,10 @@ function install(env) {
96
97
  import: cellImport,
97
98
  meta: { ...meta, resolve: (specifier) => new URL(specifier, meta.url).href },
98
99
  requireFor,
100
+ // inspect_request (#10): by descriptor, so nothing runs.
101
+ describeForInspect: (value, detail) => describeValue(value, { inspect: (v) => inspect(v, { colors: false, depth: 2 }), detail }),
102
+ inspectPath: (path, detail) => inspectPath(path, { inspect: (v) => inspect(v, { colors: false, depth: 2 }), detail }),
103
+ resolvePath,
99
104
  barrier: () => 0,
100
105
  broadcastResult: jupyter.broadcastResult,
101
106
  async commDispatch(msgType, content, metadata, buffers64) {