The 0 problem has been happening since April 2021 (GPSE 4.4.64) and it continues to this day (GPS 4.5.5), but in a different form.
I first reported the problem in April 2021 here:
With GPSE 4.5.5, it still records (0,0,0) values, but now they are written out to the KML file as (NaN, NaN, NaN).
I have updated the err2.html page (link above) with that information and I have supplied as much detail as possible to fully describe the problem.
I don't think this is related to exporting to KML or any other format. I think the bad values are being written to the database, as is evidenced by the GPSE display which shows nonsense values, e.g. for speed and distance. Perhaps the best solution is to discard (0,0,0) values on acuisition and not write to the database.
The new NaN placeholder seems to indicate that you are doing a floating-point calculation that is failing. Here is some discussion of testing for the presence of NaN by using the .isNan() method:
Perhaps:
if(x.isNaN() || y.isNaN() || z.isNaN()) then don't write to database.
I would be more than happy to send my entire database if you want to look at it. It's not that big. I offered to do that in 2021, but didn't get a response.
jag