-
-
Notifications
You must be signed in to change notification settings - Fork 173
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
cannot unmarshal array into Go value of type models.Heartbeat #688
Comments
It's both, the |
@alanhamlett Can you give a few hints about what has changed on the plugin's end to cause these failures? Did the payload of heartbeats sent to the API change? Can you point me to the relevant commits in the plugin's codebase, please? |
To be honest, rather than putting long-winded hacks in place on Wakapi's heartbeats endpoint, I'd prefer to make the plugin follow the payload format specified in the docs, where |
Sure, I'll fix that in the browser extension. |
Thanks! 👍 Pushed a fix to Wakapi in the meanwhile well. Actually, sending |
Ok, I'll revert my browser-wakatime change then. 👍 |
I'm seeing a 400 error response from
https://wakapi.dev/api/compat/wakatime/v1/users/current/heartbeats.bulk
:When sending JSON payload:
Might be from
time
being a string instead of number. The WakaTime API accepts both types, but we prefer string to avoid any floating point accuracy errors.Or, it could be the
id
oruserAgent
attributes, which might not be known by wakapi.Lastly, it could be
"type": "domain"
, but I assume wakapi should support that because it's been used by the browser extension for many years already.System information
The text was updated successfully, but these errors were encountered: