diff options
author | Bryan Newbold <bnewbold@archive.org> | 2019-10-04 15:51:38 -0700 |
---|---|---|
committer | Bryan Newbold <bnewbold@archive.org> | 2019-10-04 15:51:38 -0700 |
commit | 84a501f86dc9a6a2e25e58c7380575ed946c9357 (patch) | |
tree | e26ae69e413fa38d3f4dda198a0e0302cceb9873 /python | |
parent | 04c0882a3c216fd43cbb2643f2f8dbc257fd2338 (diff) | |
download | sandcrawler-84a501f86dc9a6a2e25e58c7380575ed946c9357.tar.gz sandcrawler-84a501f86dc9a6a2e25e58c7380575ed946c9357.zip |
remove any trailing newline
Diffstat (limited to 'python')
-rwxr-xr-x | python/grobid2json.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/python/grobid2json.py b/python/grobid2json.py index ae31486..df21883 100755 --- a/python/grobid2json.py +++ b/python/grobid2json.py @@ -125,8 +125,8 @@ def teixml2json(content, encumbered=True): if header is None: raise ValueError("XML does not look like TEI format") application_tag = header.findall('.//{%s}appInfo/{%s}application' % (ns, ns))[0] - info['grobid_version'] = application_tag.attrib['version'] - info['grobid_timestamp'] = application_tag.attrib['when'] + info['grobid_version'] = application_tag.attrib['version'].strip() + info['grobid_timestamp'] = application_tag.attrib['when'].strip() info['title'] = header.findtext('.//{%s}analytic/{%s}title' % (ns, ns)) info['authors'] = all_authors(header.find('.//{%s}sourceDesc/{%s}biblStruct' % (ns, ns))) info['journal'] = journal_info(header) |