simple fixes

This commit is contained in:
John Lancaster
2025-06-20 08:50:43 -05:00
parent ba043554dc
commit 475bdb9dd9
4 changed files with 25 additions and 21 deletions

View File

@@ -10,14 +10,15 @@ from appdaemon.adapi import ADAPI
# fake/
# SimpleApp
class HelloWorld(ADAPI):
def initialize(self):
def initialize(self) -> None:
self.log(f'{self.__class__.__name__} Initialized')
self.log('+' * 50)
# fake
self.register_service("my_domain/my_exciting_service", self.my_exciting_cb)
self.register_service('my_domain/my_exciting_service', self.my_exciting_cb)
def my_exciting_cb(self, *args: str, my_arg: int = 0, **kwargs: Any) -> Any:
namespace, domain, service = args
self.log(f"Service {domain}/{service} in the {namespace} namepsace called with {kwargs}")
self.log(f'Service {domain}/{service} in the {namespace} namepsace called with {kwargs}')
return 999 + my_arg