frain-dev / convoy-go

The official Go SDK for Convoy (getconvoy.io)
https://getconvoy.io
MIT License
14 stars 8 forks source link

Unmarshal error when creating events #44

Closed Jossec101 closed 1 week ago

Jossec101 commented 1 month ago

Hi, we are using convoy v23.11.1 and with both sdk versions, v1/v2 we are experiencing unmarshal errors when webhooks are properly created and sent.

The error is in https://github.com/frain-dev/convoy-go/blob/75e92173056dff9097140b087195732a5e15033d/request.go#L122-L127

It looks like the response.Data (e.g. 200) is unmarshalled into a convoy_go.EventResponse leading to an error, we did a workaround to ignore this unmarshall error but this looks to be a legacy code that has been maintained there for some reason.

subomi commented 4 weeks ago

Hi @Jossec101, a temporary fix has been merged for this (#45). You can upgrade your SDK to v2.1.8

I'll leave this open for comments. cc @lil-sahil

subomi commented 1 week ago

Closing this because it seems to be resolved.