Spyder 5 won't launch - anaconda

I just downloaded Spyder 5 using
conda upgrade anaconda
conda install spyder=5.0.0
However, after installation when I launch Spyder from the Windows menu, I see a pop up indicating that Spyder 5 is launching. However, after a few seconds the popup disappears and Spyder does not launch.
When I try to launch Spyder from the Anaconda Navigator, I get the following error:
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\kite\kite_completions.png is overriding the existing kite_completions
f'The icon located in {complete_path} is overriding '
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\old_svg\CloseButton.svg is overriding the existing CloseButton
f'The icon located in {complete_path} is overriding '
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\spyder2_icon_theme\folding.arrow_down_off.png is overriding the existing folding.arrow_down_off
f'The icon located in {complete_path} is overriding '
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\spyder2_icon_theme\folding.arrow_down_on.png is overriding the existing folding.arrow_down_on
f'The icon located in {complete_path} is overriding '
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\spyder2_icon_theme\folding.arrow_right_off.png is overriding the existing folding.arrow_right_off
f'The icon located in {complete_path} is overriding '
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\spyder2_icon_theme\folding.arrow_right_on.png is overriding the existing folding.arrow_right_on
f'The icon located in {complete_path} is overriding '
C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\utils\image_path_manager.py:46: UserWarning: The icon located in C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\images\tour\tour-spyder-logo.svg is overriding the existing tour-spyder-logo
f'The icon located in {complete_path} is overriding '
No QCoreApplication instance found. Application patches not applied. You have to call load_stylesheet function after instantiation of QApplication to take effect.
ipython_console: cannot import name 'secure_write' from 'jupyter_core.paths' (C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jupyter_core\paths.py)
Traceback (most recent call last):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\solver.py", line 117, in find_external_plugins
mod = importlib.import_module(entry_point.module_name)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\importlib\__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1006, in _gcd_import
File "", line 983, in _find_and_load
File "", line 967, in _find_and_load_unlocked
File "", line 677, in _load_unlocked
File "", line 728, in exec_module
File "", line 219, in _call_with_frames_removed
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\plugins\ipythonconsole\plugin.py", line 24, in
from jupyter_client.connect import find_connection_file
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jupyter_client\__init__.py", line 4, in
from .connect import *
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jupyter_client\connect.py", line 35, in
from jupyter_core.paths import jupyter_data_dir, jupyter_runtime_dir, secure_write
ImportError: cannot import name 'secure_write' from 'jupyter_core.paths' (C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\jupyter_core\paths.py)
Pruned plugin: variable_explorer
Pruned plugin: plots
Traceback (most recent call last):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 2146, in create_window
main.setup()
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 836, in setup
plugin_deps = solve_plugin_dependencies(enabled_plugins.values())
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\solver.py", line 210, in solve_plugin_dependencies
plugin_deps = [plugin_names[name] for name in deps]
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\solver.py", line 210, in
plugin_deps = [plugin_names[name] for name in deps]
KeyError: 'plots'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\Scripts\spyder-script.py", line 10, in
sys.exit(main())
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\start.py", line 214, in main
mainwindow.main(options, args)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 2293, in main
mainwindow = create_window(app, splash, options, args)
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 2148, in create_window
if main.console is not None:
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 1159, in __getattr__
return self.get_plugin(self._INTERNAL_PLUGINS_MAPPING[attr])
File "C:\Users\USERNAME\AppData\Local\Continuum\anaconda3\lib\site-packages\spyder\app\mainwindow.py", line 168, in get_plugin
raise SpyderAPIError('Plugin "{}" not found!'.format(plugin_name))
spyder.api.exceptions.SpyderAPIError: Plugin "internal_console" not found!
I have already tried the following things already (unsuccessfully):
Uninstalling (through Windows menu) Spyder and reinstalling it in the Anaconda prompt
Installing Spyder 4 again conda install spyder=4.0.0. However, this does not launch either anymore.
What can I do to launch Spyder again?

Try to use:
icon_theme = spyder 2
in the file C:\Users<user_name>.spyder-py3\config\spyder.ini

You need remove Spyder History.
rm ~/.config/spyder-py3

I was having the same problem and I just completely uninstalled anaconda 3 with the Uninstall-Anaconda.exe then I reinstalled and updated everything again. That may not really be a viable option for you but I did get it to work.

Below commands worked for me without breaking anything:
conda update anaconda
and then
conda install spyder=5

Related

Anaconda will not launch due to DLL load failure

