diff --git a/spyder/utils/ipython/spyder_kernel.py b/spyder/utils/ipython/spyder_kernel.py index 421482ba421..d4423a02681 100644 --- a/spyder/utils/ipython/spyder_kernel.py +++ b/spyder/utils/ipython/spyder_kernel.py @@ -65,6 +65,7 @@ def __init__(self, *args, **kwargs): self.namespace_view_settings = {} self._pdb_obj = None self._pdb_step = None + self._publish_data = False kernel_config = self.config.get('IPKernelApp', None) if kernel_config is not None: @@ -157,6 +158,7 @@ def get_value(self, name): # petitions to display a value value = None publish_data({'__spy_data__': value}) + self._publish_data = True def set_value(self, name, value): """Set the value of a variable""" @@ -212,11 +214,12 @@ def publish_pdb_state(self): Publish Variable Explorer state and Pdb step through publish_data. """ - if self._pdb_obj: + if self._pdb_obj and not self._publish_data: state = dict(namespace_view = self.get_namespace_view(), var_properties = self.get_var_properties(), step = self._pdb_step) publish_data({'__spy_pdb_state__': state}) + self._publish_data = False def pdb_continue(self): """