diff options
author | Alejandro Sirgo Rica <asirgo@soleta.eu> | 2024-08-08 14:25:00 +0200 |
---|---|---|
committer | Alejandro Sirgo Rica <asirgo@soleta.eu> | 2024-08-09 11:05:02 +0200 |
commit | 73ecb48113eb8d2a37cee89e3481415089867709 (patch) | |
tree | 1608a98f2347db2cd9397d5ab1860a6f25559486 /src/windows/ogOperations.py | |
parent | 71b3211d3d64cae19daf7e940516f47bc284450c (diff) |
src: log without backtrace in not implemented functions
Don't log a backtrace when a not implemented function is called
in ogClient.
Log a "Function not implemented" message.
Diffstat (limited to 'src/windows/ogOperations.py')
-rw-r--r-- | src/windows/ogOperations.py | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/windows/ogOperations.py b/src/windows/ogOperations.py index 45413ba..5ac9c9f 100644 --- a/src/windows/ogOperations.py +++ b/src/windows/ogOperations.py @@ -12,6 +12,7 @@ import subprocess from subprocess import CalledProcessError import multiprocessing as mp from multiprocessing import Process, freeze_support +from src.log import OgError from PIL import Image, ImageDraw from pystray import Icon, Menu, MenuItem @@ -68,7 +69,7 @@ class OgWindowsOperations: systray_p.start() def _restartBrowser(self, url): - raise NotImplementedError + raise OgError('Function not implemented') def poweroff(self): systray_p.terminate() @@ -96,25 +97,25 @@ class OgWindowsOperations: return (result.returncode, cmd, result.stdout) def session(self, request, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def hardware(self, path, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def setup(self, request, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def image_restore(self, request, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def image_create(self, path, request, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def cache_delete(self, request, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def cache_fetch(self, request, ogRest): - raise NotImplementedError + raise OgError('Function not implemented') def refresh(self, ogRest): return {"status": "WIN"} |