Added some config files
This commit is contained in:
@@ -1,16 +1,16 @@
|
||||
from cpl_core.application import ApplicationABC
|
||||
from cpl_core.configuration import ConfigurationABC
|
||||
from cpl_core.console import Console
|
||||
from cpl_core.dependency_injection import ServiceProviderABC
|
||||
|
||||
|
||||
class Application(ApplicationABC):
|
||||
|
||||
def __init__(self, config: ConfigurationABC, services: ServiceProviderABC):
|
||||
ApplicationABC.__init__(self, config, services)
|
||||
|
||||
self._bot: BotService = services.get_service(BotServiceABC)
|
||||
self._logger: LoggerABC = services.get_service(LoggerABC)
|
||||
|
||||
async def configure(self):
|
||||
pass
|
||||
|
||||
async def main(self):
|
||||
Console.write_line('Hello World')
|
||||
try:
|
||||
await self._bot.run()
|
||||
except Exception as e:
|
||||
self._logger.error(__name__, 'A fatal error occured starting the bot', e)
|
||||
|
Reference in New Issue
Block a user