ipython 9.5.0__tar.gz → 9.7.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/completer.py +127 -14
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/debugger.py +116 -15
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/displaypub.py +23 -1
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/guarded_eval.py +628 -38
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magic.py +143 -117
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magic_arguments.py +6 -4
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/basic.py +52 -24
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/execution.py +19 -37
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/history.py +24 -7
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/release.py +1 -1
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/shellapp.py +5 -1
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/ultratb.py +15 -6
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/deduperreload/deduperreload_patching.py +17 -17
- {ipython-9.5.0 → ipython-9.7.0}/IPython/external/pickleshare.py +8 -66
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/interactiveshell.py +8 -3
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/shortcuts/__init__.py +1 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/PyColorize.py +35 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_sysinfo.py +1 -1
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/py3compat.py +0 -10
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/text.py +2 -2
- {ipython-9.5.0 → ipython-9.7.0}/MANIFEST.in +0 -2
- {ipython-9.5.0/ipython.egg-info → ipython-9.7.0}/PKG-INFO +25 -26
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/details.rst +1 -1
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/reference.rst +59 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/overview.rst +2 -3
- ipython-9.7.0/docs/source/whatsnew/development.rst +52 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version9.rst +82 -0
- {ipython-9.5.0 → ipython-9.7.0/ipython.egg-info}/PKG-INFO +25 -26
- {ipython-9.5.0 → ipython-9.7.0}/ipython.egg-info/requires.txt +22 -22
- {ipython-9.5.0 → ipython-9.7.0}/pyproject.toml +42 -38
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_completer.py +631 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_debug_magic.py +1 -1
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_debugger.py +313 -1
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_display_2.py +71 -9
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_formatters.py +30 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_guarded_eval.py +199 -13
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_interactiveshell.py +12 -9
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_magic.py +67 -4
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_run.py +5 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_ultratb.py +11 -1
- ipython-9.5.0/docs/source/whatsnew/development.rst +0 -34
- {ipython-9.5.0 → ipython-9.7.0}/.flake8 +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/.mailmap +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/.pre-commit-config.yaml +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/COPYING.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/__main__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/alias.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/application.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/async_helpers.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/autocall.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/builtin_trap.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/compilerop.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/completerlib.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/crashhandler.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/debugger_backport.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/display.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/display_functions.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/display_trap.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/displayhook.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/doctb.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/error.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/events.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/extensions.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/formatters.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/getipython.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/history.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/historyapp.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/hooks.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/inputtransformer2.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/interactiveshell.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/latex_symbols.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/logger.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/macro.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/ast_mod.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/auto.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/code.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/config.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/display.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/extension.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/logging.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/namespace.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/osm.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/packaging.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/pylab.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/magics/script.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/oinspect.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/page.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/payload.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/payloadpage.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/prefilter.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/profile/README_STARTUP +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/profileapp.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/profiledir.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/pylabtools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/splitinput.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/tbtools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/tips.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/core/usage.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/display.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/autoreload.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/deduperreload/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/deduperreload/deduperreload.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/storemagic.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/extensions/tests/test_deduperreload.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/external/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/external/qt_for_kernel.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/external/qt_loaders.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/backgroundjobs.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/clipboard.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/deepreload.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/demo.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/display.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/editorhooks.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/guisupport.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/latextools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/lexers.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/lib/pretty.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/paths.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/py.typed +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/sphinxext/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/sphinxext/custom_doctests.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/sphinxext/ipython_console_highlighting.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/sphinxext/ipython_directive.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/debugger.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/embed.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/ipapp.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/magics.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/prompts.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/asyncio.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/glut.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/gtk.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/gtk3.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/gtk4.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/osx.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/pyglet.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/qt.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/tk.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/pt_inputhooks/wx.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/ptutils.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/shortcuts/auto_match.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/shortcuts/auto_suggest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/terminal/shortcuts/filters.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/decorators.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/globalipapp.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/ipunittest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/Makefile +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/dtexample.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/ipdoctest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/pytest_ipdoctest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/setup.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/simple.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/simplevars.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/test_combo.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/test_example.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/test_exampleip.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/test_ipdoctest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/plugin/test_refs.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/skipdoctest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/testing/tools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_process_cli.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_process_common.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_process_emscripten.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_process_posix.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_process_win32.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/_process_win32_controller.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/capture.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/coloransi.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/contexts.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/data.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/decorators.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/dir2.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/docs.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/encoding.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/eventful.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/frame.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/generics.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/importstring.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/io.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/ipstruct.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/jsonutil.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/log.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/module_paths.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/openpy.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/path.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/process.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/sentinel.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/strdispatch.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/sysinfo.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/syspathcontext.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/tempdir.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/terminal.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/timing.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/tokenutil.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/IPython/utils/wildcard.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/LICENSE +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/README.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/_build_meta.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/Makefile +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/README.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/autogen_api.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/autogen_config.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/autogen_magics.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/autogen_shortcuts.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/make.cmd +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/man/ipython.1 +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/requirements.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/2.0/running-crop.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/2.0/running.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/2.0/treeview.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/2.0/user-interface.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/2.0/widgets.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_1_prompt_no_text.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_2_print_hello_suggest.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_3_print_hello_suggest.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_4_print_hello.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_d_completions.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_d_phantom.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_def_completions.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_def_phantom.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_match_parens.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/auto_suggest_second_prompt.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/8.0/pathlib_pathlib_everywhere.jpg +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/autosuggest.gif +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_dashboard.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_dashboard_cluster.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_cythonmagic.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_long_out.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_octavemagic.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_rmagic.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_script_cells.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_spectrogram.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_notebook_tooltip.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_par_tb.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_qtconsole_baboon.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipy_013_qtconsole_completer.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ipython-6-screenshot.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/jedi_type_inference_60.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/kernel_selector_screenshot.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ms_visual_studio.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/notebook_specgram.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/ptshell_features.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/qtconsole.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/qtconsole_tabbed.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_images/unicode_completion.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_static/favicon.ico +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_static/logo.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_static/theme_overrides.css +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_templates/breadcrumbs.html +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/_templates/notebook_redirect.html +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/about/history.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/about/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/about/license_and_copyright.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/api/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/conf.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/callbacks.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/custommagics.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/eventloops.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/extensions/autoreload.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/extensions/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/extensions/storemagic.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/inputtransforms.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/integrating.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/intro.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/options/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/shell_mimerenderer.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/config/shortcuts/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/coredev/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/config.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/execution.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/figs/ipy_kernel_and_terminal.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/figs/ipy_kernel_and_terminal.svg +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/figs/other_kernels.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/figs/other_kernels.svg +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/how_ipython_works.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/inputhook_app.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/kernels.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/messaging.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/pycompat.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/development/wrapperkernels.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/install/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/install/install.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/install/kernel_install.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/autoawait.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/magics.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/plotting.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/python-ipython-diff.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/shell.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/tips.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/interactive/tutorial.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/links.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/parallel/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/sphinx.toml +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/sphinxext.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-0.11.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-0.12.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-0.13.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-1.0.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-2.0.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-3.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-4.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-5.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-6.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-7.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/github-stats-8.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/index.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/pr/README.md +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/pr/antigravity-feature.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/pr/incompat-switching-to-perl.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version0.10.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version0.11.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version0.12.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version0.13.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version0.8.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version0.9.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version1.0.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version2.0.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version3.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version3_widget_migration.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version4.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version5.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version6.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version7.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/source/whatsnew/version8.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/sphinxext/apigen.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/sphinxext/configtraits.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/sphinxext/github.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/docs/sphinxext/magics.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/Embedding/embed_class_long.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/Embedding/embed_class_short.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/Embedding/embed_function.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/Embedding/start_ipython_config.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/example-demo.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/gui/gui-glut.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/gui/gui-gtk4.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/gui/gui-qt.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/ipython-completion.bash +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/ipython-get-history.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/IPython Kernel/ipython.desktop +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/auto_suggest_llm.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/utils/cwd_prompt.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/utils/list_pyfiles.ipy +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/examples/utils/list_subdirs.ipy +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/ipython.egg-info/SOURCES.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/ipython.egg-info/dependency_links.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/ipython.egg-info/entry_points.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/ipython.egg-info/not-zip-safe +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/ipython.egg-info/top_level.txt +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/long_description.rst +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/scripts/ipython.ico +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/scripts/ipython_nb.ico +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/setup.cfg +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/setup.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/setupbase.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/2x2.jpg +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/2x2.png +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/__init__.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/bad_all.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/conftest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/cve.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/fake_ext_dir/daft_extension.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/fake_llm.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/nonascii.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/nonascii2.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/print_argv.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/refbug.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/simpleerr.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/tclass.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test.wav +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_alias.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_application.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_async_helpers.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_autocall.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_backgroundjobs.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_capture.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_clipboard.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_compilerop.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_completerlib.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_decorators.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_decorators_2.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_deepreload.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_dir2.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_display.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_displayhook.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_editorhooks.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_embed.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_events.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_exceptiongroup_tb.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_extension.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_handlers.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_help.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_history.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_hooks.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_imports.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_importstring.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_inputtransformer2.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_inputtransformer2_line.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_interactivshell.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_io.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_iplib.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_ipunittest.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_latextools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_logger.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_magic_arguments.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_magic_terminal.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_module_paths.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_oinspect.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_openpy.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_page.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_path.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_paths.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_prefilter.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_pretty.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_process.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_profile.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_pt_inputhooks.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_pycolorize.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_pylabtools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_qt_loaders.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_shellapp.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_shortcuts.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_splitinput.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_storemagic.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_sysinfo.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_tempdir.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_text.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_tips.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_tokenutil.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_tools.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_wildcard.py +0 -0
- {ipython-9.5.0 → ipython-9.7.0}/tests/test_zzz_autoreload.py +0 -0
|
@@ -218,7 +218,7 @@ from IPython.core.guarded_eval import (
|
|
|
218
218
|
EvaluationContext,
|
|
219
219
|
_validate_policy_overrides,
|
|
220
220
|
)
|
|
221
|
-
from IPython.core.error import TryNext
|
|
221
|
+
from IPython.core.error import TryNext, UsageError
|
|
222
222
|
from IPython.core.inputtransformer2 import ESC_MAGIC
|
|
223
223
|
from IPython.core.latex_symbols import latex_symbols, reverse_latex_symbol
|
|
224
224
|
from IPython.testing.skipdoctest import skip_doctest
|
|
@@ -1127,7 +1127,7 @@ class Completer(Configurable):
|
|
|
1127
1127
|
except IndexError:
|
|
1128
1128
|
return None
|
|
1129
1129
|
|
|
1130
|
-
def global_matches(self, text):
|
|
1130
|
+
def global_matches(self, text: str, context: Optional[CompletionContext] = None):
|
|
1131
1131
|
"""Compute matches when text is a simple name.
|
|
1132
1132
|
|
|
1133
1133
|
Return a list of all keywords, built-in functions and names currently
|
|
@@ -1137,12 +1137,41 @@ class Completer(Configurable):
|
|
|
1137
1137
|
matches = []
|
|
1138
1138
|
match_append = matches.append
|
|
1139
1139
|
n = len(text)
|
|
1140
|
-
|
|
1140
|
+
|
|
1141
|
+
search_lists = [
|
|
1141
1142
|
keyword.kwlist,
|
|
1142
1143
|
builtin_mod.__dict__.keys(),
|
|
1143
1144
|
list(self.namespace.keys()),
|
|
1144
1145
|
list(self.global_namespace.keys()),
|
|
1145
|
-
]
|
|
1146
|
+
]
|
|
1147
|
+
if context and context.full_text.count("\n") > 1:
|
|
1148
|
+
# try to evaluate on full buffer
|
|
1149
|
+
previous_lines = "\n".join(
|
|
1150
|
+
context.full_text.split("\n")[: context.cursor_line]
|
|
1151
|
+
)
|
|
1152
|
+
if previous_lines:
|
|
1153
|
+
all_code_lines_before_cursor = (
|
|
1154
|
+
self._extract_code(previous_lines) + "\n" + text
|
|
1155
|
+
)
|
|
1156
|
+
context = EvaluationContext(
|
|
1157
|
+
globals=self.global_namespace,
|
|
1158
|
+
locals=self.namespace,
|
|
1159
|
+
evaluation=self.evaluation,
|
|
1160
|
+
auto_import=self._auto_import,
|
|
1161
|
+
policy_overrides=self.policy_overrides,
|
|
1162
|
+
)
|
|
1163
|
+
try:
|
|
1164
|
+
obj = guarded_eval(
|
|
1165
|
+
all_code_lines_before_cursor,
|
|
1166
|
+
context,
|
|
1167
|
+
)
|
|
1168
|
+
except Exception as e:
|
|
1169
|
+
if self.debug:
|
|
1170
|
+
warnings.warn(f"Evaluation exception {e}")
|
|
1171
|
+
|
|
1172
|
+
search_lists.append(list(context.transient_locals.keys()))
|
|
1173
|
+
|
|
1174
|
+
for lst in search_lists:
|
|
1146
1175
|
for word in lst:
|
|
1147
1176
|
if word[:n] == text and word != "__builtins__":
|
|
1148
1177
|
match_append(word)
|
|
@@ -1157,6 +1186,7 @@ class Completer(Configurable):
|
|
|
1157
1186
|
for word in shortened.keys():
|
|
1158
1187
|
if word[:n] == text and word != "__builtins__":
|
|
1159
1188
|
match_append(shortened[word])
|
|
1189
|
+
|
|
1160
1190
|
return matches
|
|
1161
1191
|
|
|
1162
1192
|
def attr_matches(self, text):
|
|
@@ -1219,8 +1249,15 @@ class Completer(Configurable):
|
|
|
1219
1249
|
else:
|
|
1220
1250
|
return code
|
|
1221
1251
|
|
|
1252
|
+
def _extract_code(self, line: str):
|
|
1253
|
+
"""No-op in Completer, but can be used in subclasses to customise behaviour"""
|
|
1254
|
+
return line
|
|
1255
|
+
|
|
1222
1256
|
def _attr_matches(
|
|
1223
|
-
self,
|
|
1257
|
+
self,
|
|
1258
|
+
text: str,
|
|
1259
|
+
include_prefix: bool = True,
|
|
1260
|
+
context: Optional[CompletionContext] = None,
|
|
1224
1261
|
) -> tuple[Sequence[str], str]:
|
|
1225
1262
|
m2 = self._ATTR_MATCH_RE.match(text)
|
|
1226
1263
|
if not m2:
|
|
@@ -1233,7 +1270,19 @@ class Completer(Configurable):
|
|
|
1233
1270
|
|
|
1234
1271
|
obj = self._evaluate_expr(expr)
|
|
1235
1272
|
if obj is not_found:
|
|
1236
|
-
|
|
1273
|
+
if context:
|
|
1274
|
+
# try to evaluate on full buffer
|
|
1275
|
+
previous_lines = "\n".join(
|
|
1276
|
+
context.full_text.split("\n")[: context.cursor_line]
|
|
1277
|
+
)
|
|
1278
|
+
if previous_lines:
|
|
1279
|
+
all_code_lines_before_cursor = (
|
|
1280
|
+
self._extract_code(previous_lines) + "\n" + expr
|
|
1281
|
+
)
|
|
1282
|
+
obj = self._evaluate_expr(all_code_lines_before_cursor)
|
|
1283
|
+
|
|
1284
|
+
if obj is not_found:
|
|
1285
|
+
return [], ""
|
|
1237
1286
|
|
|
1238
1287
|
if self.limit_to__all__ and hasattr(obj, '__all__'):
|
|
1239
1288
|
words = get__all__entries(obj)
|
|
@@ -1327,7 +1376,9 @@ class Completer(Configurable):
|
|
|
1327
1376
|
),
|
|
1328
1377
|
)
|
|
1329
1378
|
done = True
|
|
1330
|
-
except (SyntaxError, TypeError):
|
|
1379
|
+
except (SyntaxError, TypeError) as e:
|
|
1380
|
+
if self.debug:
|
|
1381
|
+
warnings.warn(f"Trimming because of {e}")
|
|
1331
1382
|
# TypeError can show up with something like `+ d`
|
|
1332
1383
|
# where `d` is a dictionary.
|
|
1333
1384
|
|
|
@@ -1338,8 +1389,10 @@ class Completer(Configurable):
|
|
|
1338
1389
|
expr = self._trim_expr(expr)
|
|
1339
1390
|
except Exception as e:
|
|
1340
1391
|
if self.debug:
|
|
1341
|
-
|
|
1392
|
+
warnings.warn(f"Evaluation exception {e}")
|
|
1342
1393
|
done = True
|
|
1394
|
+
if self.debug:
|
|
1395
|
+
warnings.warn(f"Resolved to {obj}")
|
|
1343
1396
|
return obj
|
|
1344
1397
|
|
|
1345
1398
|
@property
|
|
@@ -2244,6 +2297,57 @@ class IPCompleter(Completer):
|
|
|
2244
2297
|
"suppress": False,
|
|
2245
2298
|
}
|
|
2246
2299
|
|
|
2300
|
+
def _extract_code(self, line: str) -> str:
|
|
2301
|
+
"""Extract code from magics if any."""
|
|
2302
|
+
|
|
2303
|
+
if not line:
|
|
2304
|
+
return line
|
|
2305
|
+
maybe_magic, *rest = line.split(maxsplit=1)
|
|
2306
|
+
if not rest:
|
|
2307
|
+
return line
|
|
2308
|
+
args = rest[0]
|
|
2309
|
+
known_magics = self.shell.magics_manager.lsmagic()
|
|
2310
|
+
line_magics = known_magics["line"]
|
|
2311
|
+
magic_name = maybe_magic.lstrip(self.magic_escape)
|
|
2312
|
+
if magic_name not in line_magics:
|
|
2313
|
+
return line
|
|
2314
|
+
|
|
2315
|
+
if not maybe_magic.startswith(self.magic_escape):
|
|
2316
|
+
all_variables = [*self.namespace.keys(), *self.global_namespace.keys()]
|
|
2317
|
+
if magic_name in all_variables:
|
|
2318
|
+
# short circuit if we see a line starting with say `time`
|
|
2319
|
+
# but time is defined as a variable (in addition to being
|
|
2320
|
+
# a magic). In these cases users need to use explicit `%time`.
|
|
2321
|
+
return line
|
|
2322
|
+
|
|
2323
|
+
magic_method = line_magics[magic_name]
|
|
2324
|
+
|
|
2325
|
+
try:
|
|
2326
|
+
if magic_name == "timeit":
|
|
2327
|
+
opts, stmt = magic_method.__self__.parse_options(
|
|
2328
|
+
args,
|
|
2329
|
+
"n:r:tcp:qov:",
|
|
2330
|
+
posix=False,
|
|
2331
|
+
strict=False,
|
|
2332
|
+
preserve_non_opts=True,
|
|
2333
|
+
)
|
|
2334
|
+
return stmt
|
|
2335
|
+
elif magic_name == "prun":
|
|
2336
|
+
opts, stmt = magic_method.__self__.parse_options(
|
|
2337
|
+
args, "D:l:rs:T:q", list_all=True, posix=False
|
|
2338
|
+
)
|
|
2339
|
+
return stmt
|
|
2340
|
+
elif hasattr(magic_method, "parser") and getattr(
|
|
2341
|
+
magic_method, "has_arguments", False
|
|
2342
|
+
):
|
|
2343
|
+
# e.g. %debug, %time
|
|
2344
|
+
args, extra = magic_method.parser.parse_argstring(args, partial=True)
|
|
2345
|
+
return " ".join(extra)
|
|
2346
|
+
except UsageError:
|
|
2347
|
+
return line
|
|
2348
|
+
|
|
2349
|
+
return line
|
|
2350
|
+
|
|
2247
2351
|
@context_matcher()
|
|
2248
2352
|
def magic_matcher(self, context: CompletionContext) -> SimpleMatcherResult:
|
|
2249
2353
|
"""Match magics."""
|
|
@@ -2255,7 +2359,7 @@ class IPCompleter(Completer):
|
|
|
2255
2359
|
line_magics = lsm['line']
|
|
2256
2360
|
cell_magics = lsm['cell']
|
|
2257
2361
|
pre = self.magic_escape
|
|
2258
|
-
pre2 = pre+pre
|
|
2362
|
+
pre2 = pre + pre
|
|
2259
2363
|
|
|
2260
2364
|
explicit_magic = text.startswith(pre)
|
|
2261
2365
|
|
|
@@ -2377,7 +2481,7 @@ class IPCompleter(Completer):
|
|
|
2377
2481
|
return {
|
|
2378
2482
|
"completions": matches,
|
|
2379
2483
|
# static analysis should not suppress other matchers
|
|
2380
|
-
"suppress": False,
|
|
2484
|
+
"suppress": {_get_matcher_id(self.file_matcher)} if matches else False,
|
|
2381
2485
|
}
|
|
2382
2486
|
|
|
2383
2487
|
def _jedi_matches(
|
|
@@ -2619,10 +2723,13 @@ class IPCompleter(Completer):
|
|
|
2619
2723
|
def python_matcher(self, context: CompletionContext) -> SimpleMatcherResult:
|
|
2620
2724
|
"""Match attributes or global python names"""
|
|
2621
2725
|
text = context.text_until_cursor
|
|
2726
|
+
text = self._extract_code(text)
|
|
2622
2727
|
completion_type = self._determine_completion_context(text)
|
|
2623
2728
|
if completion_type == self._CompletionContextType.ATTRIBUTE:
|
|
2624
2729
|
try:
|
|
2625
|
-
matches, fragment = self._attr_matches(
|
|
2730
|
+
matches, fragment = self._attr_matches(
|
|
2731
|
+
text, include_prefix=False, context=context
|
|
2732
|
+
)
|
|
2626
2733
|
if text.endswith(".") and self.omit__names:
|
|
2627
2734
|
if self.omit__names == 1:
|
|
2628
2735
|
# true if txt is _not_ a __ name, false otherwise:
|
|
@@ -2634,14 +2741,20 @@ class IPCompleter(Completer):
|
|
|
2634
2741
|
is None
|
|
2635
2742
|
)
|
|
2636
2743
|
matches = filter(no__name, matches)
|
|
2637
|
-
|
|
2744
|
+
matches = _convert_matcher_v1_result_to_v2(
|
|
2638
2745
|
matches, type="attribute", fragment=fragment
|
|
2639
2746
|
)
|
|
2747
|
+
if matches["completions"]:
|
|
2748
|
+
matches["suppress"] = {_get_matcher_id(self.file_matcher)}
|
|
2749
|
+
return matches
|
|
2640
2750
|
except NameError:
|
|
2641
2751
|
# catches <undefined attributes>.<tab>
|
|
2642
2752
|
return SimpleMatcherResult(completions=[], suppress=False)
|
|
2643
2753
|
else:
|
|
2644
|
-
|
|
2754
|
+
try:
|
|
2755
|
+
matches = self.global_matches(context.token, context=context)
|
|
2756
|
+
except TypeError:
|
|
2757
|
+
matches = self.global_matches(context.token)
|
|
2645
2758
|
# TODO: maybe distinguish between functions, modules and just "variables"
|
|
2646
2759
|
return SimpleMatcherResult(
|
|
2647
2760
|
completions=[
|
|
@@ -3476,7 +3589,7 @@ class IPCompleter(Completer):
|
|
|
3476
3589
|
full_text=full_text,
|
|
3477
3590
|
cursor_position=cursor_pos,
|
|
3478
3591
|
cursor_line=cursor_line,
|
|
3479
|
-
token=text,
|
|
3592
|
+
token=self._extract_code(text),
|
|
3480
3593
|
limit=MATCHES_LIMIT,
|
|
3481
3594
|
)
|
|
3482
3595
|
|
|
@@ -1107,6 +1107,21 @@ class Pdb(OldPdb):
|
|
|
1107
1107
|
]
|
|
1108
1108
|
)
|
|
1109
1109
|
)
|
|
1110
|
+
if self.skip and self.is_skipped_module(frame.f_globals.get("__name__", "")):
|
|
1111
|
+
print(
|
|
1112
|
+
self.theme.format(
|
|
1113
|
+
[
|
|
1114
|
+
(
|
|
1115
|
+
Token.ExcName,
|
|
1116
|
+
" [... skipped 1 ignored module(s)]",
|
|
1117
|
+
),
|
|
1118
|
+
(Token, "\n"),
|
|
1119
|
+
]
|
|
1120
|
+
)
|
|
1121
|
+
)
|
|
1122
|
+
|
|
1123
|
+
return False
|
|
1124
|
+
|
|
1110
1125
|
return super().stop_here(frame)
|
|
1111
1126
|
|
|
1112
1127
|
def do_up(self, arg):
|
|
@@ -1114,10 +1129,10 @@ class Pdb(OldPdb):
|
|
|
1114
1129
|
Move the current frame count (default one) levels up in the
|
|
1115
1130
|
stack trace (to an older frame).
|
|
1116
1131
|
|
|
1117
|
-
Will skip hidden frames.
|
|
1132
|
+
Will skip hidden frames and ignored modules.
|
|
1118
1133
|
"""
|
|
1119
1134
|
# modified version of upstream that skips
|
|
1120
|
-
# frames with __tracebackhide__
|
|
1135
|
+
# frames with __tracebackhide__ and ignored modules
|
|
1121
1136
|
if self.curindex == 0:
|
|
1122
1137
|
self.error("Oldest frame")
|
|
1123
1138
|
return
|
|
@@ -1126,15 +1141,27 @@ class Pdb(OldPdb):
|
|
|
1126
1141
|
except ValueError:
|
|
1127
1142
|
self.error("Invalid frame count (%s)" % arg)
|
|
1128
1143
|
return
|
|
1129
|
-
|
|
1144
|
+
|
|
1145
|
+
hidden_skipped = 0
|
|
1146
|
+
module_skipped = 0
|
|
1147
|
+
|
|
1130
1148
|
if count < 0:
|
|
1131
1149
|
_newframe = 0
|
|
1132
1150
|
else:
|
|
1133
1151
|
counter = 0
|
|
1134
1152
|
hidden_frames = self.hidden_frames(self.stack)
|
|
1153
|
+
|
|
1135
1154
|
for i in range(self.curindex - 1, -1, -1):
|
|
1136
|
-
|
|
1137
|
-
|
|
1155
|
+
should_skip_hidden = hidden_frames[i] and self.skip_hidden
|
|
1156
|
+
should_skip_module = self.skip and self.is_skipped_module(
|
|
1157
|
+
self.stack[i][0].f_globals.get("__name__", "")
|
|
1158
|
+
)
|
|
1159
|
+
|
|
1160
|
+
if should_skip_hidden or should_skip_module:
|
|
1161
|
+
if should_skip_hidden:
|
|
1162
|
+
hidden_skipped += 1
|
|
1163
|
+
if should_skip_module:
|
|
1164
|
+
module_skipped += 1
|
|
1138
1165
|
continue
|
|
1139
1166
|
counter += 1
|
|
1140
1167
|
if counter >= count:
|
|
@@ -1142,19 +1169,21 @@ class Pdb(OldPdb):
|
|
|
1142
1169
|
else:
|
|
1143
1170
|
# if no break occurred.
|
|
1144
1171
|
self.error(
|
|
1145
|
-
"all frames above hidden
|
|
1172
|
+
"all frames above skipped (hidden frames and ignored modules). Use `skip_hidden False` for hidden frames or unignore_module for ignored modules."
|
|
1146
1173
|
)
|
|
1147
1174
|
return
|
|
1148
1175
|
|
|
1149
1176
|
_newframe = i
|
|
1150
1177
|
self._select_frame(_newframe)
|
|
1151
|
-
|
|
1178
|
+
|
|
1179
|
+
total_skipped = hidden_skipped + module_skipped
|
|
1180
|
+
if total_skipped:
|
|
1152
1181
|
print(
|
|
1153
1182
|
self.theme.format(
|
|
1154
1183
|
[
|
|
1155
1184
|
(
|
|
1156
1185
|
Token.ExcName,
|
|
1157
|
-
f" [... skipped {
|
|
1186
|
+
f" [... skipped {total_skipped} frame(s): {hidden_skipped} hidden frames + {module_skipped} ignored modules]",
|
|
1158
1187
|
),
|
|
1159
1188
|
(Token, "\n"),
|
|
1160
1189
|
]
|
|
@@ -1166,7 +1195,7 @@ class Pdb(OldPdb):
|
|
|
1166
1195
|
Move the current frame count (default one) levels down in the
|
|
1167
1196
|
stack trace (to a newer frame).
|
|
1168
1197
|
|
|
1169
|
-
Will skip hidden frames.
|
|
1198
|
+
Will skip hidden frames and ignored modules.
|
|
1170
1199
|
"""
|
|
1171
1200
|
if self.curindex + 1 == len(self.stack):
|
|
1172
1201
|
self.error("Newest frame")
|
|
@@ -1180,28 +1209,39 @@ class Pdb(OldPdb):
|
|
|
1180
1209
|
_newframe = len(self.stack) - 1
|
|
1181
1210
|
else:
|
|
1182
1211
|
counter = 0
|
|
1183
|
-
|
|
1212
|
+
hidden_skipped = 0
|
|
1213
|
+
module_skipped = 0
|
|
1184
1214
|
hidden_frames = self.hidden_frames(self.stack)
|
|
1215
|
+
|
|
1185
1216
|
for i in range(self.curindex + 1, len(self.stack)):
|
|
1186
|
-
|
|
1187
|
-
|
|
1217
|
+
should_skip_hidden = hidden_frames[i] and self.skip_hidden
|
|
1218
|
+
should_skip_module = self.skip and self.is_skipped_module(
|
|
1219
|
+
self.stack[i][0].f_globals.get("__name__", "")
|
|
1220
|
+
)
|
|
1221
|
+
|
|
1222
|
+
if should_skip_hidden or should_skip_module:
|
|
1223
|
+
if should_skip_hidden:
|
|
1224
|
+
hidden_skipped += 1
|
|
1225
|
+
if should_skip_module:
|
|
1226
|
+
module_skipped += 1
|
|
1188
1227
|
continue
|
|
1189
1228
|
counter += 1
|
|
1190
1229
|
if counter >= count:
|
|
1191
1230
|
break
|
|
1192
1231
|
else:
|
|
1193
1232
|
self.error(
|
|
1194
|
-
"all frames below hidden
|
|
1233
|
+
"all frames below skipped (hidden frames and ignored modules). Use `skip_hidden False` for hidden frames or unignore_module for ignored modules."
|
|
1195
1234
|
)
|
|
1196
1235
|
return
|
|
1197
1236
|
|
|
1198
|
-
|
|
1237
|
+
total_skipped = hidden_skipped + module_skipped
|
|
1238
|
+
if total_skipped:
|
|
1199
1239
|
print(
|
|
1200
1240
|
self.theme.format(
|
|
1201
1241
|
[
|
|
1202
1242
|
(
|
|
1203
1243
|
Token.ExcName,
|
|
1204
|
-
f" [... skipped {
|
|
1244
|
+
f" [... skipped {total_skipped} frame(s): {hidden_skipped} hidden frames + {module_skipped} ignored modules]",
|
|
1205
1245
|
),
|
|
1206
1246
|
(Token, "\n"),
|
|
1207
1247
|
]
|
|
@@ -1214,6 +1254,67 @@ class Pdb(OldPdb):
|
|
|
1214
1254
|
do_d = do_down
|
|
1215
1255
|
do_u = do_up
|
|
1216
1256
|
|
|
1257
|
+
def _show_ignored_modules(self):
|
|
1258
|
+
"""Display currently ignored modules."""
|
|
1259
|
+
if self.skip:
|
|
1260
|
+
print(f"Currently ignored modules: {sorted(self.skip)}")
|
|
1261
|
+
else:
|
|
1262
|
+
print("No modules are currently ignored.")
|
|
1263
|
+
|
|
1264
|
+
def do_ignore_module(self, arg):
|
|
1265
|
+
"""ignore_module <module_name>
|
|
1266
|
+
|
|
1267
|
+
Add a module to the list of modules to skip when navigating frames.
|
|
1268
|
+
When a module is ignored, the debugger will automatically skip over
|
|
1269
|
+
frames from that module.
|
|
1270
|
+
|
|
1271
|
+
Supports wildcard patterns using fnmatch syntax:
|
|
1272
|
+
|
|
1273
|
+
Usage:
|
|
1274
|
+
ignore_module threading # Skip threading module frames
|
|
1275
|
+
ignore_module asyncio.\\* # Skip all asyncio submodules
|
|
1276
|
+
ignore_module \\*.tests # Skip all test modules
|
|
1277
|
+
ignore_module # List currently ignored modules
|
|
1278
|
+
"""
|
|
1279
|
+
|
|
1280
|
+
if self.skip is None:
|
|
1281
|
+
self.skip = set()
|
|
1282
|
+
|
|
1283
|
+
module_name = arg.strip()
|
|
1284
|
+
|
|
1285
|
+
if not module_name:
|
|
1286
|
+
self._show_ignored_modules()
|
|
1287
|
+
return
|
|
1288
|
+
|
|
1289
|
+
self.skip.add(module_name)
|
|
1290
|
+
|
|
1291
|
+
def do_unignore_module(self, arg):
|
|
1292
|
+
"""unignore_module <module_name>
|
|
1293
|
+
|
|
1294
|
+
Remove a module from the list of modules to skip when navigating frames.
|
|
1295
|
+
This will allow the debugger to step into frames from the specified module.
|
|
1296
|
+
|
|
1297
|
+
Usage:
|
|
1298
|
+
unignore_module threading # Stop ignoring threading module frames
|
|
1299
|
+
unignore_module asyncio.\\* # Remove asyncio.* pattern
|
|
1300
|
+
unignore_module # List currently ignored modules
|
|
1301
|
+
"""
|
|
1302
|
+
|
|
1303
|
+
if self.skip is None:
|
|
1304
|
+
self.skip = set()
|
|
1305
|
+
|
|
1306
|
+
module_name = arg.strip()
|
|
1307
|
+
|
|
1308
|
+
if not module_name:
|
|
1309
|
+
self._show_ignored_modules()
|
|
1310
|
+
return
|
|
1311
|
+
|
|
1312
|
+
try:
|
|
1313
|
+
self.skip.remove(module_name)
|
|
1314
|
+
except KeyError:
|
|
1315
|
+
print(f"Module {module_name} is not currently ignored")
|
|
1316
|
+
self._show_ignored_modules()
|
|
1317
|
+
|
|
1217
1318
|
def do_context(self, context: str):
|
|
1218
1319
|
"""context number_of_lines
|
|
1219
1320
|
Set the number of lines of source code to show when displaying
|
|
@@ -43,6 +43,9 @@ class DisplayPublisher(Configurable):
|
|
|
43
43
|
def __init__(self, shell=None, *args, **kwargs):
|
|
44
44
|
self.shell = shell
|
|
45
45
|
self._is_publishing = False
|
|
46
|
+
self._in_post_execute = False
|
|
47
|
+
if self.shell:
|
|
48
|
+
self._setup_execution_tracking()
|
|
46
49
|
super().__init__(*args, **kwargs)
|
|
47
50
|
|
|
48
51
|
def _validate_data(self, data, metadata=None):
|
|
@@ -62,6 +65,19 @@ class DisplayPublisher(Configurable):
|
|
|
62
65
|
if not isinstance(metadata, dict):
|
|
63
66
|
raise TypeError("metadata must be a dict, got: %r" % data)
|
|
64
67
|
|
|
68
|
+
def _setup_execution_tracking(self):
|
|
69
|
+
"""Set up hooks to track execution state"""
|
|
70
|
+
self.shell.events.register("post_execute", self._on_post_execute)
|
|
71
|
+
self.shell.events.register("pre_execute", self._on_pre_execute)
|
|
72
|
+
|
|
73
|
+
def _on_post_execute(self):
|
|
74
|
+
"""Called at start of post_execute phase"""
|
|
75
|
+
self._in_post_execute = True
|
|
76
|
+
|
|
77
|
+
def _on_pre_execute(self):
|
|
78
|
+
"""Called at start of pre_execute phase"""
|
|
79
|
+
self._in_post_execute = False
|
|
80
|
+
|
|
65
81
|
# use * to indicate transient, update are keyword-only
|
|
66
82
|
def publish(
|
|
67
83
|
self,
|
|
@@ -133,7 +149,13 @@ class DisplayPublisher(Configurable):
|
|
|
133
149
|
|
|
134
150
|
outputs = self.shell.history_manager.outputs
|
|
135
151
|
|
|
136
|
-
|
|
152
|
+
target_execution_count = self.shell.execution_count
|
|
153
|
+
if self._in_post_execute:
|
|
154
|
+
# We're in post_execute, so this is likely a matplotlib flush
|
|
155
|
+
# Use execution_count - 1 to associate with the cell that created the plot
|
|
156
|
+
target_execution_count = self.shell.execution_count - 1
|
|
157
|
+
|
|
158
|
+
outputs[target_execution_count].append(
|
|
137
159
|
HistoryOutput(output_type="display_data", bundle=data)
|
|
138
160
|
)
|
|
139
161
|
|