From baec212c1527259dc3bd0e0ea961e2b8154d4825 Mon Sep 17 00:00:00 2001 From: Théo de la Hogue Date: Tue, 10 Sep 2024 17:03:07 +0200 Subject: Catching error in livedata.json.gz file parsing. --- src/argaze/utils/contexts/TobiiProGlasses2.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/argaze/utils/contexts/TobiiProGlasses2.py b/src/argaze/utils/contexts/TobiiProGlasses2.py index fbc9d1e..081e225 100644 --- a/src/argaze/utils/contexts/TobiiProGlasses2.py +++ b/src/argaze/utils/contexts/TobiiProGlasses2.py @@ -1522,7 +1522,15 @@ class SegmentPlayback(ArFeatures.DataPlaybackContext): raise StopIteration # Parse data - data_object, data_object_type = self.__parser.parse_data(status, data) + try: + + data_object, data_object_type = self.__parser.parse_data(status, data) + + except Exception as e: + + logging.error('%s while parsing livedata.json.gz at %i timestamp', e, ts) + + return self.__next_data() # Return millisecond timestamp, data object and type return ts * 1e-3, data_object, data_object_type -- cgit v1.1