Compare commits

..
20 Commits
Author SHA1 Message Date
imcompiling a15a35fcda Feat: Update uv.lock.
build_develop / build (push) Successful in 43s
2025-07-16 21:08:13 -04:00
imcompiling 44baf01a51 Feat: Update utils to use new models.
build_develop / build (push) Successful in 35s
Address many pylance smells. Ignoring some I don't know how to handle,
added some TODOs for handling others later.
2025-07-16 12:02:56 -04:00
imcompiling abc2950b21 Fix: Add default of None to speech ids. 2025-07-16 11:25:42 -04:00
imcompiling 1cc46ce2fd Feat: Rename DakinySettings -> dakiny_settings.
build_develop / build (push) Successful in 37s
Also handle the list error from pylance.
2025-07-16 10:55:15 -04:00
imcompiling bb2d6b62fe Feat: Remove pylance warnings in app.py.
Also removed old database setup.
2025-07-16 10:54:29 -04:00
imcompiling 77ce54f383 Remove: Old database files.
build_develop / build (push) Successful in 39s
2025-07-16 10:37:51 -04:00
imcompiling f81ebca4de Fix: errors on models from generating database. 2025-07-16 10:35:00 -04:00
imcompiling 2e66b1c37c Feat: Add database engine. 2025-07-16 10:26:26 -04:00
imcompiling ae1f98abe3 Add: ondelete to spelling settings.
build_develop / build (push) Successful in 19s
2025-07-16 09:10:05 -04:00
imcompiling 490c30e88c Add: PointsLimit model.
build_develop / build (push) Successful in 41s
2025-07-16 09:04:42 -04:00
imcompiling 35670358c4 Fix: Add default to points. 2025-07-16 09:00:22 -04:00
imcompiling 7a59f3b453 Add: Messages model. 2025-07-16 08:56:27 -04:00
imcompiling e01ab64411 Add: Points model. 2025-07-16 08:51:51 -04:00
imcompiling df482d80f0 Fix: Add boolean column types. 2025-07-16 08:51:39 -04:00
imcompiling 0d06d98060 Add: Presence model.
build_develop / build (push) Successful in 45s
2025-07-15 15:58:57 -04:00
imcompiling c267762efa Add: UserBirthday model.
build_develop / build (push) Successful in 38s
2025-07-15 15:45:26 -04:00
imcompiling e837cec46b Add: Vote model.
build_develop / build (push) Successful in 39s
2025-07-15 15:40:32 -04:00
imcompiling 0a856755c8 Add: CouncilMembers model.
build_develop / build (push) Successful in 44s
2025-07-15 15:05:15 -04:00
imcompiling eb8cfee7fd Feat: Add ElectionInformation table.
build_develop / build (push) Successful in 37s
2025-07-15 09:48:17 -04:00
imcompiling 6b5dc771d4 Feat: Install sqlmodel.
build_develop / build (push) Successful in 37s
2025-07-15 09:20:58 -04:00
2 changed files with 2 additions and 12 deletions
+2 -11
View File
@@ -4,7 +4,6 @@ import nextcord
from nextcord.ext import commands from nextcord.ext import commands
from dakiny_bot.app import birthday_list from dakiny_bot.app import birthday_list
from dakiny_bot.DakinySettings import settings
class SubmissionListener(commands.Cog, name="Message Listener"): class SubmissionListener(commands.Cog, name="Message Listener"):
@@ -17,15 +16,7 @@ class SubmissionListener(commands.Cog, name="Message Listener"):
async def on_message(self, message: nextcord.Message) -> None: async def on_message(self, message: nextcord.Message) -> None:
"""Listener for message creation. Adds score and attachments to submission.""" """Listener for message creation. Adds score and attachments to submission."""
# don't want to process any messages from bot. # don't want to process any messages from bot.
if message.author.id == self.bot.user.id: # pyright: ignore[reportOptionalMemberAccess] if message.author.id == self.bot.user.id:
return
# Ban all members who message in this channel. Everyone in guild is a member, so shouldn't miss a ban
# due to message.author not being a nextcord.Member object.
if message.channel.id == settings.channel_ids.ban and isinstance(message.author, nextcord.Member):
await message.author.ban(
delete_message_seconds=30 * 60, reason="Probable spam. The ban channel was messaged."
)
return return
await birthday_action(message) await birthday_action(message)
@@ -40,7 +31,7 @@ def setup(bot: commands.Bot) -> None:
async def birthday_action(message: nextcord.Message) -> None: async def birthday_action(message: nextcord.Message) -> None:
""" """
Checks a message's author and mentions to see if they are in the birthday list. Checks a message's auther and mentions to see if they are in the birthday list.
Args: Args:
message (nextcord.Message): The message to check for a birthday person. message (nextcord.Message): The message to check for a birthday person.
-1
View File
@@ -17,7 +17,6 @@ class ChannelIds:
event_post: int event_post: int
general: int general: int
voting: int voting: int
ban: int
@dataclass @dataclass