From 44da4e040d53cd06d9ddcfddd0384a78dbdb0709 Mon Sep 17 00:00:00 2001 From: Colin Powell Date: Fri, 7 Feb 2025 18:16:42 -0500 Subject: [PATCH] Fix missing et and add Makefile --- Makefile | 2 ++ kowalski.py | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f159256 --- /dev/null +++ b/Makefile @@ -0,0 +1,2 @@ +run: + uv run kowalski.py diff --git a/kowalski.py b/kowalski.py index 774361a..0f60e81 100644 --- a/kowalski.py +++ b/kowalski.py @@ -23,7 +23,7 @@ cursor.execute(''' conn.commit() # Initialize Slack app -app = App(token=os.environ("SLACK_BOT_TOKEN")) +app = App(token=os.environ.get("SLACK_BOT_TOKEN")) def update_message_count(user_id): """Increment the message count for the user in SQLite.""" @@ -55,5 +55,5 @@ def handle_message_events(event, say): # Start the bot if __name__ == "__main__": - handler = SocketModeHandler(app, os.environ("SLACK_APP_TOKEN")) + handler = SocketModeHandler(app, os.environ.get("SLACK_APP_TOKEN")) handler.start()