Last answered:

02 Apr 2020

Posted on:

01 Apr 2020

0

Python spyder reset

I was using python(x,y), which came with Spyder. Yesterday, Spyder crashed I can't figure it out how to fix it. I uninstalled python(x,y) and reinstalled, still the same problem. If I try to open Spyder I get this message:
Spyder crashed during last session

If Spyder does not start at all and before submitting a bug report, please try to reset setting to defaults by running Spyder with the command line option '--reset:

python spyder --reset
Of course, I tried to do the above, but it doesn't seem like I have Spyder in my path. When I try to put
python spyder --reset
in my command prompt window, I get this error message:
python: can't open file 'spyder': [Errno 2] No such file or directory
I made some attempts of trying to add spyder to path, but they all failed. How should I go about adding Spyder to path? I am using Windows 10 on 64 bit system. My Spyder Crash report looks like this:
Traceback (most recent call last):
File "C:\Users\DELL\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 3718, in main
mainwindow = run_spyder(app, options, args)
File "C:\Users\DELL\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 3559, in run_spyder
main.setup()
File "C:\Users\DELL\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 955, in setup
self.editor = Editor(self)
File "C:\Users\DELL\anaconda3\lib\site-packages\spyder\plugins\editor\plugin.py", line 178, in __init__
self.autosave.try_recover_from_autosave()
File "C:\Users\DELL\anaconda3\lib\site-packages\spyder\plugins\editor\utils\autosave.py", line 176, in try_recover_from_autosave
files_to_recover, pidfiles = self.get_files_to_recover()
File "C:\Users\DELL\anaconda3\lib\site-packages\spyder\plugins\editor\utils\autosave.py", line 149, in get_files_to_recover
txt_as_dict = ast.literal_eval(txt)
File "C:\Users\DELL\anaconda3\lib\ast.py", line 46, in literal_eval
node_or_string = parse(node_or_string, mode='eval')
File "C:\Users\DELL\anaconda3\lib\ast.py", line 35, in parse
return compile(source, filename, mode, PyCF_ONLY_AST)
File "<unknown>", line 0

^
SyntaxError: unexpected EOF while parsing

I'm a beginner in this field.
I am wondering if anyone else ran into a similar problem, or can just give suggestions on what to do, and how to do this "reset" thing, or maybe other advice.
Thank You in Advance
1 answers ( 0 marked as helpful)
Instructor
Posted on:

02 Apr 2020

0
Hi Hoa,  I am not a python(x, y) user myself, but what if you try the following: for windows 10 users, you all need to type 'spyder' in 'Cortana' then you can see in apps category something like 'reset spyder setting' just click on that and some black screen will open and your problem will be solved. now you can open your spyder. If I could make another suggestion, it would honestly be to install anaconda (just make sure it's the 64 bit version) and use Spyder from there. I haven't encountered any dependency issues with it so far.   Best,  Eli

Submit an answer