How to fix this error?

How to fix this error

/nix/store/xf54733x4chbawkh1qvy9i1i4mlscy1c-python3-3.10.11/
bin/python3: can't open file '/home/runner/Python/main.py':
[Errno 2] No such file or directory

image

https://replit.com/@Pulastya/Python#Assignment1_Pulastya_Bhagwat.py

@Pulastya I forked your Repl and it worked fine for me. Were you able to resolve the issue? If not, can you try forking it and see if that helps?
https://replit.com/@Pulastya/Python#Assignment1_Pulastya_Bhagwat.py

2 Likes

Hi @Pulastya , welcome to the forums!
This is because your main.py may have been moved or deleted, but the config in the .replit file may not be updated.
To fix this, try the following steps:

  1. Click the 3 dots at the top of your Files sidebar and click on Show Hidden Files
  2. Go to your .replit file.
  3. Change the entrypoint variable to the file name of whichever file you want to run.
  4. Re-run the repl.

Hope this helps!

2 Likes