Skip to content

Commit

Permalink
Merge pull request #345 from inspirehep/fix-values
Browse files Browse the repository at this point in the history
pipelines: fix values
  • Loading branch information
drjova authored Oct 27, 2023
2 parents 812e968 + b1bcb28 commit ffb1c3e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions hepcrawl/pipelines.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,10 @@ def process_item(self, item, spider):
crawl_result = CrawlResult.from_parsed_item(item).to_dict()
self.results_data.append(crawl_result)

titles = get_value(crawl_result, "titles.title", default=[])
dois = get_value(crawl_result, "dois.value", default=[])
arxiv_eprints = get_value(crawl_result, "arxiv_eprints.value", default=[])
report_numbers = get_value(crawl_result, "report_numbers.value", default=[])
titles = get_value(crawl_result, "record.titles.title", default=[])
dois = get_value(crawl_result, "record.dois.value", default=[])
arxiv_eprints = get_value(crawl_result, "record.arxiv_eprints.value", default=[])
report_numbers = get_value(crawl_result, "record.report_numbers.value", default=[])

for doi in dois:
self.dois.append(doi)
Expand Down

0 comments on commit ffb1c3e

Please sign in to comment.