From 2be2a97769b2debe58e42b6ead991da6f6605f8b Mon Sep 17 00:00:00 2001 From: Joe Germuska Date: Sun, 26 Jun 2016 17:04:45 -0500 Subject: [PATCH] straggling change --- censusreporter_api.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/censusreporter_api.py b/censusreporter_api.py index 6d4c2f8..e3e5967 100644 --- a/censusreporter_api.py +++ b/censusreporter_api.py @@ -82,6 +82,8 @@ def get_dataframe(tables=None, geoids=None, release='latest',level=None,place_na """ response = json_data(tables, geoids, release) + if 'error' in response: + raise Exception(response['error']) df = pd.DataFrame.from_dict(_prep_data_for_pandas(response),orient='index') df = df.reindex_axis(sorted(df.columns), axis=1) if column_names or level is not None: