From 4f1d17624fe1af3a315e59ebfd4fc8bfe06822fe Mon Sep 17 00:00:00 2001 From: Muhamed Fazal PS Date: Tue, 7 Jul 2026 17:42:20 +0530 Subject: [PATCH] fix: remove deprecation warning for map traces with locationmode="country names" With the release of plotly.js v4, the library will be changed. The deprecation warning can be removed as a result. Fixes #5628 --- plotly/graph_objs/_scattergeo.py | 9 --------- 1 file changed, 9 deletions(-) diff --git a/plotly/graph_objs/_scattergeo.py b/plotly/graph_objs/_scattergeo.py index 2c62519f0e..ad656ddfd2 100644 --- a/plotly/graph_objs/_scattergeo.py +++ b/plotly/graph_objs/_scattergeo.py @@ -1902,15 +1902,6 @@ def __init__( constructor must be a dict or an instance of :class:`plotly.graph_objs.Scattergeo`""") - if locationmode == "country names" and kwargs.get("_validate"): - warnings.warn( - "The library used by the *country names* `locationmode` option is changing in an upcoming version. " - "Country names in existing plots may not work in the new version. " - "To ensure consistent behavior, consider setting `locationmode` to *ISO-3*.", - DeprecationWarning, - stacklevel=5, - ) - self._skip_invalid = kwargs.pop("skip_invalid", False) self._validate = kwargs.pop("_validate", True)