diff --git a/RELEASE_NOTES.md b/RELEASE_NOTES.md index 0ec4a45..f3f3d1c 100755 --- a/RELEASE_NOTES.md +++ b/RELEASE_NOTES.md @@ -1,3 +1,6 @@ +# 1.3.1 - 11/12/2018 + - input compatible with python3 + # 1.3.0 - 11/6/2018 - Add createReferencedFile (/hsapi/scimeta/\/) - Add updateReferencedFile (/hsapi/resource/\/scimeta/elements) diff --git a/hs_restclient/__init__.py b/hs_restclient/__init__.py index 2d27a9b..f0c5a30 100755 --- a/hs_restclient/__init__.py +++ b/hs_restclient/__init__.py @@ -5,7 +5,7 @@ """ __title__ = 'hs_restclient' -__version__ = '1.3.0' +__version__ = '1.3.1' import os @@ -35,6 +35,12 @@ EXPIRES_AT_ROUNDDOWN_SEC = 15 +# bind raw_input to input for Python 2 and 3 compatibility +try: + input = raw_input +except NameError: + pass + def default_progress_callback(monitor): pass @@ -70,7 +76,7 @@ def __init__(self, hostname=DEFAULT_HOSTNAME, port=None, use_https=True, verify= self.auth = auth elif prompt_auth: import getpass - username = raw_input("Username: ").strip() + username = input("Username: ").strip() password = getpass.getpass("Password for {}: ".format(username)) auth = HydroShareAuthBasic(username=username, password=password) self.auth = auth diff --git a/setup.py b/setup.py index aab243a..0c05355 100755 --- a/setup.py +++ b/setup.py @@ -15,7 +15,7 @@ # Versions should comply with PEP440. For a discussion on single-sourcing # the version across setup.py and the project code, see # https://packaging.python.org/en/latest/single_source_version.html - version='1.3.0', + version='1.3.1', description='HydroShare REST API client library', long_description=long_description,