##// END OF EJS Templates
Don't register the same callabck multiple times...
Don't register the same callabck multiple times Using the %matplotlib magics would not always work without this fix: For `%matplotlib qt5` to work, `flush_figures` should not be in `get_ipython().events.callbacks['post_execute']`. Yet without this fix: ```python Python 3.7.6 (default, Jan 8 2020, 20:23:39) [MSC v.1916 64 bit (AMD64)] Type "copyright", "credits" or "license" for more information. IPython 7.18.1 -- An enhanced Interactive Python. In [1]: %matplotlib inline In [2]: %matplotlib inline In [3]: %matplotlib inline In [4]: %matplotlib inline In [5]: get_ipython().events.callbacks['post_execute'] Out[5]: [<bound method AutoreloadMagics.post_execute_hook of <autoreload.AutoreloadMagics object at 0x00000199BFE73888>>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function matplotlib.pyplot.install_repl_displayhook.<locals>.post_execute()>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function ipykernel.pylab.backend_inline.flush_figures()>] In [6]: %matplotlib qt5 In [7]: get_ipython().events.callbacks['post_execute'] Out[7]: [<bound method AutoreloadMagics.post_execute_hook of <autoreload.AutoreloadMagics object at 0x00000199BFE73888>>, <function matplotlib.pyplot.install_repl_displayhook.<locals>.post_execute()>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function ipykernel.pylab.backend_inline.flush_figures()>, <function ipykernel.pylab.backend_inline.flush_figures()>] In [8]: ```

File last commit:

r25705:ad14ee33
r26114:73ca78ca
Show More
MANIFEST.in
46 lines | 804 B | text/plain | TextLexer
include README.rst
include COPYING.rst
include LICENSE
include setupbase.py
include setupegg.py
include MANIFEST.in
include pytest.ini
include mypy.ini
include .mailmap
recursive-exclude tools *
exclude tools
exclude CONTRIBUTING.md
exclude .editorconfig
graft setupext
graft scripts
# Load main dir but exclude things we don't want in the distro
graft IPython
# Documentation
graft docs
exclude docs/\#*
exclude docs/man/*.1.gz
exclude .git-blame-ignore-revs
# Examples
graft examples
# docs subdirs we want to skip
prune docs/build
prune docs/gh-pages
prune docs/dist
# Patterns to exclude from any directory
global-exclude *~
global-exclude *.flc
global-exclude *.yml
global-exclude *.pyc
global-exclude *.pyo
global-exclude .dircopy.log
global-exclude .git
global-exclude .ipynb_checkpoints