@property<EOL><INDENT>def latency(self):<DEDENT>
if not self.shards:<EOL><INDENT>return float('<STR_LIT>')<EOL><DEDENT>return sum(latency for _, latency in self.latencies) / len(self.shards)<EOL>
:class:`float`: Measures latency between a HEARTBEAT and a HEARTBEAT_ACK in seconds.

        This operates similarly to :meth:`.Client.latency` except it uses the average
        latency of every shard's latency. To get a list of shard latency, check the
        :attr:`latencies` property. Returns ``nan`` if there are no shards ready.