Commit 5c54f040 authored by juga's avatar juga
Browse files

fix: relaylist: Convert consensus bandwidth to bytes

Since all the other bandwidth values are in bytes and sbws should
work with bytes until it generates the final `bw`.

Closes: #29707. Bugfix v1.0.3.
parent 7a802e22
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -120,7 +120,12 @@ class Relay:

    @property
    def consensus_bandwidth(self):
        return self._from_ns('bandwidth')
        """Return the consensus bandwidth in Bytes.

        Consensus bandwidth is the only bandwidth value that is in kilobytes.
        """
        if self._from_ns('bandwidth') is not None:
            return self._from_ns('bandwidth') * 1000

    @property
    def consensus_bandwidth_is_unmeasured(self):