protolambda / go-kzg

FFT, data-recovery and KZG commitments, a.k.a. Kate commitments, in Go - *super experimental*
MIT License
90 stars 26 forks source link

add higher level eth package implementing much of eip-4844 bytes api #28

Closed roberto-bayardo closed 1 year ago

roberto-bayardo commented 1 year ago

Hi @protolambda , two things in particular I need some guidance on:

Should the versioned hash stuff be in here? If not, where do you think it should go? (It's used both by CL and EL clients.)

I'm depending on go-ethereum/params ... should I just copy / paste those needed constants here to remove that dependency?

thanks.

roberto-bayardo commented 1 year ago

Oh and I will push tests in a separate PR, as they are unfortunately are not yet quite ready to pull out of geth.

protolambda commented 1 year ago

I'm depending on go-ethereum/params ... should I just copy / paste those needed constants here to remove that dependency?

Yes please

protolambda commented 1 year ago

Should the versioned hash stuff be in here? If not, where do you think it should go? (It's used both by CL and EL clients.)

For completeness I think it's fine to host here. The complexity is low, and it may come in useful once we have standard tests for the eth KZG interface usage, to be able to run them all.

roberto-bayardo commented 1 year ago

I'm depending on go-ethereum/params ... should I just copy / paste those needed constants here to remove that dependency?

Yes please

done

roberto-bayardo commented 1 year ago

cc: @kevaundray

protolambda commented 1 year ago

Updating go-kzg min Go requirement to Go 1.18 for embed and other newer features to work. See https://github.com/protolambda/go-kzg/pull/29

protolambda commented 1 year ago

@roberto-bayardo I updated master branch with Go 1.18 from #29. Can you rebase this PR?

Also, can I help update TxPeekBlobVersionedHashes to not use ztyp? I think it can be more efficient/minimal, and it'll remove a dependency.

roberto-bayardo commented 1 year ago

@roberto-bayardo I updated master branch with Go 1.18 from #29. Can you rebase this PR?

done

Also, can I help update TxPeekBlobVersionedHashes to not use ztyp? I think it can be more efficient/minimal, and it'll remove a dependency.

yes i'm all for it.

protolambda commented 1 year ago
roberto-bayardo commented 1 year ago
  • For some reason the kzg.go file was dropped in the rebase, I edited the commit to put it back.

Sorry my bad I had renamed kzg.go from the new eth package and must have got this confused with it.

roberto-bayardo commented 1 year ago

cool looks good to go? Once merged I'll run it through our interop repo e2e tests.