Hello! I'm having a super simple issue that I hope...
# ask-community
j
Hello! I'm having a super simple issue that I hope someone can assist with. Using dagster version
1.3.10
For some reason when I am running
dagit
(and
dagster-daemon
), the env variable
DAGSTER_HOME
is not getting picked up. This is how I'm calling it:
Copy code
$ DAGSTER_HOME=~/dagster/ dagit -h 0.0.0.0 -p 3000
Usage: dagit [OPTIONS]
Try 'dagit --help' for help.

Error: No arguments given and no [tool.dagster] block in pyproject.tonml found.
The above error seems to indicate that some arguments were missing (if i want to explicitly point to a workspace file, which i dont). My other suspicion is that the
DAGSTER_HOME
variable is not being picked up When I run the above command within the
DAGSTER_HOME
path, it correctly picks up the workspace and dagster.yaml files in
DAGSTER_HOME
but the logs seem to still indicate that it is not picking up
DAGSTER_HOME
since I see the following:
Copy code
dagit - INFO - To persist information across sessions, set the environment variable DAGSTER_HOME to a directory to use
Thoughts? I've tried a bunch of different combinations to get this working but nothing is working 😞 . Any help is appreciated
l
Do you know that you can create a ".env" file in which you can define your variable ? This file is automatically detected by dagit if it is located in your dagster project.
t
Hmm, it could be something else, but the immediate thing is that the bash snippet you sent has a typo and says DAGTER_HOME
j
I'd like my
dagit
and
dagster-daemon
instances to run multiple different code locations -- thus a
.env
file doesnt work for my use case
t
Another one could be your toml file. If the above recc doesn't fix it, what does your toml file look like?
j
Thanks @Tim Castillo -- that was indeed a typo, I fixed the above. Unfortunately still having the same issues
Aren't toml files meant to be used within a project? In my case id like the dagit/daemon to run against multiple different code locations and projects I think that error message is just complaining that it couldnt find DAGSTER_HOME so it expects certain arguments to be set in order to point to an appropriate python file, module or workspace file. When I
cd
into the dagster home directory it works fine
t
I'd like my
dagit
and
dagster-daemon
instances to run multiple different code locations -- thus a
.env
file doesnt work for my use case
Do you mean, for example, that you want 2 code locations (foo and bar) and
dagit
would be accessing
foo
and the daemon is running
bar
?
180 Views