Skip to content

Instantly share code, notes, and snippets.

View campanelli-resonon's full-sized avatar

Mark B. Campanelli campanelli-resonon

View GitHub Profile
@campanelli-resonon
campanelli-resonon / spyder_console.py
Created April 24, 2019 20:39
Creating a Spyder-compatible kernel to run embedded within another Python app using IPython
"""Simple function for embedding an IPython kernel."""
import sys
from IPython.utils.frame import extract_module_locals
import ipykernel.kernelapp
from traitlets import Type
# Subclass the IPKernelApp, making it point to the SpyderKernel subclass of the IPython kernel.