diff --git a/packages/squiggle-lang/src/rescript/ReducerInterface/ReducerInterface_ExternalLibrary.res b/packages/squiggle-lang/src/rescript/ReducerInterface/ReducerInterface_ExternalLibrary.res index cb296904..6976471a 100644 --- a/packages/squiggle-lang/src/rescript/ReducerInterface/ReducerInterface_ExternalLibrary.res +++ b/packages/squiggle-lang/src/rescript/ReducerInterface/ReducerInterface_ExternalLibrary.res @@ -13,7 +13,7 @@ let dispatch = ( // () => ReducerInterface_GenericDistribution.dispatch(call, environment), () => ReducerInterface_Date.dispatch(call, environment), () => ReducerInterface_Duration.dispatch(call, environment), - () => ReducerInterface_Number.dispatch(call, environment), + // () => ReducerInterface_Number.dispatch(call, environment), // () => FunctionRegistry_Library.dispatch(call, environment, reducer), ])->E.O2.defaultFn(() => chain(call, environment, reducer)) } diff --git a/packages/squiggle-lang/src/rescript/ReducerProject/ReducerProject.res b/packages/squiggle-lang/src/rescript/ReducerProject/ReducerProject.res index fe7718d6..0730dee0 100644 --- a/packages/squiggle-lang/src/rescript/ReducerProject/ReducerProject.res +++ b/packages/squiggle-lang/src/rescript/ReducerProject/ReducerProject.res @@ -187,8 +187,12 @@ let linkDependencies = (project: t, sourceId: string): ProjectItem.T.continuatio let doLinkAndRun = (project: t, sourceId: string): unit => { let context = Reducer_Context.createContext(project->getStdLib, project->getEnvironment) // FIXME: fill context with dependencies - // let continuation = linkDependencies(project, sourceId) - let newItem = project->getItem(sourceId)->ProjectItem.run(context) + let continuation = linkDependencies(project, sourceId) + let contextWithContinuation = { + ...context, + bindings: continuation->Reducer_Bindings.extend, + } + let newItem = project->getItem(sourceId)->ProjectItem.run(contextWithContinuation) // Js.log("after run " ++ newItem.continuation->Reducer_Bindings.toString) project->setItem(sourceId, newItem) }