Skip to content

`mining_in_logarithmic_space_constant_difficulty.py` specific issues

Optimization:

  • 7m24 (bd6658de)
  • 7m17 (5f09d42a)
  • 6m05 (if output to a file that we don't continuously request)

Could just copy.deepcopy the blocks we actually change.

Correctness:

  • missing level_min usage maybe involving multiple levels having more than 2 * m blocks. Could solve this issue by making a copy.deepcopy in uparrow setting level_min but this seems heavy. Maybe there is no problem, as it's just blocks the latest m above blocks. Should verify if not updating level_min isn't problematic. It seems that with and without copy.deepcopy both compressed blockchains only start to differ at their last 100 blocks. Could use print(hash(tuple(Π))) to get the precise first difference height, but as I consider current code more correct, can just skip comparing with the previous one.
  • TODO: step-by-step
Edited by LOISON Benjamin