mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 12:47:08 +00:00
commit
7818c98c67
@ -159,7 +159,7 @@ jobs:
|
||||
git config --global user.email "pvizeli@syshack.ch"
|
||||
git config --global credential.helper store
|
||||
|
||||
echo "https://$(githubToken):x-oauth-basic@github.com > $HOME\.git-credentials
|
||||
echo "https://$(githubToken):x-oauth-basic@github.com" > $HOME\.git-credentials
|
||||
displayName: 'Install requirements'
|
||||
- script: |
|
||||
set -e
|
||||
|
@ -53,7 +53,6 @@ TYPE_SENSOR = PREFIX_TYPES + 'SENSOR'
|
||||
TYPE_DOOR = PREFIX_TYPES + 'DOOR'
|
||||
TYPE_TV = PREFIX_TYPES + 'TV'
|
||||
TYPE_SPEAKER = PREFIX_TYPES + 'SPEAKER'
|
||||
TYPE_MEDIA = PREFIX_TYPES + 'MEDIA'
|
||||
|
||||
SERVICE_REQUEST_SYNC = 'request_sync'
|
||||
HOMEGRAPH_URL = 'https://homegraph.googleapis.com/'
|
||||
@ -89,7 +88,7 @@ DOMAIN_TO_GOOGLE_TYPES = {
|
||||
input_boolean.DOMAIN: TYPE_SWITCH,
|
||||
light.DOMAIN: TYPE_LIGHT,
|
||||
lock.DOMAIN: TYPE_LOCK,
|
||||
media_player.DOMAIN: TYPE_MEDIA,
|
||||
media_player.DOMAIN: TYPE_SWITCH,
|
||||
scene.DOMAIN: TYPE_SCENE,
|
||||
script.DOMAIN: TYPE_SCENE,
|
||||
switch.DOMAIN: TYPE_SWITCH,
|
||||
|
@ -55,8 +55,7 @@ def setup_platform(hass, config, add_entities, discovery_info=None):
|
||||
|
||||
_LOGGER.warning(
|
||||
"The honeywell component is deprecated for EU (i.e. non-US) systems, "
|
||||
"this functionality will be removed in version 0.96.")
|
||||
_LOGGER.warning(
|
||||
"this functionality will be removed in version 0.96. "
|
||||
"Please switch to the evohome component, "
|
||||
"see: https://home-assistant.io/components/evohome")
|
||||
|
||||
|
@ -164,27 +164,28 @@ class ONVIFHassCamera(Camera):
|
||||
|
||||
system_date = dt_util.utcnow()
|
||||
device_time = await devicemgmt.GetSystemDateAndTime()
|
||||
cdate = device_time.UTCDateTime
|
||||
cam_date = dt.datetime(cdate.Date.Year, cdate.Date.Month,
|
||||
cdate.Date.Day, cdate.Time.Hour,
|
||||
cdate.Time.Minute, cdate.Time.Second,
|
||||
0, dt_util.UTC)
|
||||
if device_time:
|
||||
cdate = device_time.UTCDateTime
|
||||
cam_date = dt.datetime(cdate.Date.Year, cdate.Date.Month,
|
||||
cdate.Date.Day, cdate.Time.Hour,
|
||||
cdate.Time.Minute, cdate.Time.Second,
|
||||
0, dt_util.UTC)
|
||||
|
||||
_LOGGER.debug("Camera date/time: %s",
|
||||
cam_date)
|
||||
_LOGGER.debug("Camera date/time: %s",
|
||||
cam_date)
|
||||
|
||||
_LOGGER.debug("System date/time: %s",
|
||||
system_date)
|
||||
_LOGGER.debug("System date/time: %s",
|
||||
system_date)
|
||||
|
||||
dt_diff = cam_date - system_date
|
||||
dt_diff_seconds = dt_diff.total_seconds()
|
||||
dt_diff = cam_date - system_date
|
||||
dt_diff_seconds = dt_diff.total_seconds()
|
||||
|
||||
if dt_diff_seconds > 5:
|
||||
_LOGGER.warning("The date/time on the camera is '%s', "
|
||||
"which is different from the system '%s', "
|
||||
"this could lead to authentication issues",
|
||||
cam_date,
|
||||
system_date)
|
||||
if dt_diff_seconds > 5:
|
||||
_LOGGER.warning("The date/time on the camera is '%s', "
|
||||
"which is different from the system '%s', "
|
||||
"this could lead to authentication issues",
|
||||
cam_date,
|
||||
system_date)
|
||||
|
||||
_LOGGER.debug("Obtaining input uri")
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
"""Constants used by Home Assistant components."""
|
||||
MAJOR_VERSION = 0
|
||||
MINOR_VERSION = 93
|
||||
PATCH_VERSION = '0'
|
||||
PATCH_VERSION = '1'
|
||||
__short_version__ = '{}.{}'.format(MAJOR_VERSION, MINOR_VERSION)
|
||||
__version__ = '{}.{}'.format(__short_version__, PATCH_VERSION)
|
||||
REQUIRED_PYTHON_VER = (3, 5, 3)
|
||||
|
@ -147,7 +147,7 @@ DEMO_DEVICES = [{
|
||||
'action.devices.traits.Modes'
|
||||
],
|
||||
'type':
|
||||
'action.devices.types.MEDIA',
|
||||
'action.devices.types.SWITCH',
|
||||
'willReportState':
|
||||
False
|
||||
}, {
|
||||
@ -162,7 +162,7 @@ DEMO_DEVICES = [{
|
||||
'action.devices.traits.Modes'
|
||||
],
|
||||
'type':
|
||||
'action.devices.types.MEDIA',
|
||||
'action.devices.types.SWITCH',
|
||||
'willReportState':
|
||||
False
|
||||
}, {
|
||||
@ -171,7 +171,7 @@ DEMO_DEVICES = [{
|
||||
'name': 'Lounge room'
|
||||
},
|
||||
'traits': ['action.devices.traits.OnOff', 'action.devices.traits.Modes'],
|
||||
'type': 'action.devices.types.MEDIA',
|
||||
'type': 'action.devices.types.SWITCH',
|
||||
'willReportState': False
|
||||
}, {
|
||||
'id':
|
||||
@ -182,7 +182,7 @@ DEMO_DEVICES = [{
|
||||
'traits':
|
||||
['action.devices.traits.OnOff', 'action.devices.traits.Volume'],
|
||||
'type':
|
||||
'action.devices.types.MEDIA',
|
||||
'action.devices.types.SWITCH',
|
||||
'willReportState':
|
||||
False
|
||||
}, {
|
||||
|
@ -686,7 +686,7 @@ async def test_device_class_cover(hass, device_class, google_type):
|
||||
|
||||
|
||||
@pytest.mark.parametrize("device_class,google_type", [
|
||||
('non_existing_class', 'action.devices.types.MEDIA'),
|
||||
('non_existing_class', 'action.devices.types.SWITCH'),
|
||||
('speaker', 'action.devices.types.SPEAKER'),
|
||||
('tv', 'action.devices.types.TV'),
|
||||
])
|
||||
|
Loading…
x
Reference in New Issue
Block a user