tcgoetz / GarminDB

Download and parse data from Garmin Connect or a Garmin watch, FitBit CSV, and MS Health CSV files into and analyze data in Sqlite serverless databases with Jupyter notebooks.
GNU General Public License v2.0
1.1k stars 138 forks source link

Getting Failed to parse error on multiple activities #206

Closed myanshin closed 10 months ago

myanshin commented 10 months ago

Got multiple error messages while running for big part of activities: garmindb_cli.py --all --download --import --analyze --latest

Example: Failed to parse /home/maxim/HealthData/FitFiles/Activities/8284779428_ACTIVITY.fit: unsupported operand type(s) for &: 'list' and 'int' Failed to parse /home/maxim/HealthData/FitFiles/Activities/9855393971_ACTIVITY.fit: unsupported operand type(s) for &: 'list' and 'int' Failed to parse /home/maxim/HealthData/FitFiles/Activities/4722858425_ACTIVITY.fit: unsupported operand type(s) for &: 'list' and 'int'

bugreport.zip Ativities.zip

tcgoetz commented 10 months ago

Looks like you have a device or sensor:

manufacturer(<Manufacturer.zwift: 260> (260))

that is producing invalid data. It's passing an a list [255, 255, 255] where 255 is invalid value in some messages. I'm extending the parser to deal with it.

tcgoetz commented 10 months ago

Fix is in the develop branch. You can try it here or wait for the next release which should be soon.

tcgoetz commented 10 months ago

Fix is in 3.5.1.