osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Errorcode when running scripts in PyCharm


Den torsdag 2 maj 2019 kl. 13:31:29 UTC+2 skrev DL Neil:
> On 2/05/19 11:05 PM, Hampus Sj?din wrote:
> > Hey guys, so I've managed to ruin PyCharm for myself.. I just finished my first script in PyCharm and I tried renaming the file, so I closed PyCharm to reenter the file using the file manager.. And now it won't run when I try to.
> > 
> > This is what I get:
> > 
> > C:\Users\hampu\AppData\Local\Programs\Python\Python37-32\python.exe C:/Users/hampu/PycharmProjects/Laboration4/venv/Scripts
> > C:\Users\hampu\AppData\Local\Programs\Python\Python37-32\python.exe: can't find '__main__' module in 'C:/Users/hampu/PycharmProjects/Laboration4/venv/Scripts'
> > 
> > Process finished with exit code 1
> 
> 
> Is the Python code stored in a file called Scripts, called Scripts.py, 
> or perhaps a file inside the Scripts directory?
> 
> Perhaps the Windows FAQ might help? 
> https://docs.python.org/3.6/faq/windows.html
> 
> -- 
> Regards =dn

I have Python installed in: 
C:\Users\hampu\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Python 3.7

I have Python.exe installed in: C:\Users\hampu\PycharmProjects\Laboration4\venv\Scripts

I have Pycharm installed in: C:\ProgramData\Microsoft\Windows\Start Menu\Programs\JetBrains

And the current python file in: C:\Users\hampu\OneDrive\Skrivbord\lab4

I'm gonna take a wild guess and guess that something needs to be moved.