From ec7cfc34271a2da0c84e17681d7f24c7d8da3e95 Mon Sep 17 00:00:00 2001 From: PuffDip Date: Fri, 25 May 2018 13:43:02 +0200 Subject: [PATCH] remove junk --- src/__main__.py | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/src/__main__.py b/src/__main__.py index 4860c8a..d418558 100644 --- a/src/__main__.py +++ b/src/__main__.py @@ -12,7 +12,6 @@ import random import traceback import os import sys -import aiohttp import discord from discord.ext import commands @@ -65,27 +64,9 @@ class SebiMachine(commands.Bot, LoadConfig, Loggable): self.load_extension(f'src.cogs.{cog}') self.logger.info(f'Loaded: {cog}') - async def keep_website_alive(self): - """ - Agg provided us with a personal website. - This is a free host and this free host provided us with a couple of rules - we have to adjust to. One of those rules is that each month atleast one request - have to be made with this website. Rule number 10 can be found here: - https://www.freewebhostingarea.com/agreement.html. - If anyone has a better solution feel free to edit this function. - """ - # Create client session - async with aiohttp.ClientSession() as session: - # Request url - async with session.get('http://chillout.ueuo.com/') as request: - # print the response status - self.logger.info(f'http://chillout.ueuo.com/ status : {request.status}') - await asyncio.sleep(3600) # sleep for one hour - async def on_ready(self): """On ready function""" self.maintenance and self.logger.warning('MAINTENANCE ACTIVE') - await asyncio.get_event_loop().create_task(self.keep_website_alive()) async def on_command_error(self, ctx, error): """