Fit file data truncation for subsecond data

it seems like .fit files that contain subsecond data get parsed just as the first value for each second interval, truncating much of the original data. this is the case for .fit files downloaded from wattbike hub.

on the right here is the original fit file downloaded from intervals.icu and parsed just with https://www.fitfileviewer.com/; on the left is the data parsed from that file. note that the watts from in intervals.icu are always the first value from the data points for a given second

I was kinda torn on bug vs feature request here, but I landed on bug because data is being ignored. Based on the nature of the issue, it seems unlikely that introducing millisecond precision to the datetime field that stores this data is feasible - if that’s the case I would like to propose calculating an average of the values that have the same whole second datetime. That way, even though the resulting intervals.icu data may not exactly reflect the incoming data, at least all the data it’s given is being accounted for and not dropped

1 Like

@david have you happened to have a chance to take a look at this?

Intervals.icu will use the first value found for duplicate timestamps. This isn’t something I can change easily because there is already a lot of complicated (and dangerous) logic there (lots of strange things happen in fit files). I don’t think averaging would make any difference over just using the first value, as it is effectively just random sampling.

ok, i think thats reasonable, its not breaking anything. thanks for taking a look