    def time(self) -> Timer:
        """Time a block of code or function, and set the duration in seconds.

        Can be used as a function decorator or context manager.
        """
        return Timer(self, 'set')
Time a block of code or function, and set the duration in seconds.

Can be used as a function decorator or context manager.
prometheus_client/metrics.py