(self)
| 236 | updated_at = Column(DateTime, default=utcnow_naive, onupdate=utcnow_naive) |
| 237 | |
| 238 | def to_dict(self) -> Dict[str, Any]: |
| 239 | return { |
| 240 | "id": self.id, |
| 241 | "run_uuid": self.run_uuid, |
| 242 | "mode": self.mode, |
| 243 | "source": self.source, |
| 244 | "status": self.status, |
| 245 | "score": int(self.score or 0), |
| 246 | "total_checks": int(self.total_checks or 0), |
| 247 | "passed_checks": int(self.passed_checks or 0), |
| 248 | "warning_checks": int(self.warning_checks or 0), |
| 249 | "failed_checks": int(self.failed_checks or 0), |
| 250 | "duration_ms": int(self.duration_ms or 0), |
| 251 | "summary": self.summary, |
| 252 | "error_message": self.error_message, |
| 253 | "result_data": self.result_data or {}, |
| 254 | "created_at": self.created_at.isoformat() if self.created_at else None, |
| 255 | "started_at": self.started_at.isoformat() if self.started_at else None, |
| 256 | "finished_at": self.finished_at.isoformat() if self.finished_at else None, |
| 257 | "updated_at": self.updated_at.isoformat() if self.updated_at else None, |
| 258 | } |
| 259 | |
| 260 | |
| 261 | class Setting(Base): |
nothing calls this directly
no outgoing calls
no test coverage detected