Begin implementing aiohttp

This commit is contained in:
2022-09-04 13:47:32 +01:00
parent 36de004ee5
commit 663a26778d
11 changed files with 392 additions and 118 deletions

22
schemas/ch4_s.py Normal file
View File

@@ -0,0 +1,22 @@
ATTRMAP = {
"no": "msg_id",
"now": "ts",
"name": "user",
"trip": "nick",
"id": "nick_id",
"resto": "id_reply",
"com": "msg",
"ext": "file_ext",
"w": "file_w",
"h": "file_h",
"tn_w": "file_tn_w",
"tn_h": "file_tn_h",
"tim": "file_tim",
"fsize": "file_size",
"md5": "file_md5",
"filedeleted": "file_deleted",
"spoiler": "file_spoiler",
"custom_spoiler": "file_custom_spoiler",
"m_img": "file_m_img",
"time": "unix_time",
}

19
schemas/dis_s.py Normal file
View File

@@ -0,0 +1,19 @@
ATTRMAP = {
"msg": "content",
"msg_id": "id",
"nick": "author.name",
"host": "author.discriminator",
"ident": "author.nick",
"time": "created_at",
"channel": "channel.name",
"channel_nsfw": "channel.nsfw",
"bot": "author.bot",
"nick_id": "author.id",
"channel_id": "channel.id",
"net": "author.guild.name",
"net_id": "author.guild.id",
"guild_member_count": "author.guild.member_count",
"channel_category": "channel.category.name",
"channel_category_id": "channel.category.id",
"channel_category_nsfw": "channel.category.nsfw",
}

199
schemas/mc_s.py Normal file
View File

@@ -0,0 +1,199 @@
schema = {
"id": "bigint",
# 1
"archived": "int",
# 1662150538
"archived_on": "string indexed attribute",
# CF
"board_flag": "string indexed attribute",
# true, false
"bot": "bool",
# 0
"bumplimit": "int",
# mod
"capcode": "string indexed attribute",
# 393598265, #main, Rust Programmer's Club
"channel": "text",
# Miscellaneous
"channel_category": "text",
# 360581491907887100
"channel_category_id": "string indexed attribute",
# true, false
"channel_category_nsfw": "bool",
# 734229101216530600
"channel_id": "string indexed attribute",
# true, false
"channel_nsfw": "bool",
# 1
"closed": "int",
# GB
"country": "string indexed attribute",
# United Kingdom
"country_name": "text",
# 5
"file_custom_spoiler": "int",
# 1
"file_deleted": "int",
# .jpg
"file_ext": "string indexed attribute",
# 1024
"file_h": "int",
# 1
"file_m_img": "int",
# tlArbrZDj7kbheSKPyDU0w==
"file_md5": "string indexed attribute",
# 88967
"file_size": "int",
# 1
"file_spoiler": "int",
# 1662149436322819
"file_tim": "string indexed attribute",
# 250
"file_tn_h": "int",
# 241
"file_tn_w": "int",
# 1080
"file_w": "int",
# 6E646BED-297E-4B4F-9082-31EDADC49472
"filename": "text",
# Confederate
"flag_name": "string indexed attribute",
"guild": "text", # LEGACY -> channel
"guild_id": "string indexed attribute", # LEGACY -> channel_id
# 36180
"guild_member_count": "int", # ? -> channel_member_count
# 9f7b2e6a0e9b
"host": "text",
# 2447746
"id_reply": "string indexed attribute", # resto
# "522, trans rights shill", myname
"ident": "text",
# 0
"imagelimit": "int",
# 0
"images": "int",
# 0
"mode": "string indexed attribute",
# b0n3
"modearg": "string indexed attribute",
# The quick brown fox jumped over the lazy dog
"msg": "text",
# 393605030
"msg_id": "string indexed attribute",
# pol
"net": "text",
# 273534239310479360
"net_id": "string indexed attribute",
# André de Santa Cruz, santa
"nick": "text",
# 773802568324350000
"nick_id": "string indexed attribute",
# 1, 2, 3, 4, 5, 6, ...
"num": "int",
# 12
"replies": "int",
# redacted-hate-thread
"semantic_url": "string indexed attribute",
# -1 -> 1 as float
"sentiment": "float",
# 2022
"since4pass": "int",
# 4ch, irc, dis
"src": "string indexed attribute",
# true, false
"status": "bool",
# 1
"sticky": "int",
# 1000
"sticky_cap": "int",
# Redacted Hate Thread, Gorbachev is dead
"sub": "string indexed attribute",
# Loop
"tag": "string indexed attribute",
# 100
"tail_size": "int",
"time": "timestamp", # LEGACY -> ts
"tokens": "text", # ???
# 2022-09-02T16:10:36
"ts": "timestamp",
# msg, notice, update, who
"type": "string indexed attribute",
# 10
"unique_ips": "int",
# 1662149436
"unix_time": "string indexed attribute",
# Anonymous
"user": "text",
"user_id": "string indexed attribute", # LEGACY -> nick_id
# 1, 2
"version_sentiment": "int",
# 1, 2
"version_tokens": "int",
}