From f42abd39bbb9df3cf0b9ba5fa43c7d2ded7b687c Mon Sep 17 00:00:00 2001 From: Pythonic-Rainbow Date: Sat, 3 Jul 2021 14:41:04 +0800 Subject: [PATCH] 0.10 - The UI update --- DimBot.py | 18 +++++++++++++----- bruckserver/pythania.py | 15 --------------- 2 files changed, 13 insertions(+), 20 deletions(-) diff --git a/DimBot.py b/DimBot.py index 8d74e22..3fdf64b 100644 --- a/DimBot.py +++ b/DimBot.py @@ -26,7 +26,7 @@ intent.guilds = intent.members = intent.messages = intent.reactions = intent.voice_states = intent.typing = True intent.presences = True bot = missile.Bot(intents=intent) -nickname = f"DimBot {'S ' if dimsecret.debug else ''}| 0.9.28" +nickname = f"DimBot {'S ' if dimsecret.debug else ''}| 0.10" logger = missile.get_logger('DimBot') sponsor_txt = '世界の未来はあなたの手の中にあります ' reborn_channel = None @@ -449,10 +449,18 @@ async def modrole(ctx: commands.Context, role: discord.Role): async def changelog(ctx): """Shows the latest release notes of DimBot""" await ctx.reply(""" -**__0.9.28 (Jul 3, 2021 2:45AM GMT+8)__**\n -The entire `quote` command group as well as `xp leaderboard` now rock a new UI!!! -`quote i ` has been changed to `quote `. -`quote r` is removed as its obsolete with the new UI. +**__0.10 (Jul 3, 2021 2:45PM GMT+8)__ The UI update** + +After 2 months of somewhat relaxing development, I am pleased to announce v0.10, with 29 modified files, 2236 new lines and 1068 deleted lines. + +The development began with a database interconnect rewrite, which not only supports concurrent access, +but also an easier way to code SQL. +Followed by the addition of `d.xp` commands, I've stored over 1000 entries of xp records, before the 128BB incident. +Next, the UI of the entire help & quote commands, as well as `xp lb` are redesigned to be menu-driven, allowing users to +access the commands in a much easier fashion. + +In the near future, I am focusing on resolving GitHub issues, which are basically features to be added. A major goal is +to make Aegis much more configurable. """) diff --git a/bruckserver/pythania.py b/bruckserver/pythania.py index e7f9b8d..2fc2667 100644 --- a/bruckserver/pythania.py +++ b/bruckserver/pythania.py @@ -104,14 +104,6 @@ async def base64decode(request): return web.Response(body=decoded) raise web.HTTPBadRequest(reason='Missing base64-encoded parameter') - @routes.post('/ghub-webhook') - async def github_webhook(request: web.Request): - payload = await request.json() - if not payload['repository']['private']: - async with self.bot.session.post(self.github_webhook, json=payload, headers=request.headers) as r: - self.logger.info(f'Relayed GitHub webhook. Response: {r.status}') - return web.Response(status=r.status, headers=r.headers, body=await r.text()) - app = web.Application() app.add_routes(routes) runner = web.AppRunner(app) @@ -119,10 +111,3 @@ async def github_webhook(request: web.Request): site = web.TCPSite(runner, '0.0.0.0', 80) await site.start() self.logger.info('Site now running') - - # Fetches the webhook for #job - await self.bot.wait_until_ready() - for webhook in await self.bot.get_channel(435009339632123904).webhooks(): - if webhook.id == 476326171655667722: - self.github_webhook = webhook.url + '/github' - break