Skip to content
This repository was archived by the owner on Oct 5, 2023. It is now read-only.

Commit 70a8d9e

Browse files
committed
Add issue to the top level of the article
1 parent c579112 commit 70a8d9e

5 files changed

Lines changed: 12 additions & 4 deletions

File tree

.zenodo.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"description": "Translates isi web of knowledge files into python objects.",
33
"license": "MIT",
44
"title": "coreofscience/python-wostools",
5-
"version": "v2.0.2",
5+
"version": "v2.0.3",
66
"upload_type": "software",
77
"publication_date": "2018-08-13",
88
"creators": [
@@ -25,7 +25,7 @@
2525
"related_identifiers": [
2626
{
2727
"scheme": "url",
28-
"identifier": "https://github.com/coreofscience/python-wostools/tree/v2.0.2",
28+
"identifier": "https://github.com/coreofscience/python-wostools/tree/v2.0.3",
2929
"relation": "isSupplementTo"
3030
},
3131
{

HISTORY.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# History
22

3+
## 2.0.3 (2020-08-09)
4+
5+
- Add issue to the articles top level.
6+
37
## 2.0.2 (2020-08-09)
48

59
- Fix bug with first author merging articles.

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
test_suite="tests",
4343
tests_require=test_requirements,
4444
url="https://github.com/coreofscience/python-wostools",
45-
version="2.0.2",
45+
version="2.0.3",
4646
zip_safe=False,
4747
long_description_content_type="text/markdown",
4848
)

wostools/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
__author__ = """Core of Science"""
44
__email__ = "dev@coreofscience.com"
5-
__version__ = "2.0.2"
5+
__version__ = "2.0.3"
66

77
from wostools.article import Article
88
from wostools.lazy import LazyCollection

wostools/article.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ def __init__(
3333
year: Optional[int],
3434
journal: Optional[str],
3535
volume: Optional[str] = None,
36+
issue: Optional[str] = None,
3637
page: Optional[str] = None,
3738
doi: Optional[str] = None,
3839
references: Optional[List[str]] = None,
@@ -46,6 +47,7 @@ def __init__(
4647
self.year: Optional[int] = year
4748
self.journal: Optional[str] = journal
4849
self.volume: Optional[str] = volume
50+
self.issue: Optional[str] = volume
4951
self.page: Optional[str] = page
5052
self.doi: Optional[str] = doi
5153
self.references: List[str] = references or []
@@ -111,6 +113,7 @@ def merge(self, other: "Article") -> "Article":
111113
year=self.year or other.year,
112114
journal=self.journal or other.journal,
113115
volume=self.volume or other.volume,
116+
issue=self.issue or other.issue,
114117
page=self.page or other.page,
115118
doi=self.doi or other.doi,
116119
sources={*self.sources, *other.sources},
@@ -139,6 +142,7 @@ def from_isi_text(cls, raw: str) -> "Article":
139142
year=processed.get("year"),
140143
journal=processed.get("source_abbreviation"),
141144
volume=processed.get("volume"),
145+
issue=processed.get("issue"),
142146
page=processed.get("beginning_page"),
143147
doi=processed.get("DOI"),
144148
references=processed.get("references"),

0 commit comments

Comments
 (0)