diff --git a/buildstream/_yaml.py b/buildstream/_yaml.py index 7e12183e3f4218010689bec141bda8a7b2b1e760..230094c2265c22fb7ce0fec3a5789407493ed2f9 100644 --- a/buildstream/_yaml.py +++ b/buildstream/_yaml.py @@ -940,7 +940,7 @@ def node_sanitize(node): return [node_sanitize(elt) for elt in node] # Finally ChainMap and dict, and other Mappings need special handling - if node_type in (dict, ChainMap) or isinstance(node, collections.Mapping): + if node_type in (dict, ChainMap) or isinstance(node, collections.abc.Mapping): result = SanitizedDict() key_list = [key for key, _ in node_items(node)]