Replies: 1 comment
-
|
@dylanjha this definitely should be supported in workflow, and having "use workflow" and "use step" in published npm packages the way you described is an intentional design decision of workflow:
Will try to repro and make sure this actually works including in dev and prod builds. I'm not surprised if there is a bug in our current bundling for this |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
At Mux we're working on some video-related workflows, and with that is coming an SDK that exports functions that can be thought of as "workflows" for example:
Right now, if you call that function it will do a few things in sequence:
The psuedo code inside the
@mux/ai/workflowspackage is like this:I would LOVE to add
use workflow/use stepdirectives to the functions inside my SDKI think this makes a lot of sense (or someone tell me why this is a bad idea, I'd love to hear it):
await getSummaryAndTags()the way they are doing today and everything is the same⭐ and this would magically work ⭐ -- no extra configuration or setup required and now the workflows
The blocker
However, I'm testing this out with a locally built and locally linked package and it's not working. I can see in the
node_modules/that the directives are in the functions, but it ends up with an error:Questions
Can anyone figure out why this is not working?
I have a hunch that the WDK sort of "scans" for the
"use workflow"/"use step"directives in the dev server or at build time, and it's only scanning application-level code, and it's not looking at the code that gets imported from dependencies?Is something like that going on?
Is this considered a bug? What is the desired behavior?
Beta Was this translation helpful? Give feedback.
All reactions