summaryrefslogtreecommitdiff
path: root/errors.py
diff options
context:
space:
mode:
authorroot <root@turin.home>2022-02-04 18:07:47 +0000
committerroot <root@turin.home>2022-02-04 18:07:47 +0000
commit6671090e31ab30711f169abfb61d880b50ba27d8 (patch)
tree8952c13c358694c423f67e5e1e09223ed090a326 /errors.py
parent0e23673e015a5261019a151f22b419f4c80b7e8d (diff)
Dictionary class. Reformat.
Diffstat (limited to 'errors.py')
-rw-r--r--errors.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/errors.py b/errors.py
index 5e7394b..b367263 100644
--- a/errors.py
+++ b/errors.py
@@ -1,3 +1,6 @@
+import os
+
+
def device_error():
print(
"""
@@ -7,4 +10,17 @@ def device_error():
- Raspberry Pi 4
"""
)
+ os._exit(1)
+ quit()
+
+
+def argument_error(data, datatype):
+ print(
+ """
+ Invalid data type {} for {}
+ """.format(
+ data, datatype
+ )
+ )
+ os._exit(1)
quit()