<commit_before>import os
import re
import asyncio
import aiohttp
import random
import discord
import traceback

from discord.ext import commands

#from BB.file import class
from BB.conf import Conf
from BB.permissions import Perms
from BB.unogame import The_Game, Uno
from BB.player import Player, Downloader
from BB.settings import Settings, ServerSettings
from BB.mods import Moderation


class Barry(discord.Client):

    def __init__(self, bot):
        self.config = Conf(os.path.dirname(os.path.dirname(os.path.realpath(__file__)))+"\\config\\config.ini")
        self.THE_SECRET_TOKEN = self.config.THE_TOKEN
        self.loop = asyncio.get_event_loop()
        self.bot = bot
        self.downloader = Downloader(self.config.download_path)
        self.bot.add_cog(MainCommands(self.bot, self.config)) #add the main command class so the bot actually listens
        self.bot.add_cog(self) #also a cheaty way to just fit all the commands into this class
        self.bot.add_cog(Uno(self.bot, self.config, self.loop, self))        
        self.bot.add_cog(Player(self.bot, self.config, self.loop, self))
        self.bot.add_cog(Settings(self.bot, self.config, self.loop, self))
        self.bot.add_cog(Moderation(self.bot, self.config, self.loop, self))
        self.UnoGames = {}
        self.settings = {}
        
        
        self.logchan = None
        
        
        self.blacklist = set()
        
        
        super().__init__()

    

        
    @commands.command()
    async def blacklistme(self, ctx):
        self.blacklist.add(ctx.message.author.id)<commit_msg>Getting close to finishing the general api of the settings Adding barebones commands for future development because i keep forgetting everything i was going to do run.py: made it so if you passed a stupid type then it would let you know bot.py: settings api for easy reach from all other files since they all import BarryBot permissions.py: i didnt capitalize something i wouldnt use anyways but it errors there so why not unogame.py: clarifying the usage because for some reason when usage shows up it looks stupid; also making it easier to hit the silent (and hidden) gametype<commit_after>import os
import re
import asyncio
import aiohttp
import random
import discord
import traceback

from discord.ext import commands

#from BB.file import class
from BB.conf import Conf
from BB.permissions import Perms
from BB.unogame import The_Game, Uno
from BB.player import Player, Downloader
from BB.settings import Settings, ServerSettings
from BB.mods import Moderation


class Barry(discord.Client):

    def __init__(self, bot):
        self.config = Conf(os.path.dirname(os.path.dirname(os.path.realpath(__file__)))+"\\config\\config.ini")
        self.THE_SECRET_TOKEN = self.config.THE_TOKEN
        self.loop = asyncio.get_event_loop()
        self.bot = bot
        self.downloader = Downloader(self.config.download_path)
        self.bot.add_cog(MainCommands(self.bot, self.config)) #add the main command class for laziness sake
        self.bot.add_cog(self) #also a cheaty way to just fit all the commands into this class
        self.bot.add_cog(Uno(self.bot, self.config, self.loop, self))        
        self.bot.add_cog(Player(self.bot, self.config, self.loop, self))
        self.bot.add_cog(Settings(self.bot, self.config, self.loop, self))
        self.bot.add_cog(Moderation(self.bot, self.config, self.loop, self))
        self.UnoGames = {}
        self.settings = {}
        
        
        self.logchan = None
        
        
        self.blacklist = set()
        
        
        super().__init__()
    def guild_settings(ctx): #this is for general use to retrieve the context's server specific settings quickly
        ''' this just returns a settings object quickly for the context
        if it returns none then there was something wrong'''
        try:
            if ctx.guild.id in self.settings:
                return self.settings[ctx.guild.id]
        except: # something is terribly wrong with the context
            return None
        finally: # guild is isnt even in the settings file
            return None
        
    @commands.command()
    async def blacklistme(self, ctx):
        self.blacklist.add(ctx.message.author.id)
{'fraction_non_alphanumeric': 0.08388003748828492, 'fraction_numerical': 0.0, 'mean_word_length': 2.828699551569507, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 8, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6354632', 'n_tokens_mistral': 1244, 'n_tokens_neox': 1226, 'n_words': 395}