Hi all. I just started using prefect and am trying...
# prefect-cloud
c
Hi all. I just started using prefect and am trying to deploy my first flow. I can successfully deploy a python file, but the error I get is: Failed to start process for flow run 'd7c862c3-f1f2-4cbd-b00d-b1248a9add0f'. FileNotFoundError: [Errno 2] No such file or directory: '/Users/caseym/PycharmProjects/virtual' Is this because I deployed while in a virtual environment? I'm using PyCharm. Any tips?
🐞 2
1
i
Hi Casey! Deploying from a virtual environment is not only well supported, but highly recommended. Are you deploying with
prefect deploy
CLI by any chance? By default, this tries to recursively look for deployments in the current dir and maybe there was a false match. Do you happen to have this
virtual
folder in your
deployment.yaml
or
prefect.yaml
?
c
Hi Islam! I'm not sure how to add it to prefect.yaml. I did notice that my virtual environment is here: $ which python /Users/caseym/PycharmProjects/virtual environments/prefect-test/bin/python So it's almost like prefect is not recognizing the space in 'virtual environments'?
The way I am deploying is to set the deployment name like: if name == "__main__": get_repo_info.serve(name="my-second-deployment") Then run the job with: prefect deployment run 'get-repo-info/my-second-deployment'
i
I see, thanks!
c
Oh and of course run the file first to create the deployment. Like: python repo_info.py
👍 1
i
I'll try to reproduce it on my end and file a Github issue if it's indeed a space issue 🙂👍
c
Ok , I was able to create another virtual environment without a space in the name. That fixed everything and it's working correctly now. Thanks!
1
i
Thank YOU!
I've managed to reproduce it, and filed a bug to track this issue: https://github.com/PrefectHQ/prefect/issues/10820
🙌 3
Thanks again Casey!
163 Views