-
Notifications
You must be signed in to change notification settings - Fork 34
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
show response commitment #144
Conversation
@@ -260,7 +260,7 @@ func (svr *Server) HandlePut(w http.ResponseWriter, r *http.Request) (commitment | |||
} | |||
} | |||
|
|||
svr.log.Info(fmt.Sprintf("write commitment: %x\n", comm)) |
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.
oh yeah I noticed this as well. Not super sure what the intent of this was. If this is only meant for keccak commitments, then we should print it in the if clause above probably? Or was this just a mistake @epociask ?
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.
I think there is a bit confusion on the term commitment schema, https://github.com/Layr-Labs/eigenda-proxy?tab=readme-ov-file#commitment-schemas. The readme section actually means returned commitment-schemas.
In the commented log above, it only prints comm used when you send data to eigenda-proxy. If it is optimism alt da, the commitment is left empty, so nothing gets printed.
I often find it useful to debug, if I have the response commitment, which is something rollup will commit onchain. So I am adding this change
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.
The responseCommitment should be same as comm when keccak is used right? So there's literally no point in logging comm
? If that's the case, then let's just merge this. But if there is a difference between comm
and responseCommit
, then perhaps we should log both?
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.
no really, for keccak, you append a version byte 0 before the hash, https://github.com/Layr-Labs/eigenda-proxy/blob/main/commitments/op.go#L110
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.
since it is a byte, printing will just show 00 in the front
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.
oh comm is the commit type?? I thought it was the commitment for keccak commitments, where the commitment is supplied in the POST request?
Current behavior after put, it shows an empty string
![Screenshot 2024-09-20 at 1 19 23 PM](https://private-user-images.githubusercontent.com/93296844/369547731-94818a9c-26dd-4a0b-b5a8-083a5700a526.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NTQzMTQsIm5iZiI6MTczOTQ1NDAxNCwicGF0aCI6Ii85MzI5Njg0NC8zNjk1NDc3MzEtOTQ4MThhOWMtMjZkZC00YTBiLWI1YTgtMDgzYTU3MDBhNTI2LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEzVDEzNDAxNFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWQzYzk5NjBmM2ZkOWFiY2ZkNjc5NDQ5YjQwNDAxMjFkYjcyNzhhMDE5ZWM5ODhkYWM5NzE5MjA4MGM1NTg4YjYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.X_Yl5oVejNXcORE1mlCpYGQsTlX3ykP1Q1fXF8jGjZw)
This fix prints the response commitment
![Screenshot 2024-09-20 at 1 36 23 PM](https://private-user-images.githubusercontent.com/93296844/369547934-4b193341-0794-4f98-b71f-b580e2a99a73.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NTQzMTQsIm5iZiI6MTczOTQ1NDAxNCwicGF0aCI6Ii85MzI5Njg0NC8zNjk1NDc5MzQtNGIxOTMzNDEtMDc5NC00Zjk4LWI3MWYtYjU4MGUyYTk5YTczLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEzVDEzNDAxNFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTdjODkzODYwNGJkYWIzZWI3YmZmNDdhM2MwZDIyZTBlODZiYzA0Mzg0ZjE3OWIwN2Y4MTc4YmJlYzk1M2ZmZTEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.QujZyblzMqyxiADZn-HRAOrs8wTnd3aOWtXgKeuGOdo)