From 16f7ab8c7060025bbbf8a63e76ae5d3da897c654 Mon Sep 17 00:00:00 2001 From: Kyle Conroy Date: Sun, 26 Feb 2012 22:23:02 -0800 Subject: [PATCH] Remove very broken JSON stuff --- httpbin/helpers.py | 5 +++-- run_httpbin.py | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/httpbin/helpers.py b/httpbin/helpers.py index fc899e7..3b73c8f 100644 --- a/httpbin/helpers.py +++ b/httpbin/helpers.py @@ -7,6 +7,7 @@ httpbin.helpers This module provides helper functions for httpbin. """ +import json from hashlib import md5 from werkzeug.http import parse_authorization_header @@ -95,9 +96,9 @@ def get_dict(*keys, **extras): form = nonflat_dict try: - json = json.loads(request.data) + json_input = json.loads(request.data) except ValueError: - json = None + json_input = None d = dict( diff --git a/run_httpbin.py b/run_httpbin.py index 1b44eea..1f604b3 100755 --- a/run_httpbin.py +++ b/run_httpbin.py @@ -12,5 +12,6 @@ except (IndexError, ValueError): port = 5000 print 'Starting httpbin on port {0}'.format(port) +app.debug = True http_server = WSGIServer(('', port), app) -http_server.serve_forever() \ No newline at end of file +http_server.serve_forever()