MCPcopy Create free account
hub / github.com/Effect-TS/effect / runPromise

Function runPromise

packages/effect/src/ManagedRuntime.ts:377–383  ·  view source on GitHub ↗
(effect: Effect.Effect<A, E, R>, options?: {
      readonly signal?: AbortSignal | undefined
    })

Source from the content-addressed store, hash-verified

375 Effect.runPromiseExitWith(self.cachedContext)(effect, mergeRunOptions(options))
376 },
377 runPromise<A, E>(effect: Effect.Effect<A, E, R>, options?: {
378 readonly signal?: AbortSignal | undefined
379 }): Promise<A> {
380 return self.cachedContext === undefined ?
381 Effect.runPromise(provide(self, effect), mergeRunOptions(options)) :
382 Effect.runPromiseWith(self.cachedContext)(effect, mergeRunOptions(options))
383 }
384 }
385 return self
386}

Callers 6

closeFunction · 0.70
closeAndReportErrorFunction · 0.70
nextFunction · 0.70
runTestFunction · 0.50
closeScopeFunction · 0.50
layerFunction · 0.50

Calls 2

provideFunction · 0.85
mergeRunOptionsFunction · 0.85

Tested by

no test coverage detected