From e34111cc355bd2c9448746130bd3aa4df5241613 Mon Sep 17 00:00:00 2001 From: Isaiah Akorita Date: Tue, 3 Dec 2024 15:04:30 +0100 Subject: [PATCH] check cmap type before comparing to categories --- hvplot/converter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hvplot/converter.py b/hvplot/converter.py index 9aadbc358..7802475e6 100644 --- a/hvplot/converter.py +++ b/hvplot/converter.py @@ -1485,7 +1485,7 @@ def _process_style(self, kwds, plot_opts): if 'color' in style_opts: color = style_opts['color'] elif not isinstance(cmap, dict): - if cmap and any(c in cmap for c in categories): + if isinstance(cmap, str) and any(c in cmap for c in categories): color = process_cmap(cmap or self._default_cmaps['categorical'], categorical=True) else: color = cmap