Repository: terminusdb/terminusdb-client-python (language: python)

Issue:
Expose errors
**Is your feature request related to a problem? Please describe.**
Now when I want to catch an error, I have to import it from `terminusdb_client.woqlclient.errors` which I think is not convinent

**Describe the solution you'd like**
I can do `form terminusdb_client import DatabaseError`

**Describe alternatives you've considered**
Either expose all the errors by import them to the top __init__ or put error.py to the top level (which may make more sense)




Discussion / hints:

Fix patch:
diff --git a/terminusdb_client/woqlclient/errors.py b/terminusdb_client/errors.py
similarity index 100%
rename from terminusdb_client/woqlclient/errors.py
rename to terminusdb_client/errors.py
diff --git a/terminusdb_client/woqlclient/woqlClient.py b/terminusdb_client/woqlclient/woqlClient.py
index f9cceb53..1a6670f4 100644
--- a/terminusdb_client/woqlclient/woqlClient.py
+++ b/terminusdb_client/woqlclient/woqlClient.py
@@ -12,8 +12,8 @@
 from urllib3.exceptions import InsecureRequestWarning
 
 from ..__version__ import __version__
+from ..errors import DatabaseError, InterfaceError
 from ..woqlquery.woql_query import WOQLQuery
-from .errors import DatabaseError, InterfaceError
 
 # WOQL client object
 # license Apache Version 2


Test patch:
diff --git a/terminusdb_client/tests/integration_tests/test_bank.py b/terminusdb_client/tests/integration_tests/test_bank.py
index d8f51b59..4b8e6bbe 100644
--- a/terminusdb_client/tests/integration_tests/test_bank.py
+++ b/terminusdb_client/tests/integration_tests/test_bank.py
@@ -1,6 +1,6 @@
 import pytest
 
-from terminusdb_client.woqlclient.errors import DatabaseError
+from terminusdb_client.errors import DatabaseError
 from terminusdb_client.woqlclient.woqlClient import WOQLClient
 from terminusdb_client.woqlquery.woql_query import WOQLQuery
 
diff --git a/terminusdb_client/tests/test_woqlClient.py b/terminusdb_client/tests/test_woqlClient.py
index edebb4c7..0a7f1cfc 100644
--- a/terminusdb_client/tests/test_woqlClient.py
+++ b/terminusdb_client/tests/test_woqlClient.py
@@ -7,7 +7,7 @@
 import requests
 
 from terminusdb_client.__version__ import __version__
-from terminusdb_client.woqlclient.errors import InterfaceError
+from terminusdb_client.errors import InterfaceError
 from terminusdb_client.woqlclient.woqlClient import WOQLClient
 
 from .mockResponse import MOCK_CAPABILITIES