Skip to content

Commit

Permalink
Import ABC from collections.abc for Python 3.10 compatibility.
Browse files Browse the repository at this point in the history
  • Loading branch information
tirkarthi authored and karlb committed May 12, 2022
1 parent 7367b46 commit cb815a6
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions raiden/utils/datastructures.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
import collections
from collections.abc import Mapping
from itertools import zip_longest
from typing import Iterable, Tuple


def merge_dict(to_update: dict, other_dict: dict) -> None:
"""merges b into a"""
for key, value in other_dict.items():
has_map = isinstance(value, collections.Mapping) and isinstance(
to_update.get(key, None), collections.Mapping
)
has_map = isinstance(value, Mapping) and isinstance(to_update.get(key, None), Mapping)

if has_map:
merge_dict(to_update[key], value)
Expand Down

0 comments on commit cb815a6

Please sign in to comment.