Coverage for backend / app / service_runner / models.py: 100%

6 statements  

« prev     ^ index     » next       coverage.py v7.13.5, created at 2026-03-17 21:34 +0000

1"""Module defining the ServiceLog base class for service logs.""" 

2 

3from sqlalchemy import Column, String, Float, Boolean, TIMESTAMP 

4 

5 

6class ServiceLog(object): 

7 """Base class for service logs. 

8 

9 Attributes: 

10 ----------- 

11 - `run_duration` (float, optional): Duration of the service run. 

12 - `run_datetime` (datetime): Date and time of the service run. 

13 - `is_success` (bool): Indicates whether the service run was successful. 

14 - `error_message` (str, optional): Error message if the service run failed.""" 

15 

16 run_duration = Column(Float, nullable=True) 

17 run_datetime = Column(TIMESTAMP(timezone=True), nullable=False) 

18 is_success = Column(Boolean, nullable=True) 

19 error_message = Column(String, nullable=True)