Skip to content

Commit

Permalink
Merge pull request #6 from shadchin/py39
Browse files Browse the repository at this point in the history
Add support Python 3.9
  • Loading branch information
idlesign committed Dec 9, 2020
2 parents 44e544f + 40ee300 commit a9d7b9c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 8 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Expand Up @@ -3,6 +3,7 @@ dist: xenial
language: python

python:
- 3.9
- 3.8
- 3.7
- 3.6
Expand Down
10 changes: 3 additions & 7 deletions pycbrf/banks.py
Expand Up @@ -14,11 +14,7 @@
LOG = getLogger(__name__)


class _BankBase(NamedTuple):
"""Base from banks."""


class BankLegacy(_BankBase, NamedTuple):
class BankLegacy(NamedTuple):
"""Represents bank entry in legacy format.
Such objects will populate Banks().banks
Expand Down Expand Up @@ -53,7 +49,7 @@ class BankLegacy(_BankBase, NamedTuple):
swift: Optional[str]


class Bank(_BankBase, NamedTuple):
class Bank(NamedTuple):
"""Represents bank entry in current format.
Such objects will populate Banks().banks
Expand Down Expand Up @@ -217,7 +213,7 @@ def pick_value(in_dict):
# Some fields may be missing in Bank/BankLegacy
continue

if isinstance(value, _BankBase):
if isinstance(value, (BankLegacy, Bank)):
value = pick_value(value._asdict())

elif isinstance(value, bool):
Expand Down
1 change: 1 addition & 0 deletions setup.py
Expand Up @@ -66,6 +66,7 @@ def get_version():
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'License :: OSI Approved :: BSD License',
],
)
2 changes: 1 addition & 1 deletion tox.ini
@@ -1,6 +1,6 @@
# See http://tox.readthedocs.org/en/latest/examples.html for samples.
[tox]
envlist = py{36,37,38}
envlist = py{36,37,38,39}

skip_missing_interpreters = True

Expand Down

0 comments on commit a9d7b9c

Please sign in to comment.