File tree Expand file tree Collapse file tree 3 files changed +5
-43
lines changed Expand file tree Collapse file tree 3 files changed +5
-43
lines changed Original file line number Diff line number Diff line change @@ -35,24 +35,3 @@ def _handle_ipython():
35
35
load_ipython_extension (ip )
36
36
37
37
_handle_ipython ()
38
-
39
-
40
- # Workaround for the absence of a comm_info_[request/reply] shell message
41
- class CommInfo (Widget ):
42
- """CommInfo widgets are is typically instantiated by the front-end.
43
-
44
- As soon as it is instantiated, it sends the collection of valid comms, and
45
- kills itself. It is a workaround to the absence of comm_info shell
46
- message.
47
- """
48
-
49
- def __init__ (self , ** kwargs ):
50
- super (CommInfo , self ).__init__ (** kwargs )
51
- target_name = 'ipython.widget'
52
- comms = {
53
- k : dict (target_name = v .target_name )
54
- for (k , v ) in self .comm .kernel .comm_manager .comms .items ()
55
- if v is not self .comm and (v .target_name == target_name or target_name is None )
56
- }
57
- self .send (dict (comms = comms ))
58
- self .close ()
Original file line number Diff line number Diff line change @@ -635,30 +635,13 @@ define([
635
635
636
636
WidgetManager . prototype . _get_comm_info = function ( ) {
637
637
/**
638
- * Gets a promise for the open comms in the backend
638
+ * Gets a promise for the valid widget models.
639
639
*/
640
-
641
- // Version using the comm_list_[request/reply] shell message.
642
- /*var that = this;
643
- return new Promise(function(resolve, reject) {
644
- kernel.comm_info(function(msg) {
645
- resolve(msg['content']['comms']);
646
- });
647
- });*/
648
-
649
- // Workaround for absence of comm_list_[request/reply] shell message.
650
- // Create a new widget that gives the comm list and commits suicide.
651
640
var that = this ;
652
641
return this . _get_connected_kernel ( ) . then ( function ( kernel ) {
653
642
return new Promise ( function ( resolve , reject ) {
654
- var comm = kernel . comm_manager . new_comm ( 'ipython.widget' ,
655
- { 'widget_class' : 'ipywidgets.CommInfo' } ,
656
- 'comm_info' ) ;
657
- comm . on_msg ( function ( msg ) {
658
- var data = msg . content . data ;
659
- if ( data . content && data . method === 'custom' ) {
660
- resolve ( data . content . comms ) ;
661
- }
643
+ kernel . comm_info ( 'ipython.widget' , function ( msg ) {
644
+ resolve ( msg [ 'content' ] [ 'comms' ] ) ;
662
645
} ) ;
663
646
} ) ;
664
647
} ) ;
Original file line number Diff line number Diff line change @@ -276,8 +276,8 @@ def run(self):
276
276
277
277
setuptools_args = {}
278
278
install_requires = setuptools_args ['install_requires' ] = [
279
- 'ipython>=4.0.0dev0 ' ,
280
- 'ipykernel' ,
279
+ 'ipython>=4.0.0 ' ,
280
+ 'ipykernel>=4.1.0 ' ,
281
281
'traitlets' ,
282
282
'notebook' ,
283
283
]
You can’t perform that action at this time.
0 commit comments