def METHOD_NAME(self) -> None:
    """
    cancels the _periodic while loop
    """
    if self._periodic_task is not None:
        self._periodic_task.cancel()
        with suppress(asyncio.CancelledError):
            # Await task to execute it's cancellation
            self._loop.run_until_complete(self._periodic_task)
        self._periodic_task = None