Show More
@@ -34,6 +34,10 b' class Output(DOMWidget):' | |||
|
34 | 34 | print('prints to output widget')""" |
|
35 | 35 | _view_name = Unicode('OutputView', sync=True) |
|
36 | 36 | |
|
37 | def __init__(self, *args, **kwargs): | |
|
38 | super(Output, self).__init__(*args, **kwargs) | |
|
39 | self._ip = get_ipython() | |
|
40 | ||
|
37 | 41 | def clear_output(self, *pargs, **kwargs): |
|
38 | 42 | with self: |
|
39 | 43 | clear_output(*pargs, **kwargs) |
@@ -41,7 +45,7 b' class Output(DOMWidget):' | |||
|
41 | 45 | def __enter__(self): |
|
42 | 46 | """Called upon entering output widget context manager.""" |
|
43 | 47 | self._flush() |
|
44 |
kernel = |
|
|
48 | kernel = self._ip.kernel | |
|
45 | 49 | session = kernel.session |
|
46 | 50 | send = session.send |
|
47 | 51 | self._original_send = send |
General Comments 0
You need to be logged in to leave comments.
Login now