coveralls: 
[![Coverage Status](https://coveralls.io/builds/8472505/badge)](https://coveralls.io/builds/8472505)

Coverage remained the same at 100.0% when pulling **ad80837a4268266baeb9cebaa1d793a4d0bc46fb on michaelgaida:TC-26** into **5c373dd2992d4404e9a0e5fc0c5195f58c7ddb7a on gerva:master**.

coveralls: 
[![Coverage Status](https://coveralls.io/builds/8473235/badge)](https://coveralls.io/builds/8473235)

Coverage remained the same at 100.0% when pulling **2ac2caa48f1e7562fef046d4e62dc28cfec0ff63 on michaelgaida:TC-26** into **5c373dd2992d4404e9a0e5fc0c5195f58c7ddb7a on gerva:master**.

diff --git a/lib/api.py b/lib/api.py
index 6d76e18..a131931 100644
--- a/lib/api.py
+++ b/lib/api.py
@@ -8,6 +8,7 @@ import json
 import requests
 import lib.validate as validate
 from lib.adhoc import AdHocError
+from lib.configuration import ConfigError
 
 
 class APIError(Exception):
@@ -27,7 +28,13 @@ class APIv1(object):
     # E: Instance of 'LookupDict' has no 'created' member (no-member)
     def __init__(self, config):
         self.config = config
-        self.host = config.get('host')
+        try:
+            self.host = config.get('host')
+        except ConfigError as error:
+            msg = "Missing key from configuration, {0}.".format(error)
+            msg = "{0} Please check your configuration.".format(msg)
+            raise APIError(msg)
+
         self.api_url = "https://{0}/api/v1".format(self.host)
 
     def _authentication(self):
@@ -38,14 +45,25 @@ class APIv1(object):
             (tuple) username, password
         """
         config = self.config
-        return (config.get('username'), config.get('password'))
+        try:
+            return (config.get('username'), config.get('password'))
+        except ConfigError as error:
+            msg = "Missing key from configuration, {0}.".format(error)
+            msg = "{0} Please check your configuration.".format(msg)
+            raise APIError(msg)
 
     def _verify_ssl(self):
         """
         Gets the value of verify_ssl from the actual configuraion
         """
         config = self.config
-        return config.getboolean('verify_ssl')
+        try:
+            return config.getboolean('verify_ssl')
+        except ConfigError as error:
+            msg = "Missing key from configuration, {0}.".format(error)
+            msg = "{0} Please check your configuration.".format(msg)
+            raise APIError(msg)
+
 
     def _get(self, url, params, data):
         auth = self._authentication()

When no configuration file is set, `kick` raises a ConfigError
we should intercept the ConfigError and explain what's wrong with the configuration, instead of just printing the full stack trace
diff --git a/test/test_api.py b/test/test_api.py
index 50b1a85..31d8d27 100644
--- a/test/test_api.py
+++ b/test/test_api.py
@@ -135,6 +135,25 @@ def test_get_json_error(monkeypatch):
     with pytest.raises(APIError):
         api._get_json(url='', params={}, data={})
 
+def test_less_configuration():
+    config = Config(None)
+    with pytest.raises(APIError):
+        api = APIv1(config)
+
+    config.update('host', HOST)
+    api = APIv1(config)
+    with pytest.raises(APIError):
+        api._authentication()
+
+    config.update('username', USERNAME)
+    api = APIv1(config)
+    with pytest.raises(APIError):
+        api._authentication()
+
+    config.update('password', PASSWORD)
+    api = APIv1(config)
+    with pytest.raises(APIError):
+        api._verify_ssl()
 
 def test_job_params(monkeypatch):
     def mockreturn(*args, **kwargs):

pip install -e .
parse_log_pytest
requirements.txt
pytest coverage prospector
apt-get update apt-get install -y gcc
3.5
requirements/base.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
astroid==2.11.7
attrs==22.2.0
certifi==2021.5.30
click==6.6
coverage==6.2
dill==0.3.4
dodgy==0.2.1
flake8==4.0.1
flake8-polyfill==1.0.2
importlib-metadata==4.2.0
iniconfig==1.1.1
isort==5.10.1
lazy-object-proxy==1.7.1
mccabe==0.6.1
packaging==21.3
pep8-naming==0.10.0
platformdirs==2.4.0
pluggy==1.0.0
prospector==1.7.7
py==1.11.0
pycodestyle==2.8.0
pydocstyle==6.3.0
pyflakes==2.4.0
pylint==2.13.9
pylint-celery==0.3
pylint-django==2.5.3
pylint-flask==0.6
pylint-plugin-utils==0.7
pyparsing==3.1.4
pytest==7.0.1
PyYAML==3.12
requests==2.11.1
requirements-detector==0.7
setoptconf-tmp==0.3.1
snowballstemmer==2.2.0
toml==0.10.2
tomli==1.2.3
-e git+https://github.com/gerva/tower-companion.git@5c373dd2992d4404e9a0e5fc0c5195f58c7ddb7a#egg=tower_companion
typed-ast==1.5.5
typing_extensions==4.1.1
wrapt==1.16.0
zipp==3.6.0

name: tower-companion
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2021.5.30=py36h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.3=he6710b0_2
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=21.2.2=py36h06a4308_0
  - python=3.6.13=h12debd9_1
  - readline=8.2=h5eee18b_0
  - setuptools=58.0.4=py36h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.37.1=pyhd3eb1b0_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - astroid==2.11.7
      - attrs==22.2.0
      - click==6.6
      - coverage==6.2
      - dill==0.3.4
      - dodgy==0.2.1
      - flake8==4.0.1
      - flake8-polyfill==1.0.2
      - importlib-metadata==4.2.0
      - iniconfig==1.1.1
      - isort==5.10.1
      - lazy-object-proxy==1.7.1
      - mccabe==0.6.1
      - packaging==21.3
      - pep8-naming==0.10.0
      - platformdirs==2.4.0
      - pluggy==1.0.0
      - prospector==1.7.7
      - py==1.11.0
      - pycodestyle==2.8.0
      - pydocstyle==6.3.0
      - pyflakes==2.4.0
      - pylint==2.13.9
      - pylint-celery==0.3
      - pylint-django==2.5.3
      - pylint-flask==0.6
      - pylint-plugin-utils==0.7
      - pyparsing==3.1.4
      - pytest==7.0.1
      - pyyaml==3.12
      - requests==2.11.1
      - requirements-detector==0.7
      - setoptconf-tmp==0.3.1
      - snowballstemmer==2.2.0
      - toml==0.10.2
      - tomli==1.2.3
      - typed-ast==1.5.5
      - typing-extensions==4.1.1
      - wrapt==1.16.0
      - zipp==3.6.0
prefix: /opt/conda/envs/tower-companion

test/test_api.py::test_less_configuration
test/test_api.py::test_api test/test_api.py::test_verify_ssl test/test_api.py::test_get test/test_api.py::test_get_error test/test_api.py::test_post test/test_api.py::test_post_error test/test_api.py::test_get_json test/test_api.py::test_get_json_error test/test_api.py::test_job_params test/test_api.py::test_get_ids test/test_api.py::test_get_ids_zero_results test/test_api.py::test_launch_template_id test/test_api.py::test_launch_data_to_url test/test_api.py::test_job_stdout test/test_api.py::test_job_status test/test_api.py::test_job_finished test/test_api.py::test_job_started test/test_api.py::test_get_data test/test_api.py::test_ad_hoc_to_api test/test_api.py::test_launch_ad_hoc_job test/test_api.py::test_job_url
lib/api.py
lib/api.py