attestantio / go-eth2-client

Apache License 2.0
111 stars 65 forks source link

Fails to decode blob sidecars from Prysm #129

Open danyalprout opened 5 months ago

danyalprout commented 5 months ago

Hi 👋

We use this library to fetch blobs from the beacon chain. We noticed that when using Prysm as the beacon node the SSZ decoding of blob sidecars fails (see issue).

The error is happening here, due to the response from Prysm having an extra four bytes at the start (it appears to be an offset to the first element).

I suspect this maybe a Prysm encoding bug, as the spec reads as if the offset isn't required when a response is just an array of ojects.

Just wanted to double check and see if you had any insight/any other reports of this. Thank you 🙏

mcdee commented 5 months ago

It's possible that this library is the incorrect one, did you resolve the issue to know if providing the number of elements in the array (which I assume are the first four items in the data) is required?

mcdee commented 3 months ago

After further investigation it appears that this is a prysm issue, as testing against lighthouse, nimbus and teku returns the same SSZ and it is prysm which is the odd one out. Did you raise an issue with them regarding this?