Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jupyter Notebook is not showing the output of any code executed on the cell #11027

Closed
s13varun opened this issue Mar 1, 2018 · 70 comments
Closed
Milestone

Comments

@s13varun
Copy link

s13varun commented Mar 1, 2018

Hello,
I am new to python. When I use Jupyter Notebook the code inside the cells won't execute and I get these empty brackets ([ ]).
jn

@takluyver
Copy link
Member

  • Do you have any security software installed? We've seen similar problems with some internet security software blocking our connection.
  • Does it work if you try in another browser (like Firefox)?

@s13varun
Copy link
Author

s13varun commented Mar 1, 2018

no security software.
It was working on chrome 1 week before

@takluyver
Copy link
Member

Any ideas what changed? Did you install any extensions or update anything? It's still worth trying with another browser.

@s13varun
Copy link
Author

s13varun commented Mar 1, 2018

Let me try with firefox

@s13varun
Copy link
Author

s13varun commented Mar 1, 2018

it launches with chrome default.
Is it possible to change browser

@takluyver
Copy link
Member

Yes. For testing temporarily, right click the Jupyter logo in Chrome and copy the link, then paste it into Firefox.

If you want to override the default, configure NotebookApp.browser (see config docs).

@s13varun
Copy link
Author

s13varun commented Mar 2, 2018

Same issue in firefox.

@takluyver
Copy link
Member

How are you trying to execute the cells?

@s13varun
Copy link
Author

s13varun commented Mar 3, 2018 via email

@kHimanshu1
Copy link

Try restarting the kernel in kernel option

@ariansacct
Copy link

ariansacct commented Jul 20, 2018

Restarting the kernel solves it temporarily. What is the cause and the permanent fix?
It was working fine on my box two days ago, and I have not changed anything.

@kHimanshu1
Copy link

it can be caused by many reasons like:

  1. your antivirus is blocking it.
  2. your code it taking too long to execute(due to hardware limitations).
  3. something is wrong with your python distribution package. (try reinstalling it)

@ariansacct
Copy link

ariansacct commented Jul 22, 2018

Like I said, it was working as recently as two days ago. Code is just a simple loop. There is no antivirus installed. I have not updated any package during this time.
Right now I'm restarting the kernel for every run, which is very annoying.

@kurt-rhee
Copy link

This problem is also happening for me in a simple for loop. Using chrome browser.

@grantrob
Copy link

grantrob commented Aug 9, 2018

One reproducible way to force Jupyter to stop showing new output (and make the kernel hang) is to run "cat" in a cell with no arguments (on Google Chrome / Ubuntu 16.04). If there is a way to solve this problem (send a Ctrl-D to the kernel?), it might also solve the other looping problems.

@Ravindra-Marwadi
Copy link

yes it is also happening with me .. i thought it as antivirus problem but i think its not, because i had reinstalled it by disabling my antivirus .. but it is not working still ... don't know what to do ... i had also tried another browser option like Mozilla chrome Microsoft edge also with internet explorer .. but it still not working.... somebody plzz help...

@husseinm-ml
Copy link

husseinm-ml commented Sep 30, 2018

Hi,
I have just installed juypeter and I have the same issue. I tried on both chrome and iexplorer. When I try to restart the kernel, it gets stuck and this message shows forever "kernel starting, please wait"

@khamiruf
Copy link

khamiruf commented Nov 8, 2018

hi anyone has the answer? i have the same problem too

@Sophie-Germain
Copy link

