<commit_before># -*- coding: utf-8 -*-

import os
from datetime import datetime
from ChatExchange.chatexchange.client import Client
import HTMLParser
import md5
import ConfigParser
from helpers import environ_or_none


class GlobalVars:
    false_positives = []
    whitelisted_users = []
    blacklisted_users = []
    ignored_posts = []
    auto_ignored_posts = []
    startup_utc = datetime.utcnow().strftime("%H:%M:%S")
    latest_questions = []
    api_backoff_time = 0
    charcoal_room_id = "11540"
    meta_tavern_room_id = "89"
    socvr_room_id = "41570"
    blockedTime = {"all": 0, charcoal_room_id: 0, meta_tavern_room_id: 0, socvr_room_id: 0}

    experimental_reasons = []  # Don't widely report these
    non_socvr_reasons = []    # Don't report to SOCVR
    non_tavern_reasons = [    # Don't report in the Tavern
        "all-caps body",
        "all-caps answer",
        "repeating characters in body",
        "repeating characters in title",
        "repeating characters in answer",
        "few unique characters in body",
        "few unique characters in answer",
        "title has only one unique char",
        "phone number detected in title",
        "offensive body detected",
        "no whitespace in body",
        "no whitespace in answer",
    ]
    non_tavern_sites = ["stackoverflow.com"]

    parser = HTMLParser.HTMLParser()
    wrap = Client("stackexchange.com")
    wrapm = Client("meta.stackexchange.com")
    wrapso = Client("stackoverflow.com")
    privileged_users = {
        charcoal_room_id: [
            "117490",   # Normal Human
            "66258",    # Andy
            "31768",    # ManishEarth
            "103081",   # hichris123
            "73046",    # Undo
            "88521",    # ProgramFOX
            "59776",    # Doorknob
            "31465",    # Seth
            "88577",    # <NAME>
            "34124",    # <NAME>
            "54229",    # apnorton
            "20459",    # <NAME>
            "32436",    # tchrist
            "30477",    # <NAME>
            "58529",    # ferrybig
            "145208",   # <NAME>
            "178825",   # <NAME>
            "171800",   # JAL
            "64978",    # PeterJ
            "125141",   # <NAME>
            "54902",    # bummi
            "135450",   # M.A.R.
            "145604",   # Quill
            "60548",    # rene
            "121401",   # michaelpri
            "116218",   # JamesENL
            "82927",    # Braiam
            "11606",    # bwDraco
            "19761",    # <NAME>
            "108271",   # <NAME>.
            "171054",   # Magisch
            "190011",   # <NAME>
            "165661",   # Tunaki
            "145086",   # <NAME>
            "137665",   # ByteCommander
            "147884",   # wythagoras
            "186395",   # Åna
            "193364",   # <NAME>
            "163686",   # Gothdo
            "145827",   # angussidney
            "121520",   # ArtOfCode
            "215783",   # KarmaBot (ArtOfCode's sock to test things with)
            "137388",   # QPaysTaxes
            "212311",   # <NAME>
            "172397",   # Kyll
            "224538",   # FrankerZ
            "61202",    # OldSkool
            "56166"     # <NAME>
        ],
        meta_tavern_room_id: [
            "315433",   # Normal Human
            "244519",   # CRABOLO
            "244382",   # TGMCians
            "194047",   # <NAME>
            "158100",   # rene
            "178438",   # Manishearth<commit_msg>Added DavidPostill(133966) to the charcoal user list<commit_after># -*- coding: utf-8 -*-

import os
from datetime import datetime
from ChatExchange.chatexchange.client import Client
import HTMLParser
import md5
import ConfigParser
from helpers import environ_or_none


class GlobalVars:
    false_positives = []
    whitelisted_users = []
    blacklisted_users = []
    ignored_posts = []
    auto_ignored_posts = []
    startup_utc = datetime.utcnow().strftime("%H:%M:%S")
    latest_questions = []
    api_backoff_time = 0
    charcoal_room_id = "11540"
    meta_tavern_room_id = "89"
    socvr_room_id = "41570"
    blockedTime = {"all": 0, charcoal_room_id: 0, meta_tavern_room_id: 0, socvr_room_id: 0}

    experimental_reasons = []  # Don't widely report these
    non_socvr_reasons = []    # Don't report to SOCVR
    non_tavern_reasons = [    # Don't report in the Tavern
        "all-caps body",
        "all-caps answer",
        "repeating characters in body",
        "repeating characters in title",
        "repeating characters in answer",
        "few unique characters in body",
        "few unique characters in answer",
        "title has only one unique char",
        "phone number detected in title",
        "offensive body detected",
        "no whitespace in body",
        "no whitespace in answer",
    ]
    non_tavern_sites = ["stackoverflow.com"]

    parser = HTMLParser.HTMLParser()
    wrap = Client("stackexchange.com")
    wrapm = Client("meta.stackexchange.com")
    wrapso = Client("stackoverflow.com")
    privileged_users = {
        charcoal_room_id: [
            "117490",   # Normal Human
            "66258",    # Andy
            "31768",    # ManishEarth
            "103081",   # hichris123
            "73046",    # Undo
            "88521",    # ProgramFOX
            "59776",    # Doorknob
            "31465",    # Seth
            "88577",    # <NAME>
            "34124",    # <NAME>
            "54229",    # apnorton
            "20459",    # <NAME>
            "32436",    # tchrist
            "30477",    # <NAME>
            "58529",    # ferrybig
            "145208",   # <NAME>
            "178825",   # <NAME>
            "171800",   # JAL
            "64978",    # PeterJ
            "125141",   # <NAME>
            "54902",    # bummi
            "135450",   # M.A.R.
            "145604",   # Quill
            "60548",    # rene
            "121401",   # michaelpri
            "116218",   # JamesENL
            "82927",    # Braiam
            "11606",    # bwDraco
            "19761",    # <NAME>
            "108271",   # <NAME>.
            "171054",   # Magisch
            "190011",   # <NAME>
            "165661",   # Tunaki
            "145086",   # <NAME>
            "137665",   # ByteCommander
            "147884",   # wythagoras
            "186395",   # Åna
            "193364",   # <NAME>
            "163686",   # Gothdo
            "145827",   # angussidney
            "121520",   # ArtOfCode
            "215783",   # KarmaBot (ArtOfCode's sock to test things with)
            "137388",   # QPaysTaxes
            "212311",   # <NAME>
            "172397",   # Kyll
            "224538",   # FrankerZ
            "61202",    # OldSkool
            "56166",    # <NAME>
            "133966"    # DavidPostill
        ],
        meta_tavern_room_id: [
            "315433",   # Normal Human
            "244519",   # CRABOLO
            "244382",   # TGMCians
            "194047",   # <NAME>
            "158100",   # rene
            "178438",   # Manishearth
{'fraction_non_alphanumeric': 0.11781445645987479, 'fraction_numerical': 0.09419464997154241, 'mean_word_length': 1.5709583028529628, 'pattern_counts': {'":': 2, '<': 33, '<?xml version=': 0, '>': 33, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1247038', 'n_tokens_mistral': 2684, 'n_tokens_neox': 2251, 'n_words': 493}