From e838f167afa1b65ca7566c4ef195d4852b4e0ab1 Mon Sep 17 00:00:00 2001 From: Tristan Escalada Date: Sat, 31 Mar 2018 11:34:17 -0400 Subject: [PATCH 1/3] changing the name of the json param in create_api_key this conflicts with the import of json, renamed to json_data --- grafana_api/grafana_face.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/grafana_api/grafana_face.py b/grafana_api/grafana_face.py index e177a4c..d5380bd 100644 --- a/grafana_api/grafana_face.py +++ b/grafana_api/grafana_face.py @@ -565,14 +565,14 @@ def get_api_keys(self): r = self.api.GET(get_api_keys_path) return r - def create_api_key(self, json): + def create_api_key(self, json_data): """ - :param json: + :param json_data: :return: """ create_api_key_path = '/auth/keys' - r = self.api.POST(create_api_key_path, json=json) + r = self.api.POST(create_api_key_path, json=json_data) return r def delete_api_key(self, id): From 47c871d0c0a505d262b67371f38e11681dc663bc Mon Sep 17 00:00:00 2001 From: Tristan Escalada Date: Sat, 31 Mar 2018 11:35:15 -0400 Subject: [PATCH 2/3] removing the unused json import this is currently unused, can be readded if needed later --- grafana_api/grafana_face.py | 1 - 1 file changed, 1 deletion(-) diff --git a/grafana_api/grafana_face.py b/grafana_api/grafana_face.py index d5380bd..3cbce48 100644 --- a/grafana_api/grafana_face.py +++ b/grafana_api/grafana_face.py @@ -1,4 +1,3 @@ -import json from .grafana_api import GrafanaAPI From bfed50bd93a9fcb1cc431db91cbba0542198b051 Mon Sep 17 00:00:00 2001 From: Tristan Escalada Date: Sat, 31 Mar 2018 11:36:54 -0400 Subject: [PATCH 3/3] adding nose to the install dependencies nose needs to be installed to run the tests on a fresh system --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 33e97ab..717e6b2 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,6 +15,7 @@ install: - pip install requests - pip install python-coveralls - pip install coverage + - pip install nose # command to run tests script: