Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release #971

Merged
merged 1 commit into from
Oct 1, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions db/python/layers/project_insights.py
Original file line number Diff line number Diff line change
Expand Up @@ -264,15 +264,19 @@ def get_sg_web_report_links(
if stripy_report.outlier_loci
else None
),
'timestamp_completed': stripy_report.timestamp_completed.isoformat(),
'timestamp_completed': stripy_report.timestamp_completed.isoformat()
if stripy_report.timestamp_completed
else None,
}

if mito_report := sequencing_group_mito_reports.get(report_key):
report_links['mito'] = {
'url': self.get_report_url(
project.name, sequencing_group_id, mito_report.output, 'MitoReport'
),
'timestamp_completed': mito_report.timestamp_completed.isoformat(),
'timestamp_completed': mito_report.timestamp_completed.isoformat()
if mito_report.timestamp_completed
else None,
}

return report_links
Expand Down Expand Up @@ -705,6 +709,7 @@ async def _latest_es_indices_by_project_id_and_seq_type_and_stage(
JSON_UNQUOTE(JSON_EXTRACT(meta, '$.stage')) as stage
FROM analysis
WHERE type='es-index'
AND status='COMPLETED'
GROUP BY project, JSON_EXTRACT(meta, '$.sequencing_type'), JSON_EXTRACT(meta, '$.stage')
) max_timestamps ON a.project = max_timestamps.project
AND a.timestamp_completed = max_timestamps.max_timestamp
Expand Down Expand Up @@ -829,6 +834,7 @@ async def _details_stripy_reports(
FROM analysis a
LEFT JOIN analysis_sequencing_group asg on asg.analysis_id=a.id
WHERE type='web'
AND status='COMPLETED'
AND project IN :projects
AND JSON_EXTRACT(meta, '$.stage') = 'Stripy'
GROUP BY asg.sequencing_group_id
Expand Down Expand Up @@ -875,6 +881,7 @@ async def _details_mito_reports(
FROM analysis a
LEFT JOIN analysis_sequencing_group asg on asg.analysis_id=a.id
WHERE type='web'
AND status='COMPLETED'
AND project IN :projects
AND JSON_EXTRACT(meta, '$.stage') = 'MitoReport'
GROUP BY asg.sequencing_group_id
Expand Down