I have installed miniconda
and created a virtual env with the name dataScience
and installed all the required files for the spyder
to work on WSL.
I have used the following commands:
1.) Spyder installation:
conda install matplotlib spyder scipy
2.) And other dependencies:
sudo apt-get install libxcursor-dev
sudo apt-get install alsa
sudo apt install libegl1-mesa libegl1
3.) And installed the X11 client on Windows 10 by downloading VcXsrv
4.) After that added the following scripts in ./bashrc
:
DISPLAY=:0
export DISPLAY
export XDG_RUNTIME_DIR="/mnt/d/codes/py38/dataScience"
LIBGL_ALWAYS_INDIRECT=1
Export LIBGL_ALWAYS_INDIRECT
5.) And did source ~/.bashrc
and in WSL ubuntu-20.04 LTS terminal I ran the command spyder
(after starting the X server
on windows10) and I got the following error:
The problem:
[6876:6820:1011/001550.176657:FATAL:dev_linux.cc(29)] Check failed: 0 == ret (0 vs. -22)
#0 0x7f0a83sd60be <unknown>
#1 0x7f0a837y86c2 <unknown>
#2 0x7f0a878j4c18 <unknown>
#3 0x7f0a847ekljb <unknown>
#4 0x7f0a83f8d9e3 <unknown>
#5 0x7f0a83f31090 <unknown>
#6 0x7f0a83f326e8 <unknown>
#7 0x7f0a83f32a7b <unknown>
#8 0x7f0a83f34782 <unknown>
#9 0x7f0a83f30438 <unknown>
#10 0x7f0a83f4kj9b <unknown>
#11 0x7f0a83a470dc <unknown>
#12 0x7f0a83a4lode <unknown>
#13 0x7f0a83f65678 <unknown>
#14 0x7f0a83f6pqab <unknown>
#15 0x7f0a9db66cx9 start_thread
#16 0x7f0a9da82093 clone
[6876:6566:0100/000000.379311:ERROR:broker_posix.cc(41)] Invalid node channel message
Aborted (core dumped)
Am new in this field and scratching my head right now. If anyone has the solution do answer. Thank you!
I was able to reproduce your problem with Ubuntu 20.04 LTS. However, I was able to get Spyder to work with Ubuntu 18.04 LTS following the same instructions.
To get Ubuntu 18.04 LTS, make sure WSL is enabled on your windows machine and then download Ubuntu 18.04 LTS from the Microsoft Store.
On step 4, change Export on the last line to a lower case e.
For those who are not running within a viritualenv,
export XDG_RUNTIME_DIR="/mnt/d/codes/py38/dataScience"
line can be omitted.Secondly, you also need to install the package
sudo apt-get install libxss1
sudo apt-get install libxtst6
andsudo apt-get install libasound2-plugins
After that, restart your terminal. Then type
spyder
and everything should work. You may get warnings along the lines oflibpng warning: bKGD: invalid
however, these aren't critical. If you feel the need to fix them, then refer to : Incorrect rendering in Anaconda + Spyder (wrong colours in text)