mirror of
https://github.com/SpiceBot/SpiceBot.git
synced 2026-11-13 06:59:53 -05:00
commit
65a459ff6b
@ -12,8 +12,7 @@ from operator import itemgetter
|
|||||||
import threading
|
import threading
|
||||||
|
|
||||||
|
|
||||||
from sopel_modules.SpiceBot_SBTools.BotEvents import set_bot_event
|
from sopel_modules.SpiceBot_Botevents.BotEvents import set_bot_event
|
||||||
|
|
||||||
|
|
||||||
import spicemanip
|
import spicemanip
|
||||||
|
|
||||||
@ -50,11 +49,12 @@ def setup_thread(bot):
|
|||||||
# pypi installed
|
# pypi installed
|
||||||
try:
|
try:
|
||||||
import sopel_modules
|
import sopel_modules
|
||||||
pypi_modules = os.path.dirname(os.path.abspath(sopel_modules.__file__))
|
for plugin_dir in set(sopel_modules.__path__):
|
||||||
pypi_modules_dir = os.path.join(pypi_modules, 'modules')
|
for pathname in os.listdir(plugin_dir):
|
||||||
|
pypi_modules_dir = os.path.join(plugin_dir, pathname)
|
||||||
filepathlisting.append(pypi_modules_dir)
|
filepathlisting.append(pypi_modules_dir)
|
||||||
except Exception:
|
except Exception as e:
|
||||||
pass
|
stderr("[Sopel-CommandsQuery] sopel_modules not loaded :" + str(e))
|
||||||
|
|
||||||
# Extra directories
|
# Extra directories
|
||||||
filepathlist = []
|
filepathlist = []
|
||||||
@ -159,7 +159,6 @@ def query_detection(bot, trigger):
|
|||||||
# command must start with
|
# command must start with
|
||||||
if not str(trigger).startswith(tuple(['?'])):
|
if not str(trigger).startswith(tuple(['?'])):
|
||||||
return
|
return
|
||||||
stderr(trigger.args)
|
|
||||||
|
|
||||||
commands_list = dict()
|
commands_list = dict()
|
||||||
for commandstype in bot.memory['Sopel-CommandsQuery'].keys():
|
for commandstype in bot.memory['Sopel-CommandsQuery'].keys():
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user