Skip to content

Commit f8f0a6d

Browse files
committed
Fixing comment position
1 parent 6859116 commit f8f0a6d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

qiita_db/metadata_template/base_metadata_template.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -842,6 +842,11 @@ def _add_common_extend_steps_to_queue(self, md_template, conn_handler,
842842
min_md_template = md_template[new_cols].loc[existing_samples]
843843
values = as_python_types(min_md_template, new_cols)
844844
values.append(existing_samples)
845+
# psycopg2 requires a list of tuples, in which each tuple is a
846+
# set of values to use in the string formatting of the query.
847+
# We have all the values in different lists (but in the same
848+
# order) so use zip to create the list of tuples that psycopg2
849+
# requires.
845850
values = [v for v in zip(*values)]
846851
set_str = ["{0} = %s".format(col) for col in new_cols]
847852
sql = """UPDATE qiita.{0}

0 commit comments

Comments
 (0)