Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

set headerfs.BlockStamp.Timestamp #235

Merged
merged 1 commit into from
Dec 14, 2021

Conversation

chappjc
Copy link
Contributor

@chappjc chappjc commented Nov 9, 2021

The headerfs.BlockStamp returned from (*ChainService).BestBlock had a zero Timestamp.
This change sets the Timestamp field from the block header if available.

Internally it does not seem to matter that Timestamp is the zero time.Time, but for ChainService consumers it is helpful to have the block's timestamp. For example, one may compare the timestamp from the current best block from ChainService to the wallet Manager's birthday time.

headerfs/store.go Outdated Show resolved Hide resolved
neutrino.go Show resolved Hide resolved
@lightninglabs-deploy
Copy link

@chappjc, remember to re-request review from reviewers for your latest update

@lightninglabs-deploy
Copy link

@ellemouton: review reminder

2 similar comments
@lightninglabs-deploy
Copy link

@ellemouton: review reminder

@lightninglabs-deploy
Copy link

@ellemouton: review reminder

Copy link
Member

@ellemouton ellemouton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tACK 🚀

blockmanager.go Show resolved Hide resolved
The headerfs.BlockStamp returned from (*ChainService).BestBlock had a
zero Timestamp.  This change sets the Timestamp field from the block
header.
Copy link
Member

@Roasbeef Roasbeef left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🪓

@Roasbeef Roasbeef merged commit 53b628c into lightninglabs:master Dec 14, 2021
@chappjc chappjc deleted the timestamp-blockstamp branch December 14, 2021 23:14
@chappjc
Copy link
Contributor Author

chappjc commented Dec 14, 2021

🙏 Thanks! This will be a helpful change on our end.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants