Skip to content

Commit

Permalink
Merge pull request #78 from usegalaxy-eu/checklist_update
Browse files Browse the repository at this point in the history
Automatic update of ENA Sample Checklists
  • Loading branch information
bgruening authored Apr 10, 2023
2 parents 7605d87 + 26c67b6 commit 07a4018
Show file tree
Hide file tree
Showing 11 changed files with 94 additions and 32 deletions.
12 changes: 6 additions & 6 deletions ena_upload/templates/ENA_template_samples_ERC000011.xml
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,6 @@ def attributetest(row, column):
<VALUE>${row['tissue_type']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'collection_date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection_date</TAG>
<VALUE>${row['collection_date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'isolation_source')">
<SAMPLE_ATTRIBUTE>
<TAG>isolation_source</TAG>
Expand All @@ -76,6 +70,12 @@ def attributetest(row, column):
<VALUE>${row['collected_by']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'collection date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
Expand Down
14 changes: 10 additions & 4 deletions ena_upload/templates/ENA_template_samples_ERC000027.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,6 @@ def attributetest(row, column):
</SAMPLE_NAME>
<DESCRIPTION>${row.sample_description}</DESCRIPTION>
<SAMPLE_ATTRIBUTES>
<SAMPLE_ATTRIBUTE>
<TAG>Event Date/Time</TAG>
<VALUE>${row['Event Date/Time']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>Latitude Start</TAG>
<VALUE>${row['Latitude Start']}</VALUE>
Expand Down Expand Up @@ -224,6 +220,16 @@ def attributetest(row, column):
<TAG>environmental package</TAG>
<VALUE>${row['environmental package']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>broad-scale environmental context</TAG>
<VALUE>${row['broad-scale environmental context']}</VALUE>
Expand Down
14 changes: 14 additions & 0 deletions ena_upload/templates/ENA_template_samples_ERC000030.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,12 @@ def attributetest(row, column):
<VALUE>${row['Event Label']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'Event Date/Time Start')">
<SAMPLE_ATTRIBUTE>
<TAG>Event Date/Time Start</TAG>
<VALUE>${row['Event Date/Time Start']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'Event Date/Time End')">
<SAMPLE_ATTRIBUTE>
<TAG>Event Date/Time End</TAG>
Expand Down Expand Up @@ -109,6 +111,18 @@ def attributetest(row, column):
<TAG>environmental package</TAG>
<VALUE>${row['environmental package']}</VALUE>
</SAMPLE_ATTRIBUTE>
<py:if test="attributetest(row, 'collection date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>broad-scale environmental context</TAG>
<VALUE>${row['broad-scale environmental context']}</VALUE>
Expand Down
12 changes: 12 additions & 0 deletions ena_upload/templates/ENA_template_samples_ERC000034.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,18 @@ def attributetest(row, column):
<TAG>tissue_type</TAG>
<VALUE>${row['tissue_type']}</VALUE>
</SAMPLE_ATTRIBUTE>
<py:if test="attributetest(row, 'collection date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>sex</TAG>
<VALUE>${row['sex']}</VALUE>
Expand Down
12 changes: 12 additions & 0 deletions ena_upload/templates/ENA_template_samples_ERC000035.xml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,18 @@ def attributetest(row, column):
<VALUE>${row['protocol']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'collection date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'sampling time point')">
<SAMPLE_ATTRIBUTE>
<TAG>sampling time point</TAG>
Expand Down
14 changes: 10 additions & 4 deletions ena_upload/templates/ENA_template_samples_ERC000038.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,6 @@ def attributetest(row, column):
</SAMPLE_NAME>
<DESCRIPTION>${row.sample_description}</DESCRIPTION>
<SAMPLE_ATTRIBUTES>
<SAMPLE_ATTRIBUTE>
<TAG>Event Date/Time</TAG>
<VALUE>${row['Event Date/Time']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>Latitude Start</TAG>
<VALUE>${row['Latitude Start']}</VALUE>
Expand All @@ -51,6 +47,16 @@ def attributetest(row, column):
<TAG>Protocol Label</TAG>
<VALUE>${row['Protocol Label']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>broad-scale environmental context</TAG>
<VALUE>${row['broad-scale environmental context']}</VALUE>
Expand Down
12 changes: 6 additions & 6 deletions ena_upload/templates/ENA_template_samples_ERC000041.xml
Original file line number Diff line number Diff line change
Expand Up @@ -59,18 +59,18 @@ def attributetest(row, column):
<UNITS>ng/µl</UNITS>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'collection_date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection_date</TAG>
<VALUE>${row['collection_date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'isolation_source')">
<SAMPLE_ATTRIBUTE>
<TAG>isolation_source</TAG>
<VALUE>${row['isolation_source']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'collection date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
Expand Down
8 changes: 4 additions & 4 deletions ena_upload/templates/ENA_template_samples_ERC000044.xml
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,14 @@ def attributetest(row, column):
<VALUE>${row['country of travel']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>collection_date</TAG>
<VALUE>${row['collection_date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>collected_by</TAG>
<VALUE>${row['collected_by']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
Expand Down
8 changes: 4 additions & 4 deletions ena_upload/templates/ENA_template_samples_ERC000045.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,6 @@ def attributetest(row, column):
</SAMPLE_NAME>
<DESCRIPTION>${row.sample_description}</DESCRIPTION>
<SAMPLE_ATTRIBUTES>
<SAMPLE_ATTRIBUTE>
<TAG>collection_date</TAG>
<VALUE>${row['collection_date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>isolation_source</TAG>
<VALUE>${row['isolation_source']}</VALUE>
Expand All @@ -36,6 +32,10 @@ def attributetest(row, column):
<VALUE>${row['collected_by']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
Expand Down
8 changes: 4 additions & 4 deletions ena_upload/templates/ENA_template_samples_ERC000048.xml
Original file line number Diff line number Diff line change
Expand Up @@ -244,14 +244,14 @@ def attributetest(row, column):
<VALUE>${row['WGA amplification kit']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>collection_date</TAG>
<VALUE>${row['collection_date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>isolation_source</TAG>
<VALUE>${row['isolation_source']}</VALUE>
</SAMPLE_ATTRIBUTE>
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
<py:if test="attributetest(row, 'altitude')">
<SAMPLE_ATTRIBUTE>
<TAG>altitude</TAG>
Expand Down
12 changes: 12 additions & 0 deletions ena_upload/templates/ENA_template_samples_ERC000051.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,18 @@ def attributetest(row, column):
</SAMPLE_NAME>
<DESCRIPTION>${row.sample_description}</DESCRIPTION>
<SAMPLE_ATTRIBUTES>
<py:if test="attributetest(row, 'collection date')">
<SAMPLE_ATTRIBUTE>
<TAG>collection date</TAG>
<VALUE>${row['collection date']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<py:if test="attributetest(row, 'geographic location (country and/or sea)')">
<SAMPLE_ATTRIBUTE>
<TAG>geographic location (country and/or sea)</TAG>
<VALUE>${row['geographic location (country and/or sea)']}</VALUE>
</SAMPLE_ATTRIBUTE>
</py:if>
<SAMPLE_ATTRIBUTE>
<TAG>sample origin</TAG>
<VALUE>${row['sample origin']}</VALUE>
Expand Down

0 comments on commit 07a4018

Please sign in to comment.