File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
notebook/services/kernels Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -178,17 +178,18 @@ def on_timeout():
178178 # Nudge the kernel with kernel info requests until we get an IOPub message
179179 def nudge (count ):
180180 count += 1
181+ nonlocal nudge_handle
181182 if not future .done ():
182- self .log .debug ("Nudging attempt %s or kernel %s" % (count , self .kernel_id ))
183+ log = self .log .warning if count % 10 == 0 else self .log .debug
184+ log ("Nudging attempt %s on kernel %s" % (count , self .kernel_id ))
183185 self .session .send (shell_channel , "kernel_info_request" )
184186 nudge_handle = loop .call_later (0.5 , nudge , count )
185187
186- nudge_count = 0
187- nudge_handle = loop .call_later (0 , nudge , nudge_count )
188+ nudge_handle = loop .call_later (0 , nudge , count = 0 )
188189
189190 timeout = loop .add_timeout (loop .time () + self .kernel_info_timeout , on_timeout )
190191 return future
191-
192+
192193 def request_kernel_info (self ):
193194 """send a request for kernel_info"""
194195 km = self .kernel_manager
You can’t perform that action at this time.
0 commit comments