Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion homeassistant/components/smartthings/climate.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
"""Support for climate devices through the SmartThings cloud API."""
import asyncio
from collections.abc import Iterable
import logging
from typing import Iterable, Optional, Sequence
from typing import Optional, Sequence

from pysmartthings import Attribute, Capability

Expand Down
3 changes: 2 additions & 1 deletion homeassistant/helpers/template.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
"""Template helper methods for rendering strings with Home Assistant data."""
import base64
import collections.abc
from datetime import datetime
from functools import wraps
import json
Expand Down Expand Up @@ -503,7 +504,7 @@ def expand(hass: HomeAssistantType, *args: Any) -> Iterable[State]:
continue
elif isinstance(entity, State):
entity_id = entity.entity_id
elif isinstance(entity, Iterable):
elif isinstance(entity, collections.abc.Iterable):
search += entity
continue
else:
Expand Down
5 changes: 3 additions & 2 deletions homeassistant/scripts/check_config.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
"""Script to check the configuration file."""
import argparse
from collections import OrderedDict
from collections.abc import Mapping, Sequence
from glob import glob
import logging
import os
from typing import Any, Callable, Dict, List, Sequence, Tuple
from typing import Any, Callable, Dict, List, Tuple
from unittest.mock import patch

from homeassistant import bootstrap, core
Expand Down Expand Up @@ -252,7 +253,7 @@ def sort_dict_key(val):
indent_str = indent_count * " "
if listi or isinstance(layer, list):
indent_str = indent_str[:-1] + "-"
if isinstance(layer, Dict):
if isinstance(layer, Mapping):
for key, value in sorted(layer.items(), key=sort_dict_key):
if isinstance(value, (dict, list)):
print(indent_str, str(key) + ":", line_info(value, **kwargs))
Expand Down