tighten up error reporting (#1269)

* black reformat

* tighten up error reporting

* lint

* fine tuning

* additional improvements in exception handling

* lint

* include exception and traceback in log

* fix typo
This commit is contained in:
Bruce Martin
2020-03-22 09:55:47 -07:00
committed by GitHub
parent 8180be83b8
commit db7a485796
9 changed files with 124 additions and 129 deletions
+4 -4
View File
@@ -41,7 +41,7 @@ class ViewDataset(TaskSet):
with self.client.get(
f"{self.dataset}{API}/annotations/var?annotation-name={self.var_index_name()}",
headers={"Accept": "application/octet-stream"},
catch_response=True
catch_response=True,
) as r:
if r.status_code == 200:
df = decode_fbs.decode_matrix_FBS(r.content)
@@ -112,7 +112,7 @@ class ViewDataset(TaskSet):
self.client.get(
f"{self.dataset}{API}/annotations/var?annotation-name={self.parent.var_index_name()}",
headers={"Accept": "application/octet-stream"},
stream=True
stream=True,
).close()
group = Group()
@@ -126,7 +126,7 @@ class ViewDataset(TaskSet):
self.client.get(
f"{self.dataset}{API}/annotations/obs?annotation-name={name}",
headers={"Accept": "application/octet-stream"},
stream=True
stream=True,
).close()
obs_names = self.parent.obs_annotation_names()
@@ -150,7 +150,7 @@ class ViewDataset(TaskSet):
f"{self.dataset}{API}/data/var",
data=json.dumps(filter),
headers={"Content-Type": "application/json", "Accept": "application/octet-stream"},
stream=True
stream=True,
).close()