'Stops the metronome at the given time if it is currently running.
Args:
stop_time: The float wall time in seconds after which the metronome should
stop. By default, stops at next tick.
block: If true, blocks until metronome is stopped.'

@concurrency.serialized
def stop_metronome(self, stop_time=0, block=True):

    if (self._metronome is None):
        return
    self._metronome.stop(stop_time, block)
    self._metronome = None
