async def _update_entity_states(self, now):
    'Update the states of all the polling entities.\n\n        To protect from flooding the executor, we will update async entities\n        in parallel and other entities sequential.\n\n        This method must be run in the event loop.\n        '
    if self._process_updates.locked():
        self.logger.warning('Updating %s %s took longer than the scheduled update interval %s', self.platform_name, self.domain, self.scan_interval)
        return
    async with self._process_updates:
        tasks = []
        for entity in self.entities.values():
            if (not entity.should_poll):
                continue
            tasks.append(entity.async_update_ha_state(True))
        if tasks:
            (await asyncio.wait(tasks))
Update the states of all the polling entities.

To protect from flooding the executor, we will update async entities
in parallel and other entities sequential.

This method must be run in the event loop.
async def _update_entity_states(self, now):
    'Update the states of all the polling entities.\n\n        To protect from flooding the executor, we will update async entities\n        in parallel and other entities sequential.\n\n        This method must be run in the event loop.\n        '
    if self._process_updates.locked():
        self.logger.warning('Updating %s %s took longer than the scheduled update interval %s', self.platform_name, self.domain, self.scan_interval)
        return
    async with self._process_updates:
        tasks = []
        for entity in self.entities.values():
            if (not entity.should_poll):
                continue
            tasks.append(entity.async_update_ha_state(True))
        if tasks:
            (await asyncio.wait(tasks))