I was forced into some software updates on my laptop (ThinkPad) and after the update when I tried to open Spyder (via Anaconda) and it won't open. I don't have any experience in errors like this or fixing this stuff (and I am aware this may be something that is super simple). Please help. This is the application launch error I am getting:
Traceback (most recent call last):
File "C:\Users\cyrra\anaconda3\Scripts\spyder-script.py", line 10, in
sys.exit(main())
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\app\start.py", line 205, in main
mainwindow.main()
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 3651, in main
mainwindow = run_spyder(app, options, args)
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 3526, in run_spyder
main.setup()
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 871, in setup
self.help = Help(self, css_path=css_path)
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\plugins\help\plugin.py", line 68, in __init__
color_scheme = self.get_color_scheme()
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\api\plugins.py", line 347, in get_color_scheme
return super(BasePluginWidget, self)._get_color_scheme()
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\plugins\base.py", line 446, in _get_color_scheme
return get_color_scheme(CONF.get('appearance', 'selected'))
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\config\gui.py", line 114, in get_color_scheme
color_scheme[key] = CONF.get("appearance", "%s/%s" % (name, key))
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\config\manager.py", line 228, in get
return config.get(section=section, option=option, default=default)
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\config\user.py", line 976, in get
return config.get(section=section, option=option, default=default)
File "C:\Users\cyrra\anaconda3\lib\site-packages\spyder\config\user.py", line 513, in get
raise cp.NoOptionError(option, section)
configparser.NoOptionError: No option 'custom-1/background' in section: 'appearance'
Thanks,
Rachel
Did you try to run spyder on the terminal?
It should be prebuild in Anaconda.
Your Spyder config file should contain but is missing 'custom-1/background' in section: 'appearance'. If you have no experience, the easiest thing for you to do is uninstall and install Spyder (via Anaconda). Your other option is to find the config file called in line 513 of C:\Users\cyrra\anaconda3\lib\site-packages\spyder\config\user.py". Then open the config file (if it exists) and correct it. If the file is not found, search for that config file and place it in the expected location.
Related
I have upgraded to ubuntu 20.04 and have fvwm, I had the fvwm-menu-desktop that created the menus for me but lately it started behaving totally bad:
(I use the command
fvwm-menu-desktop --desktop gnome --type gtk --theme masalla --title FvwmKde to generate my menu
)
it generates twice the menu
it hangs half way (twice) just before creating the Android Studio menu item, (is that a hint?)
when I try to check the desktop menus available, it throws a python exception error:
$ fvwm-menu-desktop --get-menus desktop
Traceback (most recent call last):
File "/usr/bin/fvwm-menu-desktop", line 821, in <module>
main()
File "/usr/bin/fvwm-menu-desktop", line 388, in main
parsemenus(menulist, desktop)
File "/usr/bin/fvwm-menu-desktop", line 677, in parsemenus
parsemenu(xdg.Menu.parse(menu), name, title)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 1137, in parse
return XMLMenuBuilder(debug).parse(filename)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 641, in parse
menu = self.parse_menu(tree.getroot(), filename)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 659, in parse_menu
self.parse_node(node, filename, menu)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 668, in parse_node
menu = self.parse_menu(child, filename)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 659, in parse_menu
self.parse_node(node, filename, menu)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 668, in parse_node
menu = self.parse_menu(child, filename)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 659, in parse_menu
self.parse_node(node, filename, menu)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 691, in parse_node
parent.Rules.append(self.parse_rule(child))
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 768, in parse_rule
return Rule(type, tree)
File "/usr/lib/python3/dist-packages/xdg/Menu.py", line 421, in __init__
self.code = compile(self.expression, '<compiled-menu-rule>', 'eval')
ValueError: Name node can't be used with 'True' constant
I have
Ubuntu 20.04
fvwm 2.6.8 compiled on Jan 14 2019 at 19:59:25 with support for: ReadLine, RPlay, Stroke, XPM, SVG, Shape, XShm, SM, Bidi text, Xinerama, XRender, XCursor, XFT, NLS
mau ~ python --version
Python 2.7.18
mau ~ python3 --version
Python 3.8.5
Thanks
I know this a late answer, but I just ran into the same problem.
It is due to a change in Python 3.8.4 causing a problem in pyxdg. Here's the bug report:
https://gitlab.freedesktop.org/xdg/pyxdg/-/issues/20
And here's the patch to Menu.py:
https://gitlab.freedesktop.org/xdg/pyxdg/-/commit/9b913229ace838958e51a16cabc41905a2460f7b
I updated my /usr/lib/python3-dist-packages/xdg/Menu.py and the problem went away.
I'm trying to run flake8 on a docker django built like described here (tutorial page)
when building the docker image I get an error from flake8 which is run in an docker-compose file with like so
$ flake8 --ignore=E501,F401 .
multiprocessing.pool.RemoteTraceback:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/multiprocessing/pool.py", line 125, in worker
result = (True, func(*args, **
File "/usr/local/lib/python3.8/multiprocessing/pool.py", line 48, in
return list(map(*
File "/usr/local/lib/python3.8/site-packages/flake8/checker.py", line 666, in
return checker.run_checks()
File "/usr/local/lib/python3.8/site-packages/flake8/checker.py", line 598, in run_checks
self.run_ast_checks()
File "/usr/local/lib/python3.8/site-packages/flake8/checker.py", line 495, in run_ast_checks
checker = self.run_check(plugin, tree=ast)
File "/usr/local/lib/python3.8/site-packages/flake8/checker.py", line 426, in run_check
self.processor.keyword_arguments_for( File "/usr/local/lib/python3.8/site-packages/flake8/processor.py", line 241, in keyword_arguments_for arguments[param] = getattr(self, param)
File "/usr/local/lib/python3.8/site-packages/flake8/processor.py", line 119, in file_tokens
self._file_tokens = list(
File "/usr/local/lib/python3.8/tokenize.py", line 525, in _tokenize
pseudomatch = _compile(PseudoToken).match(line, pos)
RuntimeError: internal error in regular expression engine
The above exception was the direct cause of the following exception: Traceback (most recent call last):
File "/usr/local/bin/flake8", line 8, in <module>
sys.exit(main())
File "/usr/local/lib/python3.8/site-packages/flake8/main/cli.py", line 18, in main
app.run(argv)
File "/usr/local/lib/python3.8/site-packages/flake8/main/application.py", line 393, in run
self._run(argv)
File "/usr/local/lib/python3.8/site-packages/flake8/main/application.py", line 381, in _run
self.run_checks()
File "/usr/local/lib/python3.8/site-packages/flake8/main/application.py", line 300, in run_checks
self.file_checker_manager.run()
File "/usr/local/lib/python3.8/site-packages/flake8/checker.py", line 329, in run
self.run_parallel()
File "/usr/local/lib/python3.8/site-packages/flake8/checker.py", line 293, in run_parallel
for ret in pool_map:
File "/usr/local/lib/python3.8/multiprocessing/pool.py", line 448, in <genexpr>
return (item for chunk in result for item in chunk)
File "/usr/local/lib/python3.8/multiprocessing/pool.py", line 865, in next
raise value
RuntimeError: internal error in regular expression engine
When I run flake8 with the --verbose flag, I get an error like this:
Fatal Python error: deletion of interned string failed
Python runtime state: initialized
KeyError: 'FILENAME_RE'
from the tokenizer.py
Does anyone know how to solve this?
Additional Data:
running docker-compose v1.25.4 on an raspberry 3 with buster lite.
Installed and compiled Python 3.8.2 from source with the flag --enableloadable-sqlite
Thanks for helping!
If you don't care for flake8, then just delete that line. It will work. I had the same problem.
I know this isn't an answer. I would add a comment instead if I could.
I encountered a very similar error profile when I had refactored and left a lot of data which formerly had been in the top of the project down in what became the package folder. There were 33621 files including .venv, .nox, .pytest_cache, .coverage.
File "/usr/lib/python3.8/multiprocessing/pool.py", line 448, in <genexpr>
return (item for chunk in result for item in chunk)
File "/usr/lib/python3.8/multiprocessing/pool.py", line 868, in next
raise value
IndexError: string index out of range
If you see a similar signature (the parallel processing engine being overwhelmed in some way and throwing an exception), you may want to review your project directory structure and make sure that you did not put this kind of data in your sources directories.
I'm running a program (MGLTOOLS) by python scripts. When I start the program, I get the following error. I don't know python. I don't understood the error.
C:\Users\Goutham>set MGLPYTHONPATH=C:\Program Files (x86)\MGLTools 1.5.4
C:\Users\Goutham>"C:\Python25\python.exe" "C:\Program Files (x86)\MGLTools 1.5.4
\MGLToolsPckgs\AutoDockTools\bin\runAdt.py"
Run AutoDockTools from C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\AutoD
ockTools
Welcome to Python Molecule Viewer!
Visit http://mgltools.scripps.edu/documentation to read latest documentation.
Resource file used to customize PMV: C:\Users\Goutham\.mgltools\1.5.4\Pmv\_pmvrc
Traceback (most recent call last):
File "C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\AutoDockTools\__init
__.py", line 373, in runADT
title=title, withShell= not interactive, verbose=False)
File "C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\Pmv\moleculeViewer.p
y", line 315, in __init__
verbose=verbose, trapExceptions=trapExceptions)
File "C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\ViewerFramework\VF.p
y", line 345, in __init__
verbose=verbose)
File "C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\ViewerFramework\VFGU
I.py", line 277, in __init__
cnf = {"addScenarioButton": False})
File "C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\DejaVu\Viewer.py", l
ine 675, in __init__
cp = ClippingPlane(self.rootObject, i, self)
File "C:\Program Files (x86)\MGLTools 1.5.4\MGLToolsPckgs\DejaVu\Clip.py", lin
e 42, in __init__
self.id = self.clipPlaneNames[num]
IndexError: list index out of range
hit enter to continue
If this problem is arising as soon as you click on the GUI, you should contact MGL support and post on their forums, as StackOverflow is unlikely to be of any help (this might require a fix from the developers).
Note that the bug you are describing is described in this report:
http://mgldev.scripps.edu/bugs/show_bug.cgi?id=1216
I think it is resolved in the RC3 build. Download it here MGL Tools 1.5.6.
I'm trying to import GTK in Ubuntu Python 2.7, and I get the following error. PyGTK imports just fine. When I import gtk, I get the following error:
Exception in Tkinter callback Traceback (most recent call last):
File "/usr/lib/python2.7/lib-tk/Tkinter.py", line 1413, in __call__
return self.func(*args)
File "/usr/lib/python2.7/idlelib/MultiCall.py", line 167, in handler
r = l[i](event)
File "/usr/lib/python2.7/idlelib/PyShell.py", line 1140, in enter_callback
self.runit()
File "/usr/lib/python2.7/idlelib/PyShell.py", line 1181, in runit
more = self.interp.runsource(line)
File "/usr/lib/python2.7/idlelib/PyShell.py", line 619, in runsource
return InteractiveInterpreter.runsource(self, source, filename)
File "/usr/lib/python2.7/code.py", line 87, in runsource
self.runcode(code)
File "/usr/lib/python2.7/idlelib/PyShell.py", line 759, in runcode
self.tkconsole.endexecuting()
File "/usr/lib/python2.7/idlelib/PyShell.py", line 940, in endexecuting
self.showprompt()
File "/usr/lib/python2.7/idlelib/PyShell.py", line 1205, in showprompt
self.resetoutput()
File "/usr/lib/python2.7/idlelib/PyShell.py", line 1217, in resetoutput
if self.history:
File "/usr/lib/python2.7/idlelib/PyShell.py", line 64, in idle_showwarning
lineno, file=file, line=line))
TypeError: idle_formatwarning() got an unexpected keyword argument 'file'
How do I fix this?
This is a bug in idle. Looking at the last line of that error message:
File "/usr/lib/python2.7/idlelib/PyShell.py", line 64, in idle_showwarning
lineno, file=file, line=line))
TypeError: idle_formatwarning() got an unexpected keyword argument 'file'
This is saying that the warning.idle_showwarning method does not have an argument "file".
Sure enough looking at /usr/lib/python2.7/warnings.py
def formatwarning(message, category, filename, lineno, line=None)
There is no such argument.
This apparently has been resolved in source control but I do not think it has made it into a release yet. I would just hack the /usr/lib/python2.7/idlelib/PyShell.py file and remove the offending argument from line 64.
Then try it again...
Try it outside of IDLE. The error here is in IDLE, not your code.
Create a new script that contains import gtk and save it anywhere.
From the command line, in the directory where your script is located, run python whatever_your_scripts_name_is.py.
See if you get an error. You may not be able to import gtk in IDLE.
Edit: There is apparently a problem with GTK and IDLE in some situations on Ubuntu.
Try a different Python shell; I'd recommend IPython which you can install with Synaptic or sudo apt-get install ipython.
I am relatively new to Python, and at the same time, am attempting to install mod_dav_svn into my Apache web server. I am looking to get some idea of the scope of the error I'm receiving.
At the command line, I type in 'sudo yum install mod_dav_svn' and receive this output:
Loaded plugins: fastestmirror
Determining fastest mirrors
Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
yummain.user_main(sys.argv[1:], exit_code=True)
File "/usr/share/yum-cli/yummain.py", line 229, in user_main
errcode = main(args)
File "/usr/share/yum-cli/yummain.py", line 104, in main
result, resultmsgs = base.doCommands()
File "/usr/share/yum-cli/cli.py", line 339, in doCommands
self._getTs(needTsRemove)
File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 101, in _getTs
self._getTsInfo(remove_only)
File "/usr/lib/python2.4/site-packages/yum/depsolve.py", line 112, in _getTsInfo
pkgSack = self.pkgSack
File "/usr/lib/python2.4/site-packages/yum/init.py", line 591, in
pkgSack = property(fget=lambda self: self._getSacks(),
File "/usr/lib/python2.4/site-packages/yum/init.py", line 434, in _getSacks
self.repos.populateSack(which=repos)
File "/usr/lib/python2.4/site-packages/yum/repos.py", line 223, in populateSack
self.doSetup()
File "/usr/lib/python2.4/site-packages/yum/repos.py", line 71, in doSetup
self.ayum.plugins.run('postreposetup')
File "/usr/lib/python2.4/site-packages/yum/plugins.py", line 176, in run
func(conduitcls(self, self.base, conf, **kwargs))
File "/usr/lib/yum-plugins/fastestmirror.py", line 181, in postreposetup_hook
all_urls = FastestMirror(all_urls).get_mirrorlist()
File "/usr/lib/yum-plugins/fastestmirror.py", line 333, in get_mirrorlist
self._poll_mirrors()
File "/usr/lib/yum-plugins/fastestmirror.py", line 376, in _poll_mirrors
pollThread.start()
File "/usr/lib/python2.4/threading.py", line 416, in start
_start_new_thread(self.__bootstrap, ())
thread.error: can't start new thread
The only other question I could find with a similar error was this one: https://stackoverflow.com/search?q=can%27t+start+new+thread+python, but I'm not sure it has to do with running too many threads since I am the only one using the server, and this is one of the first python commands I have used. Could someone point me in the right direction, or towards some material that may help me troubleshoot the issue? Thanks!
Disable yum-fastermirror and you should be able to complete the install.
yum --disableplugin=fastestmirror update
Are you on a virtual machine?