Update EIP-4844: Decouple blobs#6610
Conversation
|
✅ All reviewers have approved. |
|
The commit 366b28a (as a parent of bb8db28) contains errors. |
EIPS/eip-4844.md
Outdated
| blobs: List[Vector[BLSFieldElement, FIELD_ELEMENTS_PER_BLOB], LIMIT_BLOBS_PER_TX] | ||
| # KZGProof = Bytes48 | ||
| kzg_aggregated_proof: KZGProof | ||
| blob_proofs: List[KZGProof, MAX_TX_WRAP_KZG_COMMITMENTS] |
There was a problem hiding this comment.
A bit redundant to call it blob_proofs. Let's call it proofs.
There was a problem hiding this comment.
added it on the lines of blob_kzgs, should we also rename it to just kzgs?
There was a problem hiding this comment.
IMO kzgs is ambiguous because it's not clear if it refers to proofs or commitments.
There was a problem hiding this comment.
then renaming them to commitments is a good idea?
There was a problem hiding this comment.
I think it is a good idea, but probably in a separate PR.
I was originally mistaken that you were gonna introduce another kzgs naming with this PR, but since it refers to something that already exists, please disregard my previous comment.
I don't have a strong opinion about blob_kzgs vs kzgs. But I guess if you go with proofs it also makes sense to go with kzgs.
There was a problem hiding this comment.
Prefer commitments to kzgs.
There was a problem hiding this comment.
updated, can rename blob_kzgs to commitments in a followup PR
There was a problem hiding this comment.
Here is the followup PR build on top of this current branch: g11tech#1 (can update target to this repo once this PR merges)
There was a problem hiding this comment.
I have merged the followup changes to this PR on the request from @Inphi
| def kzg_to_versioned_hash(kzg: KZGCommitment) -> VersionedHash: | ||
| return BLOB_COMMITMENT_VERSION_KZG + sha256(kzg)[1:] | ||
| def kzg_to_versioned_hash(commitment: KZGCommitment) -> VersionedHash: | ||
| return BLOB_COMMITMENT_VERSION_KZG + sha256(commitment)[1:] |
There was a problem hiding this comment.
Suggest renaming all BLOB_COMMITMENT_VERSION_KZG to VERSIONED_HASH_VERSION_KZG as CL specs.
| return BLOB_COMMITMENT_VERSION_KZG + sha256(commitment)[1:] | |
| return VERSIONED_HASH_VERSION_KZG + sha256(commitment)[1:] |
There was a problem hiding this comment.
umm ... BLOB_COMMITMENT_VERSION_KZG makes more sense to me as its the version of the commitment scheme
There was a problem hiding this comment.
I think the rationale was the version of VersionedHash. I'm not sure what's the scenario of changing VERSIONED_HASH_VERSION_* but not just changing the commitment scheme though.
It should be unified to one of the names anyway.
/cc @asn-d6 @dankrad any thoughts?
And kzg_to_versioned_hash was also renamed to kzg_commitment_to_versioned_hash.
There was a problem hiding this comment.
No strong opinion here. I think both variants are reasonable.
I would go with @hwwhww suggestions to make it the same with consensus-specs.
Co-authored-by: dankrad <[email protected]>
Co-authored-by: dankrad <[email protected]>
|
rebase via UI @Inphi could you take a look/re-approve now that you are in authors list 😆 |
|
It might be off the scope of this PR, but there are some more CL specs changes that are not synced. |
asn-d6
left a comment
There was a problem hiding this comment.
Let's get this merged finally! Sorry for the delays.
@g11tech is there a chance you can also open another PR to further synchronize the EIP with the consensus-specs in terms of function names and type changes. I think consensus-specs is a bit ahead on this (due to the unittests) and we should get the EIP to catch up. Thanks!
eth-bot
left a comment
There was a problem hiding this comment.
All Reviewers Have Approved; Performing Automatic Merge...
|
sounds good, will open an update for bringing naming convention uptodate |
Decouple the blobs as per