Skip to content
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

Fix swagger doc gen to resolve v2.BlobHeader #1199

Merged
merged 1 commit into from
Feb 3, 2025

Conversation

pschork
Copy link
Contributor

@pschork pschork commented Feb 2, 2025

Swagger was including the (v1) core.BlobHeader instead of the v2.BlobHeader in the v2.BlobFeedResponse

v2.BlobFeedResponse{
blobs	[v2.BlobInfo{
blob_key	[...]
blob_metadata	v2.BlobMetadata{
blobHeader	core.BlobHeader{
accountID	[...] <-- accountID is inside the BlobHeader object

Checks

  • I've made sure the tests are passing. Note that there might be a few flaky tests, in that case, please comment that they are not relevant.
  • I've checked the new test coverage and the coverage percentage didn't drop.
  • Testing Strategy
    • Unit tests
    • Integration tests
    • This PR is not tested :(

@pschork pschork requested a review from jianoaix February 2, 2025 03:39
@@ -71,7 +71,7 @@ func BlobStatusFromProtobuf(s pb.BlobStatus) (BlobStatus, error) {

// BlobMetadata is an internal representation of a blob's metadata.
type BlobMetadata struct {
BlobHeader *core.BlobHeader
BlobHeader *corev2.BlobHeader
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, this is not just a doc issue, it's a real bug. Our test seems weak.

Copy link
Contributor Author

@pschork pschork Feb 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure. The go compiler does the right thing with core "github.com/Layr-Labs/eigenda/core/v2". I think swagger builds a naive package lookup so resolves to v1 core.BlobHeader

@pschork pschork merged commit 5620ce2 into master Feb 3, 2025
10 checks passed
@pschork pschork deleted the pschork/swagger_blobheader_fix branch February 3, 2025 23:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants