ReviewOS

stacks/ts-watches

getActivityDetails drops the GPS and getActivity returns records: [] — only the original download carries a route

#13
Open chris opened this 8 days ago ·
8 days ago

Split out of #12, which is fixed: downloadOriginalActivity() (0.1.3) returns the original recording's bytes, and hq.training reads routes through it.

The other two ways to get an activity still cannot carry a route, which is why a server has to download and parse the original file to get one at all:

  • getActivityDetails() drops the GPS. Garmin Connect's activity-details response includes the polyline and per-sample metrics; the method returns the summary and leaves the coordinates behind.
  • getActivity() hardcodes records: [], so its Activity shape advertises records it never fills.

Either should return the samples it was given (lat/lon, time, altitude, heart rate where present), or the types should stop promising them. As it stands a caller reads records, gets an empty array, and cannot tell "no GPS" from "not fetched".

Sign in to comment on this issue.