From b07ab253b7a2adec01233989d983d2f180c9fe4e Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Mon, 31 Dec 2012 12:23:42 +1300 Subject: Require requests > 1.0.4 This changes the API slightly, since json is now a method, not a property. --- libpathod/test.py | 4 ++-- pathod | 2 +- setup.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/libpathod/test.py b/libpathod/test.py index e431be18..ed0ee26a 100644 --- a/libpathod/test.py +++ b/libpathod/test.py @@ -30,7 +30,7 @@ class Daemon: Return some basic info about the remote daemon. """ resp = requests.get("%s/api/info"%self.urlbase, verify=False) - return resp.json + return resp.json() def last_log(self): """ @@ -47,7 +47,7 @@ class Daemon: Return the log buffer as a list of dictionaries. """ resp = requests.get("%s/api/log"%self.urlbase, verify=False) - return resp.json["log"] + return resp.json()["log"] def clear_log(self): """ diff --git a/pathod b/pathod index 09facad4..27e7e040 100755 --- a/pathod +++ b/pathod @@ -166,7 +166,7 @@ if __name__ == "__main__": group = parser.add_argument_group( - 'Controlling Logging', + 'Controlling Logging', """ Some of these options expand generated values for logging - if you're generating large data, use them with caution. diff --git a/setup.py b/setup.py index 4df247b2..0653ee70 100644 --- a/setup.py +++ b/setup.py @@ -89,5 +89,5 @@ setup( "Topic :: Software Development :: Testing :: Traffic Generation", "Topic :: Internet :: WWW/HTTP", ], - install_requires=['netlib>=0.2.2', "requests>=0.13", "flask"], + install_requires=['netlib>=0.2.2', "requests>=1.0.4", "flask"], ) -- cgit v1.2.3