Getting started with Issue #1292 #1597
Closed
erwindassen
started this conversation in
General
Replies: 2 comments
-
It might make sense to split the changes into 2 different PRs (if only to get the first improvement merged in). As for 2 I think GetTimestamp will be your friend. I actually really dislike the |
Beta Was this translation helpful? Give feedback.
0 replies
-
This has already been dealt with in #1638. Closing. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there, I'm trying to learn the codebase and thought of starting with some issues appropriately tagged. I came across issue #1292 and it seemed doable. 1. was no issue. But along point 2 I got to the point where I've created a window whose tip is - instead of the wall clock time - the timestamp of the last accepted P-chain block... or it should be. The issue is that (platformvm) block.Block does not have a timestamp. There is a BanffBlock interface but the state functions (in platformvm/state/state.go) do not seem to use it. I'm wondering if I am going about this wrong or if there is a proper/better way to get the timestamp of the last P-chain accepted block.
I am also not supper happy with the way I am doing this. I had to make changes to mockable.Clock to generalize it to accept a custom Time() function; as of now either you get current wall clock time (the default) or a set constant.
Don't want to waste your time so if you prefer for me to just drop it let me know and perhaps point me to a better issue for a noob.
Beta Was this translation helpful? Give feedback.
All reactions