Skip to content

Commit

Permalink
Changed: output plotid when we find an invalid proof of space (#15257)
Browse files Browse the repository at this point in the history
* output plotid when we find an invalid proof of space

* fix
  • Loading branch information
wjblanke committed May 12, 2023
1 parent 148a8eb commit f278520
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion chia/farmer/farmer_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,10 @@
from chia.types.blockchain_format.proof_of_space import (
generate_plot_public_key,
generate_taproot_sk,
get_plot_id,
verify_and_get_quality_string,
)
from chia.types.blockchain_format.sized_bytes import bytes32
from chia.util.api_decorators import api_request
from chia.util.ints import uint32, uint64

Expand Down Expand Up @@ -92,7 +94,8 @@ async def new_proof_of_space(self, new_proof_of_space: harvester_protocol.NewPro
new_proof_of_space.sp_hash,
)
if computed_quality_string is None:
self.farmer.log.error(f"Invalid proof of space {new_proof_of_space.proof}")
plotid: bytes32 = get_plot_id(new_proof_of_space.proof)
self.farmer.log.error(f"Invalid proof of space: {plotid.hex()} proof: {new_proof_of_space.proof}")
return None

self.farmer.number_of_responses[new_proof_of_space.sp_hash] += 1
Expand Down

0 comments on commit f278520

Please sign in to comment.