~craftyguy/ridecasa

8b8a86198ae90b91333bb5aa36c7893a59ab5183 — Clayton Craft 2 years ago f719974
parsers/fitparse: ignore points with no position data
1 files changed, 5 insertions(+), 0 deletions(-)

M ridecasa/parsers/fitparse.py
M ridecasa/parsers/fitparse.py => ridecasa/parsers/fitparse.py +5 -0
@@ 35,6 35,11 @@ class FITParse():
        start_time = fit_summary.get_value('start_time')
        trackpoints = []
        for record in records:
            lat = record.get_value('position_lat')
            lon = record.get_value('position_long')
            if not lat or not lon:
                # ignore points with no position data
                continue
            r_time = record.get_value('timestamp')
            alt = record.get_value('enhanced_altitude')
            if not alt: