Loading sbws/lib/v3bwfile.py +37 −37 Original line number Diff line number Diff line Loading @@ -313,7 +313,6 @@ class V3BWLine(object): divided by the the time it took to received. bw = data (Bytes) / time (seconds) """ success_results = [r for r in results if isinstance(r, ResultSuccess)] # log.debug("Len success_results %s", len(success_results)) node_id = '$' + results[0].fingerprint kwargs = dict() Loading @@ -322,8 +321,10 @@ class V3BWLine(object): kwargs['master_key_ed25519'] = results[0].master_key_ed25519 kwargs['time'] = cls.last_time_from_results(results) kwargs.update(cls.result_types_from_results(results)) # useful args for scaling if success_results: success_results = [r for r in results if isinstance(r, ResultSuccess)] if not success_results: return None results_away = \ cls.results_away_each_other(success_results, secs_away) if not results_away: Loading Loading @@ -358,7 +359,6 @@ class V3BWLine(object): cls.desc_bw_obs_mean_from_results(results_recent) bwl = cls(node_id, bw, **kwargs) return bwl return None @classmethod def from_data(cls, data, fingerprint): Loading Loading
sbws/lib/v3bwfile.py +37 −37 Original line number Diff line number Diff line Loading @@ -313,7 +313,6 @@ class V3BWLine(object): divided by the the time it took to received. bw = data (Bytes) / time (seconds) """ success_results = [r for r in results if isinstance(r, ResultSuccess)] # log.debug("Len success_results %s", len(success_results)) node_id = '$' + results[0].fingerprint kwargs = dict() Loading @@ -322,8 +321,10 @@ class V3BWLine(object): kwargs['master_key_ed25519'] = results[0].master_key_ed25519 kwargs['time'] = cls.last_time_from_results(results) kwargs.update(cls.result_types_from_results(results)) # useful args for scaling if success_results: success_results = [r for r in results if isinstance(r, ResultSuccess)] if not success_results: return None results_away = \ cls.results_away_each_other(success_results, secs_away) if not results_away: Loading Loading @@ -358,7 +359,6 @@ class V3BWLine(object): cls.desc_bw_obs_mean_from_results(results_recent) bwl = cls(node_id, bw, **kwargs) return bwl return None @classmethod def from_data(cls, data, fingerprint): Loading