-added suport for custom query in FileBotHandler
-PEP and docstring cleanup