MCPcopy Create free account
hub / github.com/hashintel/hash / waitOnResource

Function waitOnResource

libs/@local/hash-backend-utils/src/environment.ts:27–39  ·  view source on GitHub ↗
(
  resource: string,
  logger?: Pick<Console, "debug">,
)

Source from the content-addressed store, hash-verified

25};
26
27export const waitOnResource = async (
28 resource: string,
29 logger?: Pick<Console, "debug">,
30) => {
31 logger?.debug(`Waiting on ${resource}...`);
32
33 await waitOn({
34 resources: [resource],
35 timeout: 30000,
36 });
37
38 logger?.debug(`${resource} is ready`);
39};
40
41/**
42 * @todo reimplement a 'changes to entities' publisher

Callers 1

mainFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected