dagster icon indicating copy to clipboard operation
dagster copied to clipboard

[ui] Wonky op graph displays when creating AssetsDefinitions from graphs.

Open OwenKephart opened this issue 2 years ago • 0 comments

Dagster version

0.15.8

What's the issue?

When you create an AssetsDefinition.from_graph, and view the op graph in Dagit, the connections are incorrectly displayed. Take this example repository:

Users/owen/.zshrc:ulimit:73: setrlimit failed: invalid argument                            │from dagster import run_status_sensor, DagsterRunStatus, bu
# Introduction
from dagster import AssetsDefinition, op, graph, asset, repository, define_asset_job

@op
def bar(inp):
    return inp

@op
def combine(x):
    return x

@graph
def ag(inp1):
    a = bar(inp1)
    b = bar(inp1)
    return combine([a, b])

ag_asset = AssetsDefinition.from_graph(ag)

@asset
def inp1():
    return 1


@repository
def repo():
    return [ag_asset, inp1, define_asset_job("all")]

When viewing the op graph, we'd expect both bar and bar_2 to be connected to the graph input inp1. However, we only see a single connection here: Screen Shot 2022-08-04 at 2 57 04 PM

The view when you click "Explode graphs" is even more inaccurate: Screen Shot 2022-08-04 at 2 58 32 PM

However, the underlying ops appear to be connected as expected, and if you execute this graph you'll see an accurate step dependency graph:

Screen Shot 2022-08-04 at 2 53 58 PM

What did you expect to happen?

No response

How to reproduce?

No response

Deployment type

No response

Deployment details

No response

Additional information

No response

Message from the maintainers

Impacted by this issue? Give it a 👍! We factor engagement into prioritization.

OwenKephart avatar Aug 04 '22 21:08 OwenKephart

I was able to repro this using your example, thanks for filing it! This is... quite busted, and it does seem like its running into limitations of our current rendering logic.

bengotow avatar Aug 29 '22 19:08 bengotow