-
-
Notifications
You must be signed in to change notification settings - Fork 738
Closed
Labels
Description

I have no idea why this is happening. Looking at the traceback, it looks like a package error.
watch.py
from watchdog.observers import Observer
from watchdog.events import FileSystemEventHandler
class Mod_handler(FileSystemEventHandler):
def on_modified(self, event):
if(event.src_path == "/database.json"):
print("Execute your logic here!")
print("on_modified", event.src_path)
event_handler = Mod_handler()
observer = Observer()
observer.schedule(event_handler, path='/', recursive=False)
observer.start()
def start():
observer.start()bot.py
# some unrelated code here
import watch
watch.start()
# some unrelated code here