Compare commits

...

2 Commits

Author SHA1 Message Date
John Lancaster
9c12df1256 changed port 2024-03-18 17:42:42 -05:00
John Lancaster
af433e7eb9 added module import printing 2024-03-18 17:42:29 -05:00
3 changed files with 15 additions and 5 deletions

View File

@@ -12,7 +12,7 @@ appdaemon:
ha_url: http://192.168.1.82:8123
token: !secret long_lived_token
http:
url: http://0.0.0.0:5050
url: http://0.0.0.0:5051
admin:
api:
hadashboard:

View File

@@ -1,2 +1,6 @@
print(f' Importing {__name__} '.center(50, '='))
from .motion import Motion
from .my_sub_pkg.hello import HelloWorldSub
from .my_sub_pkg.hello import HelloWorldSub
print(' Done '.center(50, '='))

View File

@@ -1,8 +1,14 @@
from pathlib import Path
import appdaemon.adbase as ad
print(f' Importing {Path(__file__).name} '.center(50, '-'))
class Motion(ad.ADBase):
def initialize(self):
self.adapi = self.get_ad_api()
self.log = self.adapi.log
self.log(f'Initialized app from {__file__}')
# self.log(f'New log line asdfasdf')
self.changes = False
self.adapi.log(f'Initialized app from {__file__} new line changes: {self.changes}')
print(f'Done, motion.changes = {Motion.changes}'.center(50, '-'))