Remove warning

This commit is contained in:
Pascal Vizeli 2017-10-23 08:58:02 +02:00 committed by Fabian Affolter
parent ed82f23da3
commit 9794336113
No known key found for this signature in database
GPG Key ID: DDF3D6F44AAB1336

View File

@ -370,12 +370,6 @@ class EntityPlatform(object):
def add_entities(self, new_entities, update_before_add=False): def add_entities(self, new_entities, update_before_add=False):
"""Add entities for a single platform.""" """Add entities for a single platform."""
# That avoid deadlocks
if update_before_add:
self.component.logger.warning(
"Call 'add_entities' with update_before_add=True "
"only inside tests or you can run into a deadlock!")
run_coroutine_threadsafe( run_coroutine_threadsafe(
self.async_add_entities(list(new_entities), update_before_add), self.async_add_entities(list(new_entities), update_before_add),
self.component.hass.loop).result() self.component.hass.loop).result()