[docs]defrecursive_merge(d1:JSON_DICT_TYPE,d2:JSON_DICT_TYPE)->JSON_DICT_TYPE:""" Update two dicts of dicts recursively, if either mapping has leaves that are non-dicts, the second's leaf overwrites the first's. """fork,vind1.items():ifkind2andall(isinstance(e,MutableMapping)forein(v,d2[k])):d2[k]=recursive_merge(v,d2[k])returnd1|d2
[docs]classCompositeMetaClass(type(commands.Cog),type(ABC)):""" This allows the metaclass used for proper type detection to coexist with discord.py's metaclass """