Question about getting dagstermill up and running
# announcements
d
Question about getting dagstermill up and running
I been trying to get a hello world notebook going with dagstermill. I’ve looked through the examples that use notebooks and have read the outdated but more detailed documentation on dagstermill (https://dagster.readthedocs.io/en/0.3.3.post0/intro_tutorial/dagstermill.html) but still can’t get my notebook pipeline going. This runs successfully (though it also runs with any notebook_path, even invalid ones)
Copy code
def hello_world():
  return dagstermill.define_dagstermill_solid(
    name="hello_world",
    notebook_path="hello_world.ipynb",
    input_defs=[InputDefinition(name="a"), InputDefinition(name="b")]
  )

@pipeline
def demo_notebook_pipeline():
  hello_world()

if __name__ == "__main__":
  result = execute_pipeline(demo_notebook_pipeline)
  assert result.success
And I included the pipeline in the
pipeline_defs
for my
RepositoryDefinition
but when I run dagit it does not appear as a valid pipeline
m
hi @dhume
👋 1
i think the issue here is that calling
hello_world
doesn't actually execute the solid --
hello_world
is a solid factory, i.e., it returns a solid
so calling
hello_world()
inside the
@pipeline
decorator doesn't do anything -- you would need to do
hello_world()()
alternatively, you could have
hello_world = define_dagstermill_solid(...)
does that make sense?
d
Ah. I missed that. Thanks
m
we have an open issue to write better error messages / warnings for this