Skip to content

Commit

Permalink
feat: doing a temperoray comit to save work!
Browse files Browse the repository at this point in the history
  • Loading branch information
amindadgar committed Jan 11, 2024
1 parent 00a6669 commit 4eea2bf
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions dags/hivemind_etl_helpers/src/db/discord/fetch_raw_messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,8 @@ def fetch_raw_messages(guild_id: str, from_date: datetime | None = None) -> list
client[guild_id]["rawinfos"]
.find(
{
"$and": [
{"createdDate": {"$gte": from_date}},
{"isGeneratedByWebhook": False},
],
"createdDate": {"$gte": from_date},
"isGeneratedByWebhook": False,
}
)
.sort("createdDate", 1)
Expand Down Expand Up @@ -135,3 +133,19 @@ def fetch_raw_msg_grouped(
raw_messages_grouped = list(cursor)

return raw_messages_grouped

def fetch_channels(guild_id: str):
"""
fetch the channels from modules that we wanted to process
Parameters
-----------
guild_id : str
the guild to have its channels
Returns
---------
channels : list[str]
the channels to fetch data from
"""
pass

0 comments on commit 4eea2bf

Please sign in to comment.