Exceptions API
src.core.exceptions ¶
This module provides all exceptions used within the system. All exceptions inherit from the base class CGMProcessorError or one of the subsequent children classes.
CGMProcessorError ¶
Bases: Exception
Base exception for all CGM processor errors.
Source code in src/core/exceptions.py
FileError ¶
FileAccessError ¶
FileExtensionError ¶
FileParseError ¶
FormatError ¶
Bases: CGMProcessorError
Base class for format-related errors.
Source code in src/core/exceptions.py
FormatDetectionError ¶
Bases: FormatError
Raised when there's an error detecting file format.
Source code in src/core/exceptions.py
FormatLoadingError ¶
FormatValidationError ¶
Bases: FormatError
Raised when there's an error validating format definition.
Source code in src/core/exceptions.py
DeviceFormatError ¶
ReaderError ¶
Bases: CGMProcessorError
Base class for reader related errors.
Source code in src/core/exceptions.py
ProcessingError ¶
Bases: CGMProcessorError
Base class for data processing errors.
Source code in src/core/exceptions.py
DataProcessingError ¶
Bases: ProcessingError
Raised when there's an error processing data.
Source code in src/core/exceptions.py
TimestampProcessingError ¶
Bases: ProcessingError
Raised when there is a timestamp format issues
Source code in src/core/exceptions.py
AlignmentError ¶
Bases: ProcessingError
Raised when there is an error aligning datasets
Source code in src/core/exceptions.py
DataExistsError ¶
ValidationError ¶
DataValidationError ¶
Bases: ValidationError
Raised when there's an error validating data.
Source code in src/core/exceptions.py
ExportError ¶
DataQualityError ¶
Bases: ProcessingError
Raised when data quality checks fail (e.g., too many gaps, noise).
Source code in src/core/exceptions.py
TimeAlignmentError ¶
Bases: ProcessingError
Raised when there are issues aligning different data streams (e.g., CGM with insulin).
Source code in src/core/exceptions.py
UnitConversionError ¶
Bases: ProcessingError
Raised for unit conversion issues (e.g., mg/dL to mmol/L).
Source code in src/core/exceptions.py
MetricCalculationError ¶
Bases: ProcessingError
Raised when there are issues calculating diabetes metrics.
Source code in src/core/exceptions.py
CalibrationError ¶
Bases: ProcessingError
Raised for sensor calibration related issues.
Source code in src/core/exceptions.py
DataGapError ¶
Bases: DataQualityError
Raised when data gaps exceed acceptable thresholds.