diff --git a/modules/mesh-build-go/cmd/mesh-build-go/compose.go b/modules/mesh-build-go/cmd/mesh-build-go/compose.go index a44dd7a55..a28671458 100644 --- a/modules/mesh-build-go/cmd/mesh-build-go/compose.go +++ b/modules/mesh-build-go/cmd/mesh-build-go/compose.go @@ -62,7 +62,11 @@ func (m *Module) compose(ctx context.Context, fetch buildstep.StepFunc, a sdkste if err != nil { return nil, err } - req, err := composer.Decode(job.Request) + body, err := job.RequestBytes() + if err != nil { + return nil, buildstep.Refuse("the compose ask %s: %v", a.ID, err) + } + req, err := composer.Decode(body) if err != nil { return nil, buildstep.Refuse("the compose ask %s: %v", a.ID, err) } diff --git a/modules/mesh-build-go/cmd/mesh-build-go/compose_test.go b/modules/mesh-build-go/cmd/mesh-build-go/compose_test.go index b14272e25..722b5abc7 100644 --- a/modules/mesh-build-go/cmd/mesh-build-go/compose_test.go +++ b/modules/mesh-build-go/cmd/mesh-build-go/compose_test.go @@ -81,6 +81,10 @@ func TestAKeptComposerIsRunWithTheManifestsFilled(t *testing.T) { } fetched := 0 fetch := func(context.Context, map[string]any) (any, error) { fetched++; return nil, nil } + // Issue 1966: the request arrives gzip-packed, as the checker sends one over the bus's message limit. + if err := a.Compose.PackRequest(a.Compose.Request); err != nil { + t.Fatal(err) + } out, err := m.compose(context.Background(), fetch, a) if err != nil { t.Fatal(err)