Skip to content

Commit

Permalink
Merge pull request #246 from MinaFoundation/PM-1945-mina-staking-ledg…
Browse files Browse the repository at this point in the history
…er-exporter-update-epoch-logic

PM-1945 - Update Mina Staking Ledger Epoch Calculation
  • Loading branch information
kaozenn authored Aug 27, 2024
2 parents 1a91ff9 + 17bcb3d commit 05aa53f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ def get_epochs(pod_name):
status_info = json.loads(output)
slot_number = int(status_info["global_slot_since_genesis_best_tip"])
slots_per_epoch = int(status_info["consensus_time_now"]["slots_per_epoch"])
current_epoch = slot_number // slots_per_epoch
current_epoch = 1 + (slot_number // slots_per_epoch)
next_epoch = current_epoch + 1
return current_epoch, next_epoch

Expand Down

0 comments on commit 05aa53f

Please sign in to comment.