diff --git a/holoviews/core/spaces.py b/holoviews/core/spaces.py index 9ea540f906..7ae788b980 100644 --- a/holoviews/core/spaces.py +++ b/holoviews/core/spaces.py @@ -539,9 +539,9 @@ def clone(self, callable=None, **overrides): def __call__(self, *args, **kwargs): # Nothing to do for callbacks that accept no arguments - kwarg_hash = kwargs.pop('memoization_hash', ()) + kwarg_hash = kwargs.pop('_memoization_hash_', ()) (self.args, self.kwargs) = (args, kwargs) - if not args and not kwargs: return self.callable() + if not args and not kwargs and not any(kwarg_hash): return self.callable() inputs = [i for i in self.inputs if isinstance(i, DynamicMap)] streams = [] for stream in [s for i in inputs for s in get_nested_streams(i)]: @@ -905,7 +905,7 @@ def _execute_callback(self, *args): else: kwargs = dict(flattened) if not isinstance(self.callback, Generator): - kwargs['memoization_hash'] = hash_items + kwargs['_memoization_hash_'] = hash_items with dynamicmap_memoization(self.callback, self.streams): retval = self.callback(*args, **kwargs) diff --git a/holoviews/tests/teststreams.py b/holoviews/tests/teststreams.py index 43b392dacb..42cc86074c 100644 --- a/holoviews/tests/teststreams.py +++ b/holoviews/tests/teststreams.py @@ -172,6 +172,7 @@ def test_class_value_update(self): + class TestSubscribers(ComparisonTestCase): def test_exception_subscriber(self):