I have the same problem :(

@nmaiorana
Copy link

Any answers here?

@fgtom
Copy link

fgtom commented Nov 25, 2018

In my case, the below solution worked. (Downgrading tornado to 4.xx)

jupyter/notebook#3202 (comment)

@stmax82
Copy link

stmax82 commented Dec 2, 2018

@fgtom downgrading tornado didn't work for me :/

I occasionally run into this problem since a while... I already tried disabling Windows Defender and the Firewall and different browsers without success. I installed the Jupyter Notebook using conda. I also tried reinstalling it globally and in conda environments without success either. :( This is really annoying...

@RishabhVerma098
Copy link

same thing happened to me ...but when I disabled my adaware antivirus ..it worked...!!!!

@Zitihskx
Copy link

I am having problem of not compiling. It shows In[*] whenever i compile. I have tried all solutions above, disabling my defender, changing browser options, reinstalling python package , installing jupyter through pip install and anaconda but still problem stays. What can be the solution??

@JaceRyczak
Copy link

Disabling Adaware antivirus solved this problem for me.

@graphedge
Copy link

Why is there no one assigned to this? This approaches being a dealbreaker for corporate people running jupyter behind mandated antivirus.

@takluyver
Copy link
Member

Perhaps said corporate people should contribute to understanding and fixing the problem?

@stmax82
Copy link

stmax82 commented Dec 20, 2018

@takluyver I already spent several hours trying to find the cause, both at work and at home, but found that I lack experience with the code base / the architecture / how components are supposed to communicate. I'm sure if someone more experienced with the project could provide some hints on where to look / what to try everyone would be more than willing to work on a solution.

@darshanc99
Copy link

Simply uninstall your adaware antivirus. It fixes the issue!

@MehrdadDS
Copy link

First of all, let's check the state of any cell is the "Code" not in "Markdown"

@michaelort33
Copy link

This happened to me and I realized the issue was caused by a duplicate nbextensions directory this leads to duplicated .yaml files for the scratchpad extension.

I fixed by simply typing jupyter --paths into the console. Looking where my jupyter nbextensions were stored. I had nbextensions stored in both myname/anaconda3/etc/jupyter and in myname/.local/share/jupyter

I deleted the nbextension from myname/.local/share/jupyter and I kept the one in anaconda3 folder.

Problem solved!

@Jatindevaiah
Copy link

As @Hazarmavi mentioned. fixed it by upgrading kernel using the following command: python -m pip install --upgrade ipykernel

@yamasampo
Copy link

I have the same problem. I tried downgrading tornado and upgrading ipykernel and confirmed that I do not have duplicated nbextensions, but my problem has not been solved yet. (This is pretty annoying and I cannot work on anything.)

In my environment, conda list | grep "tornado" gives
tornado 5.1.1 py36h1de35cc_0

and conda list | grep "ipykernel" returns
ipykernel 5.1.1 py36h39e3cac_0

Does any body have any other suggestions?

@archenroot
Copy link

First time facing this issue, asking wtf of course :-), On Gentoo don't have this issue, but was using now WLS Ubuntu via virtualenv in W10 host. Well, I just did CTRL+C in terminal, which triggered Jupyter to be completely restarted (it won't shutdown) and now outputs magically appeared automatically.

@Aref-cs
Copy link

Aref-cs commented Sep 26, 2019

I have the same problem.
1- Shouldn't the activation circle close to the Python be 'green' if the Python is working properly?
2- Moreover, what is that asterisks that appears after I run a line?

jupyter_problem

@fisadev
Copy link

fisadev commented Oct 7, 2019

@Aref-cs

  1. That circle isn't green. An empty circle means the kernel of the notebook isn't doing anything, and a full circle means it's running code.
  2. The asterisks in the cells mean they are being executed, they change to the number when they finish executing the code.

@StevenRoland
Copy link

I had the same issue. I just ran the prompt as administrator as I found a permission error displayed in Jupyter Notebook and disabled my firewall and it works fine.

@wajdan846
Copy link

wajdan846 commented Nov 4, 2019

try reinstalling python as well e.g in my case python 3.5.2 worked fine as I was having problems with python 3.8 and so after reinstalling jupyter notebook things seem to run perfectly.

@ck3mp
Copy link

ck3mp commented Nov 5, 2019

I had the exact same issue. Downgrading to Tornado 5.1.1 fixed the issues
(Windows 7, Python 3.7.5, Spaces in the path name to the venv that Jupyter runs from)

@capitao014
Copy link

I have the same problem.
1- Shouldn't the activation circle close to the Python be 'green' if the Python is working properly?
2- Moreover, what is that asterisks that appears after I run a line?

jupyter_problem

Restart kernel solved the same problem for me.

@CharlieZhu
Copy link

I found the missing output redirected to Jupyter Notebook console, after running django.setup(). Then, reset the stdout, solved. Don't know detail yet.

import os, sys
print 'django setup start.'
stdout = sys.stdout
import django
django.setup()
sys.stdout = stdout
print 'django setup done.'

@plammens
Copy link

I have found that I encounter this issue every time an unhandled exception bubbles up to the notebook. In those cases I have to restart the kernel every time—which is very frustrating.

@maximelucas
Copy link

I am having the same issue. It started happening yesterday after installing numba with
python3 -m pip install numba --user

I tried downgrading to tornado 5.1.1 but it does not fix the issue.
In any case, I run Jupyter Notebook 6.0.1 (Python Python 3.6.9), which should not have any problem with the latest version of tornado (6.0.3).

I am on Ubuntu 18.04, so no antivirus. It is not because of the running time of the cell either, it happens with basic '2+2' cells.

Any clue?

@Saswatm123
Copy link

I am having the same issue as @woodrujm , where my Python output works fine, but my R output doesn't work properly. The graphs for R work, but the regular output prints to my console rather than the cell output area. I am trying everything here and will report back if I find anything that doesn't involve settling for reading off my console.

@AtharvaKitkaru
Copy link

Hello,
I am new to python. When I use Jupyter Notebook the code inside the cells won't execute and I get these empty brackets ([ ]).
jn

Uninstalling antivirus worked for me

@diwert-ai
Copy link

I had the same issue. Solution was found here:
jupyter/notebook#4613 (comment)

@Raghu0210
Copy link

import sys
Fixed the issue

@Aref-cs
Copy link

Aref-cs commented Feb 12, 2020

Hi guys!

I don't have a fix for this issue, since I stopped using my local system! I have a short-term (or maybe long-term) fix for this issue for those who just want to start coding instead of trouble shooting Jupyter and Python packages: use something like Google Colab!

I had an issue with Jupyter, then I switched to Anaconda and used JupyterLab, but both had the same issue of having problems with the server connections! I had removed and installed Jupyter, Anaconda and Python several times and changed settings too.

But to me, it was so much hassle! especially, since I was using Windows and once something goes wrong in windows, it continues to go wrong! :)) Also, I don't get it! Almost whenever I started using a new technique, application or technology, I had to dedicate the first week (or two) of my work to trouble shooting for the thing to just start working on my system! :) So, I switched to online alternatives such as the one CoCalc provides. But for now, I am using Google Colab and it works just fine!

@lukasbee1
Copy link

image
I don't know what this numbers mean, but without them I can't see any outbut.

I solved this problem by creating with new field, which was created with numbers.

@adilodha
Copy link

adilodha commented Apr 7, 2020

i would like to add one observation:
when i run a loop goes into infinite execution, jupyter notebook stops showing output of executed code. restarting the kernel did resolve the issue.
I think this issue occurs in case of execution time out.

@Vikram-kotharu
Copy link

hello in my jupyter notebook class function is not working
Screenshot (11)..pls help me

@kaykayes
Copy link

had the same issue , fixed it by closing all tabs, reopening the files in JupyterLab v1.2.6, rerunning the cells one after the other. - watiting for the first one to finish before running the next cell.....I am now getting all the output just fine.

@louiselmps
Copy link

Had the same issue turns out i was downloading all dependencies in my local not inside the tensorflow VM (tensorflow_cpu / tensorflow_gpu). So make sure you are inside the VM

@Carreau Carreau added this to the not ipython milestone May 4, 2020
@Carreau
Copy link
Member

Carreau commented May 4, 2020

Closing as this issue is not in IPython itself and if still problematic and relevant should be opened on the right repository if this is an actual bug or code proposal. For general help use discourse. This will allow to keep the number of opened issue on the IPython repo under control and allow you to get faster response.

@TkRj
Copy link

TkRj commented May 30, 2020

Hi

I could not solve this either but I am a beginner so I am not particular about IDEs at the moment. I just want to learn the important computing concepts quick and not waste my time troubleshooting this problem.
Solution: I switched to Visual Studio Code and it has not given me any problem.
Click here: https://code.visualstudio.com/ to download it.

Hope this helps!

@aparajitad60
Copy link

Downgrade tornado, this worked for me.

pip install tornado==4.5.3

@ipython ipython locked and limited conversation to collaborators Jul 2, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests