Skip to content

Commit

Permalink
fix + paired end xlsx example
Browse files Browse the repository at this point in the history
  • Loading branch information
bedroesb committed Dec 7, 2024
1 parent ed08d89 commit 5d47b99
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions ena_upload/ena_upload.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,8 +222,8 @@ def generate_stream(schema, targets, Template, center, tool):
targets.rename(columns={'file_format': 'file_type'}, inplace=True)
file_attrib = ['file_name', 'file_type', 'file_checksum']
other_attrib = ['alias', 'experiment_alias']
run_groups = targets[other_attrib].groupby(targets['alias'])
run_groups = run_groups.experiment_alias.unique()
# Create groups with alias as index
run_groups = targets[other_attrib].groupby('alias')['experiment_alias'].first().to_dict()
file_groups = targets[file_attrib].groupby(targets['alias'])

# param in generate() determined by the setup in template
Expand Down
2 changes: 1 addition & 1 deletion ena_upload/templates/ENA_template_runs.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def mandatorytest(row, column, index):
<EXPERIMENT_REF refname="${experiment_alias}"/>
<DATA_BLOCK>
<FILES>
<py:for each="index, row in file_groups.get_group((alias,)).iterrows()">
<py:for each="index, row in file_groups.get_group(alias).iterrows()">
<py:if test="mandatorytest(row, 'file_type', index)">
<xi:include href="ENA_template_FILE.xml" />
</py:if>
Expand Down
Binary file modified example_tables/ENA_excel_example_ERC000033.xlsx
Binary file not shown.

0 comments on commit 5d47b99

Please sign in to comment.