mirror of
https://github.com/SpiceBot/SpiceBot.git
synced 2026-11-13 06:59:53 -05:00
test
This commit is contained in:
parent
d05b16c3f8
commit
07b6fa3f39
@ -16,12 +16,15 @@ import requests
|
|||||||
from fake_useragent import UserAgent
|
from fake_useragent import UserAgent
|
||||||
import urllib
|
import urllib
|
||||||
|
|
||||||
|
import sys
|
||||||
|
|
||||||
|
|
||||||
class SpiceBot_DictComs_MainSection(StaticSection):
|
class SpiceBot_DictComs_MainSection(StaticSection):
|
||||||
extra = ListAttribute('extra')
|
extra = ListAttribute('extra')
|
||||||
|
|
||||||
|
|
||||||
class BotJSONCommands():
|
class BotJSONCommands():
|
||||||
|
|
||||||
def __init__(self):
|
def __init__(self):
|
||||||
self.setup_dictcoms()
|
self.setup_dictcoms()
|
||||||
self.header = {'User-Agent': str(UserAgent().chrome)}
|
self.header = {'User-Agent': str(UserAgent().chrome)}
|
||||||
@ -33,10 +36,11 @@ class BotJSONCommands():
|
|||||||
]
|
]
|
||||||
|
|
||||||
dir_to_scan = botread.get_config_dirs("SpiceBot_DictComs")
|
dir_to_scan = botread.get_config_dirs("SpiceBot_DictComs")
|
||||||
|
sys.stderr.write(dir_to_scan)
|
||||||
|
|
||||||
self.valid_dictcom_dict = botread.json_to_dict(dir_to_scan, "Dictionary Commands", "SpiceBot_DictComs")
|
valid_dictcom_dict = botread.json_to_dict(dir_to_scan, "Dictionary Commands", "SpiceBot_DictComs")
|
||||||
|
|
||||||
for dict_from_file in list(self.valid_dictcom_dict.keys()):
|
for dict_from_file in list(valid_dictcom_dict.keys()):
|
||||||
|
|
||||||
dict_from_file["comtype"] = "prefix"
|
dict_from_file["comtype"] = "prefix"
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user