Spyder: Spyder complains about missing ipykernel module in external interpreters

Created on 11 Sep 2017  路  18Comments  路  Source: spyder-ide/spyder

While trying to use Spyder with the Python3.6.3 core I get such error; "Your Python environment or installation doesn't have the ipykernel module installed on it. Without this module is not possible for Spyder to create a console for you."

What steps will reproduce the problem?

  1. Get Python 3.6.2 installed along with 3.5.4
  2. Launch Spyder and got to Tools -> Preferences -> Python Interpreter
  3. Switch to python3.6
  4. Try to open a new Ipython console

What is the expected output? What do you see instead?

Get this error:

```An error occurred while starting the kernel
Your Python environment or installation doesn't have the ipykernel module installed on it. Without this module is not possible for Spyder to create a console for you.

You can install ipykernel by running in a terminal:
pip install ipykernel
or
conda install ipykernel

**Please provide any additional information below**

have tried to install the missing ipykernel thinking it might be missing for the Python3.6 environment but no luck. The package seems to be already installed so nothing needs to be done. 

## Versions and main components

* Spyder Version: Spyder 3.2.2
* Python Version: 3.6.2
* Qt Version: 
* PyQt Version:
* Operating system: Kali Linux, all updates applied.


## Dependencies

Please go to the menu entry `Help > Optional Dependencies` (or
`Help > Dependencies`), press the button `Copy to clipboard`
and paste the contents below:

IPython >=4.0 : 6.1.0 (OK)
cython >=0.21 : None (NOK)
jedi >=0.9.0 : 0.10.2 (OK)
nbconvert >=4.0 : 5.3.1 (OK)
numpy >=1.7 : 1.9.1 (OK)
pandas >=0.13.1 : None (NOK)
psutil >=0.3 : 5.3.1 (OK)
pycodestyle >=2.3: 2.3.1 (OK)
pyflakes >=0.6.0 : 1.6.0 (OK)
pygments >=2.0 : 2.2.0 (OK)
pylint >=0.25 : 1.7.2 (OK)
qtconsole >=4.2.0: 4.3.1 (OK)
rope >=0.9.4 : 0.10.7 (OK)
sphinx >=0.6.6 : 1.5.5 (OK)
sympy >=0.7.3 : None (NOK)
```

IPython Console Bug

Most helpful comment

Same issue with me. It seems this is due to multiple envs in Conda and Python Installation

--- Reset Spyder to factory defaults solved issue. Thanks

All 18 comments

Thanks for reporting. We'll take a look at this in a future release.

I can't reproduce this error, sorry.

I come acrosss the same error.

@autodataming, we're working to improve this situation in our next release.

Same issue with me. It seems this is due to multiple envs in Conda and Python Installation

--- Reset Spyder to factory defaults solved issue. Thanks

Is there any way to solve this issue? While i'm useing python 2.7 it's working fine.
But when i try to use py 3.6 it should the error:
An error ocurred while starting the kernel
Your Python environment or installation doesn't have the ipykernel and cloudpickle modules installed on it. Without these modules is not possible for Spyder to create a console for you.

You can install them by running in a system terminal:

pip install ipykernel cloudpickle

after i install the ipykernel cloudpickle from console, it's still not working.

@gordonzhu, we're working to improve this in Spyder 3.3, to be released next month.

has it been fixed please?

With version 3.3.0 it complains about spyder-kernels:
An error ocurred while starting the kernel
Your Python environment or installation doesn't have the spyder鈥慿ernels module installed on it. Without this module is not possible for Spyder to create a console for you.

Same error, when I type python in my console, it launches _Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 17:00:18) [MSC v.1900 64 bit (AMD64)] on win32_ that pip works with.
But in Spyder it uses version _Python 3.6.6 (v3.6.6:4cf1f54eb7, Jun 27 2018, 03:37:03) [MSC v.1900 64 bit (AMD64)]_
Trying to launches 3.6.5 executabe in spyder, gives my spyder-kernel issue.

@AdrienMau, please read:

https://github.com/spyder-ide/spyder/wiki/Working-with-packages-and-environments-in-Spyder#2-the-modular-approach

to understand how to use other Python environments in Spyder.

This issue still exists in Spyder 3.3.1, but I was able to get the kernel working by running conda install spyder-kernels=0.* when my environment was activated.

--EDIT. Everything below this point is incorrect and caused by issues when I tried to copy-paste the command to install spyder-kernels. I'm leaving it just in case it is useful to someone else. --

The spyder-kernels package is not available with either conda or pip so I cannot run an ipython interpreter from my environment.

Steps to reproduce:

  1. Create a new environment.
  2. In Spyder, switch the interpreter to run from the python.exe located in the environment directory.
  3. Spyder 3.3.1 complains that Your Python environment or installation doesn't have the spyder鈥慿ernels module or the right version of it installed. and recommends you install spyder-kernels=0.* using either pip or conda.
  4. Try to install spyder-kernels using conda or pip.
  5. Both attempts fail. (conda doesn't have the package, pip gets an "invalid requirement".

spyder: 3.3.1
conda: 4.5.9

I Installed fresh Anaconda and then within that when I open Spyder I got this message in return
Capture

I tried the following command to install ipykernels but after that also it is not showing.
conda create -n py38 python=3.8 spyder-kernels
conda install spyder-kernels
conda install ipykernels

and I got same issue with spyder until now. and when I tried to update spyder in anaconda to the latest version it shows me unable to update.

I stumbled upon the same issue as @BeatkinGourav.

and I got same issue with spyder until now. and when I tried to update spyder in anaconda to the latest version it shows me unable to update.

Try

conda update anaconda
conda update spyder

Same issue as @BeatkinGourav. OS X Mojave, Python 3.8, and Spyder 4.1.3 installed using conda.

Resolved by Preferences-> Reset to Defaults as suggested by @afarane.

I'm getting this issue 3 years after it's closed. When I follow the instruction with the conda install spyder鈥慿ernels=0.* in the environment of the Python executable, I get:

```PackagesNotFoundError: The following packages are not available from current channels:

  • spyder鈥慿ernels=0

Current channels:

Upd: solved with conda install -c conda-forge spyder-kernels=0.*

Was this page helpful?
0 / 5 - 0 ratings