I am trying to install/use Anaconda on my pc with Windows 10.
After installation, Anaconda will not launch.
If I enter anaconda-navigator in the Anaconda Command Prompt i receive the error included at bottom of post.
I tried to update conda to resolve using conda update conda, conda update anaconda-navigator, anaconda-navigator --reset
all of which render “environment variables: conda info could not be constructed. KeyError(‘pkgs_dirs’)”.
I tried conda info to find the .condarc file but received a DLL error.
I tried adding anaconda3\Scripts to path but that hasn’t helped.
Here's a pic of my path vars if it helps:
–DLL error msg
Traceback (most recent call last): File
“C:\Users\Penelope\anaconda3\Scripts\anaconda-navigator-script.py”,
line 6, in from anaconda_navigator.app.main import main File
“C:\Users\Penelope\anaconda3\lib\site-packages\anaconda_navigator\app\main.py”,
line 19, in from anaconda_navigator.app.start import start_app File
“C:\Users\Penelope\anaconda3\lib\site-packages\anaconda_navigator\app\start.py”,
line 27, in from anaconda_navigator.widgets.main_window import
MainWindow File
“C:\Users\Penelope\anaconda3\lib\site-packages\anaconda_navigator\widgets\main_window_init_.py”,
line 25, in from anaconda_navigator.api.anaconda_api import
AnacondaAPI File
“C:\Users\Penelope\anaconda3\lib\site-packages\anaconda_navigator\api\anaconda_api.py”,
line 30, in from anaconda_navigator.api.client_api import ClientAPI
File
“C:\Users\Penelope\anaconda3\lib\site-packages\anaconda_navigator\api\client_api.py”,
line 23, in import binstar_client File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client_init_.py”,
line 21, in from .mixins.channels import ChannelsMixin File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\mixins\channels.py”,
line 7, in from binstar_client.utils import jencode File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\utils_init_.py”,
line 14, in from .config import (get_server_api, dirs, load_token,
store_token, File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\utils\config.py”,
line 90, in USER_LOGDIR = dirs.user_log_dir File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\utils\appdirs.py”,
line 253, in user_log_dir return user_log_dir(self.appname,
self.appauthor, version=self.version) File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\utils\appdirs.py”,
line 192, in user_log_dir path = user_data_dir(appname, appauthor,
version) File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\utils\appdirs.py”,
line 68, in user_data_dir path = os.path.join(_get_win_folder(const),
appauthor, appname) File
“C:\Users\Penelope\anaconda3\lib\site-packages\binstar_client\utils\appdirs.py”,
line 280, in _get_win_folder_with_pywin32 from win32com.shell import
shellcon, shell ImportError: DLL load failed while importing shell:
The specified procedure could not be found.

failed to import pywin32 (even if it already installed) while starting supervisord in windows nanoserver container

I am trying to bring two process up in a windows Nanoserver container using supervisord (pip install supervisor-win )
Everything is setup in supervisord.conf, while starting it I am facing below issue,
C:\data>supervisord -n
C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\options.py:480: UserWarning: Supervisord is running as root and it is searching for its configuration file in default locations (inc
luding its current working directory); you probably want to specify a "-c" argument specifying an absolute path to a configuration file for improved security.
self.warnings.warn(
Traceback (most recent call last):
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\loggers.py", line 220, in _disable_inheritance_filehandler
import win32api
oduleNotFoundError: No module named 'win32api'
D
uring handling of the above exception, another exception occurred:
T
raceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "C:\python-3.11.1-embed-amd64\Scripts\supervisord.exe\__main__.py", line 7, in <module>
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\supervisord.py", line 403, in main
go(options)
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\supervisord.py", line 415, in go
d.main()
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\supervisord.py", line 77, in main
self.options.make_logger()
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\options.py", line 1221, in make_logger
loggers.handle_file(
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\loggers.py", line 444, in handle_file
handler = RotatingFileHandler(filename, 'a', maxbytes, backups)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\loggers.py", line 211, in __init__
self._disable_inheritance_filehandler() # fix file used by others process
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\python-3.11.1-embed-amd64\Lib\site-packages\supervisor\loggers.py", line 223, in _disable_inheritance_filehandler
raise ImportWarning("log rotation requires the installation of the \"pywin32\" library.\n"
ImportWarning: log rotation requires the installation of the "pywin32" library.
Download and install from https://github.com/mhammond/pywin32/releases
C:\data>
pywin32 module is already installed (tried reinstall with whl and pip anyway, that did not help)
C:\data>python -m pip show pywin32
Name: pywin32
Version: 305
Summary: Python for Window Extensions
Home-page: https://github.com/mhammond/pywin32
Author: Mark Hammond (et al)
Author-email: mhammond#skippinet.com.au
License: PSF
Location: C:\python-3.11.1-embed-amd64\Lib\site-packages
Requires:
Required-by: pypiwin32, supervisor-win
C:\data>
What could be the issue here? I see less dll files (around 400 only) in C:\Windows\System32 compared to servercore/server image (This is working fine with windows servercore image.)

SerpentAI Installation error

I have been trying to install SerpentAI. I am on a Mac, and I have followed all the steps. I have all the dependencies, but when I use the keyword serpent it gives me this error.
I know I am missing a config file but I don't know where to find it, or how to solve this.
Any command that started with serpent gave me this error.
Here is the error
Traceback (most recent call last):
File "/anaconda3/bin/serpent", line 11, in <module>
load_entry_point('SerpentAI==2018.1.2', 'console_scripts', 'serpent')()
File "/anaconda3/lib/python3.6/site- packages/pkg_resources/__init__.py", line 480, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2691, in load_entry_point
return ep.load()
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2322, in load
return self.resolve()
File "/anaconda3/lib/python3.6/site-packages/pkg_resources/__init__.py", line 2328, in resolve
module = __import__(self.module_name, fromlist=['__name__'], level=0)
File "/anaconda3/lib/python3.6/site-packages/SerpentAI-2018.1.2-py3.6.egg/serpent/serpent.py", line 11, in <module>
from serpent.utilities import clear_terminal, display_serpent_logo, is_linux, is_macos, is_windows, is_unix, wait_for_crossbar
File "/anaconda3/lib/python3.6/site-packages/SerpentAI-2018.1.2-py3.6.egg/serpent/utilities.py", line 8, in <module>
from serpent.config import config
File "/anaconda3/lib/python3.6/site-packages/SerpentAI-2018.1.2-py3.6.egg/serpent/config.py", line 18, in <module>
raise Exception("Configuration file not found at: 'config/config.yml'...")
Exception: Configuration file not found at: 'config/config.yml'...
So I think I found the problem, you can clone the GitHub repo, and it will have the config files. Then when you run pip install it will clone a version, and that version won't have the config files.
I had the same issue when trying to run serpent vi sual_debugger after following all installation guide steps.
Try to run serpent setup, it might solve the problem you have. It helped in my case.

Error windows with specified version of firefox and selenium

I am using python and selenium.
On my pc, i have two version of firefox
the first one in ProgrammFiles is version 21
The latest one is in "C:\Users\User\AppData\Local\Mozilla Firefox"
I would like to run selenium on the lastest one, but i got an error message:
from selenium import webdriver
from selenium.webdriver.firefox.firefox_binary import FirefoxBinary
binary = FirefoxBinary("C:\Users\User\AppData\Local\Mozilla Firefox")
browser = webdriver.Firefox(firefox_binary=binary)
Traceback (most recent call last):
File "", line 1, in
browser = webdriver.Firefox(firefox_binary=binary)
File "C:\Python27\lib\site-packages\selenium-2.48.0-py2.7.egg\selenium\webdriver\firefox\webdriver.py", line 77, in init
self.binary, timeout),
File "C:\Python27\lib\site-packages\selenium-2.48.0-py2.7.egg\selenium\webdriver\firefox\extension_connection.py", line 49, in init
self.binary.launch_browser(self.profile)
File "C:\Python27\lib\site-packages\selenium-2.48.0-py2.7.egg\selenium\webdriver\firefox\firefox_binary.py", line 67, in launch_browser
self._start_from_profile_path(self.profile.path)
File "C:\Python27\lib\site-packages\selenium-2.48.0-py2.7.egg\selenium\webdriver\firefox\firefox_binary.py", line 90, in _start_from_profile_path
env=self._firefox_env)
File "C:\Python27\lib\subprocess.py", line 710, in init
errread, errwrite)
File "C:\Python27\lib\subprocess.py", line 958, in _execute_child
startupinfo)
WindowsError: [Error 5] アクセスが拒否されました。
Do you have any hint to give me to solve this problem ?
The firefox binary path that needs to be passed in FirefoxBinary('') should be the path for the executable 'firefox.exe'.
E.g.:
ff_binary = FirefoxBinary("C:\\Program Files (x86)\\Mozilla Firefox\\firefox.exe")
driver = webdriver.Firefox(firefox_binary=ff_binary)
PS: In your case, the path you've specified is the path where the firefox profile is stored normally.
Hope this helps.

