-
Notifications
You must be signed in to change notification settings - Fork 152
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
Miner is no longer nullable #1341
Miner is no longer nullable #1341
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1341 +/- ##
==========================================
+ Coverage 77.08% 77.14% +0.06%
==========================================
Files 256 256
Lines 17262 17257 -5
==========================================
+ Hits 13306 13313 +7
+ Misses 3390 3378 -12
Partials 566 566
|
What happens if deserializing pre-existing blocks with null miner? |
Hmm... libplanet/Libplanet/Blocks/BlockHeader.cs Line 119 in 9e0e63d
If a key/value pair is present, but the value is empty, then again, deserialization would fail on: libplanet/Libplanet/Blocks/Block.cs Line 168 in 9e0e63d
I'm assuming creation of malformed |
43fe1d5
to
2250357
Compare
/rebase |
2250357
to
6983399
Compare
bd695b7
to
2b68661
Compare
2b68661
to
00ddc70
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
526163d
to
51f4e43
Compare
51f4e43
to
1cb52bf
Compare
/rebase |
1cb52bf
to
3b22396
Compare
Unless we want to support blockchain architecture where blocks without miners are allowed as a feature, there doesn't seem to be a real necessity for having
null
minerAddress
forBlock<T>
. On a side note, having a dummyAddress
or a specialAddress
reserved for unforeseen future purposes might come in handy for the convenience of development. Just spitballing, but something like/dev/null
Address
"eating up"Transaction<T>
s and/orIAction
s might be useful. Perhaps we should reserve0
and/or1
?