full_node: Drop unused get_fork_point_no_validations (#16107)

This commit is contained in:
dustinface 2023-08-25 00:38:35 +07:00 committed by GitHub
parent 3b20b4a2f0
commit 22e4a5f9f3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -589,20 +589,6 @@ class WeightProofHandler:
fork_point, _ = self.get_fork_point(summaries)
return True, fork_point
def get_fork_point_no_validations(self, weight_proof: WeightProof) -> Tuple[bool, uint32]:
log.debug("get fork point skip validations")
assert self.blockchain is not None
assert len(weight_proof.sub_epochs) > 0
if len(weight_proof.sub_epochs) == 0:
return False, uint32(0)
summaries, sub_epoch_weight_list = _validate_sub_epoch_summaries(self.constants, weight_proof)
if summaries is None:
log.warning("weight proof failed to validate sub epoch summaries")
return False, uint32(0)
assert sub_epoch_weight_list is not None
fork_height, _ = self.get_fork_point(summaries)
return True, fork_height
async def validate_weight_proof(self, weight_proof: WeightProof) -> Tuple[bool, uint32, List[SubEpochSummary]]:
assert self.blockchain is not None
if len(weight_proof.sub_epochs) == 0: