Skip to content

Commit

Permalink
Index variantcallingactivity entities (#4617)
Browse files Browse the repository at this point in the history
  • Loading branch information
nadove-ucsc committed Dec 6, 2022
1 parent d021bc4 commit 26237c0
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/azul/plugins/metadata/anvil/indexer/transform.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,8 @@ def _only_dataset(self) -> MutableJSON:
'activity',
'alignmentactivity',
'assayactivity',
'sequencingactivity'
'sequencingactivity',
'variantcallingactivity'
}


Expand Down
21 changes: 21 additions & 0 deletions src/azul/plugins/repository/tdr_anvil/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,15 @@ def _upstream_from_files(self,
FROM file AS f
JOIN {backtick(self._full_table_name(source, 'sequencingactivity'))} AS sqa
ON f.file_id IN UNNEST(sqa.generated_file_id)
UNION ALL SELECT
f.file_id,
'variantcallingactivity',
vca.variantcallingactivity_id,
vca.used_file_id,
[]
FROM file AS f
JOIN {backtick(self._full_table_name(source, 'variantcallingactivity'))} AS vca
ON f.file_id IN UNNEST(vca.generated_file_id)
UNION ALL SELECT
f.file_id,
'activity',
Expand Down Expand Up @@ -419,6 +428,12 @@ def _downstream_from_files(self,
ala.used_file_id,
ala.generated_file_id
FROM {backtick(self._full_table_name(source, 'alignmentactivity'))} AS ala
UNION ALL SELECT
vca.variantcallingactivity_id,
'variantcallingactivity',
vca.used_file_id,
vca.generated_file_id
FROM {backtick(self._full_table_name(source, 'variantcallingactivity'))} AS vca
UNION ALL SELECT
a.activity_id,
'activity',
Expand Down Expand Up @@ -555,6 +570,12 @@ def convert_column(value):
'activity_type',
'assay_type',
'data_modality',
},
'variantcallingactivity': {
'variatncallingactivity_id',
'activity_type',
'reference_assembly',
'data_modality'
}
}

Expand Down

0 comments on commit 26237c0

Please sign in to comment.