Unable to run Windmill, multiple errors

I have been having all kinds of problems getting Windmill setup and installed. I thought I finally got it setup, but now when I try to just run windmill, I get the following errors. Any help is appreciated.
c:\Python33\Scripts>windmill firefox http://www.google.com Traceback
(most recent call last): File
"c:\Python33\Scripts\windmill-script.py", line 9, in
load_entry_point('windmill==1.6', 'console_scripts', 'windmill')() File
"C:\Python33\lib\site-packages\distribute-0.6.49-py3.3.egg\pkg_resources.
py", line 345, in load_entry_point
return get_distribution(dist).load_entry_point(group, name) File "C:\Python33\lib\site-packages\distribute-0.6.49-py3.3.egg\pkg_resources.
py", line 2382, in load_entry_point
return ep.load() File "C:\Python33\lib\site-packages\distribute-0.6.49-py3.3.egg\pkg_resources.
py", line 2088, in load
entry = import(self.module_name, globals(),globals(), ['name']) File
"C:\Python33\lib\site-packages\windmill-1.6-py3.3.egg\windmill__init__.p
y", line 17, in
import bin, browser, server, conf, tools, sys ImportError: No module named 'bin'
I had the same issue; Windmill doesn't work with Python 3.x. To fix the problem install Python 2.x

Resources