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
Inject display into builtins #10596
Inject display into builtins #10596
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,6 +56,7 @@ | |
from IPython.core.prefilter import PrefilterManager | ||
from IPython.core.profiledir import ProfileDir | ||
from IPython.core.usage import default_banner | ||
from IPython.display import display | ||
from IPython.testing.skipdoctest import skip_doctest | ||
from IPython.utils import PyColorize | ||
from IPython.utils import io | ||
|
@@ -618,6 +619,7 @@ def init_builtins(self): | |
# removing on exit or representing the existence of more than one | ||
# IPython at a time. | ||
builtin_mod.__dict__['__IPYTHON__'] = True | ||
builtin_mod.__dict__['display'] = display | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. away we go! There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Makes sense, I'll enter a Github issue in PixieDust repo There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Thanks ! Or, if we can figure out a way to use IPython machinery for pixeldust (as we already have dispatch per object types) that would be great. Feel free to crosslink here or ping me. |
||
|
||
self.builtin_trap = BuiltinTrap(shell=self) | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice bug fix!
display_id=1
would have always generated a new ID for this.