Skip to content

Commit 573fdb5

Browse files
committed
commit updates for release 0.2.7
1 parent 5826efe commit 573fdb5

File tree

6 files changed

+535
-5
lines changed

6 files changed

+535
-5
lines changed

CHANGELOG.md

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

3+
## Version 0.2.7
4+
5+
- Calling the `techport()` method without a project ID now returns data as expected. Thank you to user
6+
[Burzlurker](https://github.com/Burzlurker) for pointing this out and providing a fix!
7+
- Implemented a fix for when the `X-RateLimit-Remaining` header object was not available in the returned
8+
API data and thus caused an error.
9+
310
## Version 0.2.6
411

512
- `sentry` function now returns a summary object when `return_df=True` and a `des` or `spk` parameter are not specified.

docs/source/versions.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@
44
Version History
55
===============
66

7+
Version 0.2.7
8+
-------------
9+
10+
- Calling the :code:`techport()` method without a project ID now returns data as expected. Thank you to
11+
user `Burzlurker <https://github.com/Burzlurker>`_ for pointing this out and providing a fix!
12+
- Implemented a fix for when the :code:`X-RateLimit-Remaining` header object was not available in the returned
13+
API data and thus caused an error.
14+
715
Version 0.2.6
816
-------------
917

nasapy/api.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1467,7 +1467,7 @@ def techport(self, project_id=None, last_updated=None, return_format='json'):
14671467
params={'updatedSince': last_updated,
14681468
'api_key': self.__api_key})
14691469
else:
1470-
url = url + '{project_id}'.format(project_id=project_id)
1470+
url = url + '/{project_id}'.format(project_id=project_id)
14711471

14721472
if return_format == 'xml':
14731473
url = url + '.xml'
@@ -2907,7 +2907,10 @@ def _donki_request(key, url, start_date=None, end_date=None):
29072907
'endDate': end_date
29082908
})
29092909

2910-
limit_remaining = r.headers['X-RateLimit-Remaining']
2910+
if 'X-RateLimit-Remaining' not in r.headers:
2911+
limit_remaining = 'n/a'
2912+
else:
2913+
limit_remaining = r.headers['X-RateLimit-Remaining']
29112914

29122915
if r.status_code != 200:
29132916
raise requests.exceptions.HTTPError(r.reason, r.url)

setup.py

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

55
setup(
66
name='nasapy',
7-
version='0.2.6',
7+
version='0.2.7',
88
author='Aaron Schlegel',
99
author_email='aaron@aaronschlegel.me',
1010
description='Python wrapper for the NASA API',

0 commit comments

Comments
 (0)