Add blob index to file path (#13736)

* Add index to file path

* Add block root

* Add index to file path
This commit is contained in:
terence 2024-03-12 20:36:43 -10:00 committed by GitHub
parent 4d3a6d84d2
commit d49afb370c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -177,7 +177,7 @@ func saveInvalidBlobToTemp(b blocks.ROBlob) {
if !features.Get().SaveInvalidBlob {
return
}
filename := fmt.Sprintf("blob_sidecar_%d.ssz", b.Slot())
filename := fmt.Sprintf("blob_sidecar_%#x_%d_%d.ssz", b.BlockRoot(), b.Slot(), b.Index)
fp := path.Join(os.TempDir(), filename)
log.Warnf("Writing invalid blob sidecar to disk at %s", fp)
enc, err := b.MarshalSSZ()