diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/phenotypes_bulk_edit.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/phenotypes_bulk_edit.py b/scripts/phenotypes_bulk_edit.py index 30933a6..7de3347 100644 --- a/scripts/phenotypes_bulk_edit.py +++ b/scripts/phenotypes_bulk_edit.py @@ -105,7 +105,11 @@ def compute_differences( # b. Publications differences db_publications = fetch_phenotype_publications(conn, pheno_xref_ids) new_publications = create_new_publications( - conn, pmed.fetch_publications(new_pubmed_ids)) + conn, pmed.fetch_publications(tuple( + pubmed_id for pubmed_id in pubmed_ids + if pubmed_id not in + tuple(row["PubMed_ID"] for row in db_publications)))) + logger.debug("New Publications: %s", new_publications) pub_diff = publications_differences( file_contents, db_publications, { row["PubMed_ID"]: row["PublicationId"] |