Hi all, has anyone else run into issue when trying...
# ask-the-community
e
Hi all, has anyone else run into issue when trying to render workflows that go past a depth of 5 in the UI? The UI can’t seem to render anything past the 5th nested node. Attached is a screenshot of what I’m seeing and the code for how to reproduce it. I would expect to see
wf_6
and
wf_7
also rendered in the UI bug I don’t see in the “Nodes” tab nor the “Timeline” tab. The “Graph” tab only shows a single node which is another problem but I believe people are aware and working on that issue.
Copy code
@dynamic
def wf_1(n: int) -> int:
    return wf_2(n=n+1)

@dynamic
def wf_2(n: int) -> int:
    return wf_3(n=n+1)

@dynamic
def wf_3(n: int) -> int:
    return wf_4(n=n+1)

@dynamic
def wf_4(n: int) -> int:
    return wf_5(n=n+1)

@dynamic
def wf_5(n: int) -> int:
    return wf_6(n=n+1)

@dynamic
def wf_6(n: int) -> int:
    return wf_7(n=n+1)

@dynamic
def wf_7(n: int) -> int:
    return n+1

@workflow
def run_wf(n: int) -> int:
    return wf_1(n=n)
n
@Jason Porter are you familiar with this UI bug? basically dynamic workflows can go 5 levels deep
j
Hey @Eric Song - sorry about that; this is definitely not supposed to happen. Could I ask what version of UI you're running on?
Asking because
1.4
release included a fix that should have resolved this issue - definitely possible its still broken but letting us know which version of
flyteconsole
is running will help us figure this out 👍
e
I’m on 1.4.1! Admin version is 1.1.70 if that matters.
j
Okay strange. I'll cut an issue and we'll investigate this and keep you updated 👍
e
thanks Jason!
j
Hey @Eric Song - I think I know what happened; we had a known issue with 1.4 that was fixed in the latest flyte release. Can you try pulling that down? https://github.com/flyteorg/flyteconsole/releases/tag/v1.4.3
e
sounds good. I’ll try that out.
That fixed the issue. Thanks @Jason Porter! On a slightly related but different issue, we found another niche case where the UI breaks when rendering nodes. The reproduction case seems to if
@workflow
is called recursively like in the following code.
Copy code
@dynamic
def wf_recurse(n: int) -> int:
    print(f'Calling wf_recurse with {n=}')
    return wf_recurse_conditional(n=n-1)

@dynamic
def return_n(n: int) -> int:
    return n

@workflow
def wf_recurse_conditional(n: int) -> int:
    return (
        conditional("cond")
        .if_(n == 0)
        .then(return_n(n=n))
        .else_()
        .then(
            wf_recurse(
                n=n
            )
        )
     )

@workflow
def run_wf(n: int) -> int:
    return wf_recurse(n=n
I attached a screen recording of the UI error.
It's fine if we convert the
@workflow
to be a
@dynamic
function but that has a different issue where
.with_overrides(name=??)
doesn't work but I believe that's being tracked in a separate issue.
j
Okay great. And yeah, that second issue will fix the name override 👍
Or, wait, rather it will be fixed by this issue (dupe) https://github.com/flyteorg/flyte/issues/3470
127 Views