Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependency SQLAlchemy to v2.0.18 #17

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
122 changes: 65 additions & 57 deletions docs/sqlite_database_structure.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,78 +2,86 @@ Note: this documentation was generated automatically from the tasks.py code usin


**activity table**

|Column|Description
|--|--|
|event_name|Indicates the type of event recorded. For example: 'message_sent', 'guild_joined', 'application_command_used', 'add_reaction', 'app_opened'.|
|day|The date on which the event occurred, formatted as 'YYYY-MM-DD'.|
|hour|The hour during which the event occurred, given as an integer from 0-23.|
|occurrence_count|The number of times this event occurred during this hour on the given day.|
|associated_channel_id|ID of the channel associated with the event.|
|associated_guild_id|ID of the guild associated with the event.|
|associated_user_id|ID of the user or application associated with the event. For 'application_command_used' events only.|
|extra_field_1|Additional data associated with the event. Can contain the name of the emoji for 'add_reaction' events, the operating system for 'app_opened' events, and the application ID for 'application_command_used' events.|
|extra_field_2|Additional data associated with the event. Used to indicate if an emoji is custom ('1') or not ('0') for 'add_reaction' events.|
|-|-
| event_name | The name of the activity event that occurred. Examples could include `message_sent`, `email_opened`, `app_crashed`, etc.|
| day | The specific day when the event occurred in the format `YYYY-MM-DD`. |
| hour | The specific hour when the event occurred as an integer value using a 24-hour clock format. |
| occurence_count | The number of times the event occurred during the specified hour on the specified day. |
| associated_channel_id | The ID of the channel associated with the event, if any. |
| associated_guild_id | The ID of the guild (paid version of a server) associated with the event, if any. |
| associated_user_id |The ID of the user associated with the event, if any. |
| extra_field_1 | An extra field that may hold different contents depending on the event. |
| extra_field_2 | A second extra field that may hold different contents depending on the event. |

**dm_channels_data table**

|Column|Description
|--|--|
|channel_id|The unique identifier for the direct message channel.|
|dm_user_id|The unique identifier for the user involved in the direct message channel.|
|user_name|The username of the user involved in the direct message channel.|
|display_name|The display name of the user involved in the direct message channel.|
|user_avatar_url|URL of the user’s avatar.|
|total_message_count|The total number of messages exchanged in the direct message channel.|
|total_voice_channel_duration|The total duration of voice channel activity in the direct message channel.|
|sentiment_score|The sentiment score of the messages in the direct message channel.|
|-|-
| channel_id | The unique identifier for the direct message (DM) channel. |
| dm_user_id | The unique identifier associated with the user in the DM. |
| user_name | The name of the user associated with the DM. |
| display_name | The user's display name associated with the DM. |
| user_avatar_url | The URL path to the user's avatar image. |
| total_message_count | The total number of messages counted in the DM channel. |
| total_voice_channel_duration | The total duration measured of voice interaction in the DM channel. |
| sentiment_score | A score representing the sentiment of the messages in the DM channel. |

**guild_channels_data table**

|Column|Description
|--|--|
|channel_id|The unique identifier for the guild channel.|
|guild_id|The unique identifier for the guild the channel belongs to.|
|channel_name|The name of the channel.|
|total_message_count|The total number of messages sent in the channel.|
|total_voice_channel_duration|The total time spent in the voice channels of the discord guild.|
|-|-
| channel_id | The unique identifier for the guild channel. |
| guild_id | The unique identifier for the guild. |
| channel_name | The name of the guild channel. |
| total_message_count | The total number of messages counted in the guild channel. |
| total_voice_channel_duration | The total duration measured of voice interaction in the guild channel. |

**guilds table**

|Column|Description
|--|--|
|guild_id|The unique identifier for the guild.|
|guild_name|The name of the guild.|
|total_message_count|The total number of messages sent across all channels in the guild.|
|-|-
| guild_id | The unique identifier for the guild. |
| guild_name | The name of the guild. |
| total_message_count | The total number of messages counted in the guild. |

**payments table**
|Column|Description
|--|--|
|payment_id|A unique identifier for the payment transaction.|
|payment_date|The date the payment was made.|
|payment_amount|The amount of the payment.|
|payment_currency|The currency in which the payment was made.|
|payment_description|Description of the payment transaction.|

| Column| Description
|-|-
| payment_id | The unique identifier for the payment. |
| payment_date | The date the payment was made in format `YYYY-MM-DD`. |
| payment_amount | The amount of the payment. |
| payment_currency | The currency the payment was made in. |
| payment_description | A description of the payment. |

**voice_sessions table**
|Column|Description
|--|--|
|channel_id|The unique identifier for the channel in which the voice session occurred.|
|guild_id|The unique identifier for the guild in which the voice session occurred.|
|duration_mins|The duration of the voice session, measured in minutes.|
|started_date|The starting date and time of the voice session.|
|ended_date|The ending date and time of the voice session.|

| Column | Description
|-|-
| channel_id | The unique identifier for the channel of the voice session. |
| guild_id | The unique identifier for the guild of the voice session. |
| duration_mins | The total duration of the voice session in minutes. |
| started_date | The date the voice session started in the format `YYYY-MM-DD`.|
| ended_date | The date the voice session ended in the format `YYYY-MM-DD`.|

**sessions table**
|Column|Description
|--|--|
|duration_mins|The duration of the session, in minutes.|
|started_date|The starting date and time of the session.|
|ended_date|The ending date and time of the session.|
|device_os|The operating system of the device used for the session.|

|Column | Description
|-|-
| duration_mins | The total duration of the session in minutes. |
| started_date | The date the session started in the format `YYYY-MM-DD`.|
| ended_date | The date the session ended in the format `YYYY-MM-DD`.|
| device_os | The operating system of the device used for the session.|

**package_data table**
|Column|Description
|--|--|
|package_id|The unique identifier for the data package.|
|package_version|The version of the data package.|
|package_owner_id|The unique identifier for the owner of the package.|
|package_owner_name|The username of the package owner.|
|package_owner_display_name|The display name of the package owner.|
|package_owner_avatar_url|The URL to the avatar image of the package owner.|

| Column | Description
|-|-
| package_id | The unique identifier for the package.|
| package_version | The version of the package.|
| package_owner_id | The id of the owner of the package.|
| package_owner_name | The name of the owner of the package.|
| package_owner_display_name | The display name of the owner of the package.|
| package_owner_avatar_url | The URL path to the owner's avatar image.|
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ regex==2023.6.3
requests==2.31.0
rich==13.4.2
six==1.16.0
SQLAlchemy==2.0.15
SQLAlchemy==2.0.18
tomli==2.0.1
tqdm==4.65.0
typing_extensions==4.6.2
Expand Down