Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why the workflow end step cannot be the end of split node #2198

Open
EveT0n opened this issue Jan 7, 2025 · 0 comments
Open

Why the workflow end step cannot be the end of split node #2198

EveT0n opened this issue Jan 7, 2025 · 0 comments

Comments

@EveT0n
Copy link

EveT0n commented Jan 7, 2025

I have a workflow with two steps before the end step

from metaflow import FlowSpec, step

class LinearFlow(FlowSpec):

    @step
    def start(self):
        self.my_var = 'hello world'
        self.next(self.a, self.b)

    @step
    def a(self):
        print('the data artifact is: %s' % self.my_var)
        self.next(self.end)

    @step
    def b(self):
        print('test b')
        self.next(self.end)

    @step
    def end(self):
        print('the data artifact is still: %s' % self.my_var)

if __name__ == '__main__':
    LinearFlow()

When I use it to create a workflow, the following error occurs

Validating your flow...
    Validity checker found an issue:
    Step end reached before a split started at step(s) a, b were joined. Add a join step before end.

I think the end step should be able to support multiple upstream steps. I read the documentation of metaflow and did not find an explanation of this design. My workflow runs on argo-workflow. Are there any other considerations for this limitation?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant