ipython / ipython/ipykernel

Process hang while executing logging.warning under specific circumstances

Aberta
#1,166 11 comentários 1 reação 0 responsáveis Ver no GitHub
Linguagem predominante
Python
Estrelas
734
Forks
412
Merge médio
1d 5h
PRs com merge (30d)
8

Descrição

I identified a kernel hang when calling the python logging facility under certain circumstances. The hang is specific for usage of function in jupyter, i.e. it does not happen in a ipython command shell.

The hang happens when I import a specific module form this repository: https://github.com/secdev/scapy/ (the issue can be reproduced with the version from pip as well).

```
from scapy.route6 import *
```

The hang happens in line 234 when this method is called

```
warning("No route found for IPv6 destination %s (no default route?)" % dst)
```

warning() is a wrapper that calls

```
logging.getLogger("scapy.runtime").logging(x)
```

where x is the message. I am not able to reproduce this issue in a smaller test case, i.e. I cannot find other situations where a call to logging.warning() hangs the kernel.

The reason why I open this issue with jupyter is that the jupyter notebook is the only environment where this results in a hang. The code works without issues in the standard python2.7 interpreter, and in the ipython command shell

I experience the issue on Mac OS X with the following python, and package versions

```
$ python --version
Python 2.7.10
```

ipython and jupyter versions are:

```
ipykernel==4.3.1
ipython==4.2.0
ipython-genutils==0.1.0
ipywidgets==5.1.2
jupyter==1.0.0
jupyter-client==4.2.2
jupyter-console==4.1.1
jupyter-core==4.1.0
```

Is there any additional information that I can provide to further debug this problem?

Guia de contribuição

Abrir o guia de contribuição

Avaliação

Esta issue ainda não foi avaliada.

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.