ComfyUI icon indicating copy to clipboard operation
ComfyUI copied to clipboard

python3: can't open file '/content/main.py

Open shivangvijay opened this issue 2 years ago • 3 comments

python3: can't open file '/content/main.py': [Errno 2] No such file or directory

I am getting this issue when trying to run it on Google colab. The install code given in this link:- [https://github.com/comfyanonymous/ComfyUI/blob/master/notebooks/comfyui_colab.ipynb]

I am exactly following this code but getting above issue.

shivangvijay avatar Dec 17 '23 08:12 shivangvijay

having the exact same problem 👎

phenomenal-hardy avatar Dec 19 '23 16:12 phenomenal-hardy

Did you %cd into another folder?

Try changing the code in your ComfyUI launch script to the path where your main.py folder is. In my case it's the below:

!python /content/drive/MyDrive/ComfyUI/main.py --dont-print-server

hydra213 avatar Dec 24 '23 02:12 hydra213

I had the issue. you can run !pwd and !ls to check your current folder and the files in your folder.

in my case, my folder is /content/ComfyUI. after I re-ran the Environment Setup code again, the issue magically resolved.

I guess it's probably some colab re-connect issue

justoy avatar Jul 12 '24 00:07 justoy