Richard Fisher
09/16/2020, 8:14 AMexample_pipeline.py
file (I’m using import src.load_and_store
in the example_pipeline.py
file (which is in the same directory as src
). This works correctly when running the pipeline using the Python API (through execute_pipeline
in _`__name__ == "__main__"`_ in example_pipeline.py
) and when running it through dagit
with a workspace.yaml
file:
load_from:
- python_file: example_pipeline.py
However, when I try run dagster pipeline execute -f example_pipeline.py
(from the same directory) I receive the error ModuleNotFoundError: No module named 'src'
.
I’m sure this is a fairly basic import error, but could someone please provide a solution/best practice for this?alex
09/16/2020, 2:48 PMdagster pipeline execute -f example_pipeline.py -d ./
where -d
is setting the “working directory”dagit
and the dagster
cliRichard Fisher
09/16/2020, 2:58 PMdagster pipeline…
should be to use the current working directory as the working directory (without specifying the -d
flag), then I think that seems more intuitive (but I’m not sure what other implications that may have.daniel
09/17/2020, 12:44 AM