disnake-debug 2.6
A visual debugging extension for disnake discord bots including easy blacklisting, evaluation, echoing and much more!
License: MIT
Keywords: disnake,discord,debugging,visual,extension,cog

[![Python versions](https://img.shields.io/pypi/pyversions/disnake-debug.svg)](https://pypi.python.org/pypi/disnake-debug)
[![License](https://img.shields.io/pypi/l/disnake-debug.svg)](https://github.com/CaedenPH/disnake-debug/blob/master/LICENSE)
[![Status](https://img.shields.io/pypi/status/disnake-debug.svg)](https://pypi.python.org/pypi/disnake-debug)
[![Issues](https://img.shields.io/github/issues/CaedenPH/disnake-debug.svg?colorB=3333ff)](https://github.com/CaedenPH/disnake-debug/issues)
[![Commit activity](https://img.shields.io/github/commit-activity/w/CaedenPH/disnake-debug.svg)](https://github.com/CaedenPH/disnake-debug/commits)


<h1 align="center">
<sub>
    <img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAMgAAADICAMAAACahl6sAAAAgVBMVEX///8AAAD29vYEBARFRUULCwvz8/MMDAw8PDz8/PzCwsLW1tbR0dHa2toZGRkUFBTo6Ojh4eErKyu6uroxMTFpaWkXFxfKysqFhYVwcHDAwMDu7u6WlpaysrIiIiI4ODhaWlpeXl55eXlMTEypqalBQUGCgoKUlJSfn58lJSVkZGS5Z6x3AAAHbUlEQVR4nO2d61arMBCFSZG21N7vtdqr2ur7P+BRK0dIgUxmdhp0sX9aFswnCUlmJpkgqFWrVq1atWrV+tOKh2uby0f3TVeWiNTbRUqNH2Pa1fGyr1R47Lq1iaOHlvrSsUG5uvlyuTp8cm2XrUbfHErdEUia7eTq1si9bVZaKUUn+eFQanUL6yy0UXSSNId6u419ZIWKTJLhUK1bWUjUXFFJshyVeyM7RSTRONTsllYStFA0Ep0jqtpXK1iSSHSO6o0jNJLfwBEEj9ckcW9yXh5Wq8PycdKLfwlHEJw1kuk2ynSH7VTrHxPfFhfpOVQWqi5HEDxZkEQPvq0t0yQyE1zU6vi2tVwPRJJo4dvScq13ZoaLdlaryVvroU/lUKpf4b6uj4kGLX3bW6AGuV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K5CYII=" height="36">
</sub>
&nbsp;
disnake-debug
</h1>
<p align="center">
<sup>
a debugging and utility extension for disnake bots
</sup>
<br>
</p>

***

disnake-debug is an extension for bot developers that enables rapid prototyping, experimentation, and debugging of features for bots.
features include easy blacklisting, dynamically change bot avatar and name, pause and unpause the bot (stop it from responding to commands until unpaused), evaluate code (normal, return and dir), leave guilds, speak as the bot, view invokes and view bot statistics

One of disnake-debug's core philosophies is to be dynamic and easy-to-use. Here's the two step install:

> 1. Download disnake-debug on the command line using pip:
> ```bash
> pip install -U disnake-debug
> ```
> 2. Load the extension in your bot code before it runs:
> ```python
> bot.load_extension('disnake-debug')
> ```
> That's it!

How to use debug:

> Once the extension is loaded and the bot is online you can just run the debug command 
> If your prefix is . you would run `.debug`

How to configure the database (sqlite) location:
> In your .env, put `DATABASE_PATH=your_path`
> Make sure there is a database.db file in your_path

Configure the embed colors:
> In your .env replace `EMBED_COLOR` with a hex color
> `EMBED_COLOR` is automatically created and added to your `.env`

Simple bot example with disnake-debug:

> ```py
> from dotenv import load_dotenv # import load_dotenv to load your .env file
> from os import environ # import environ 
> from disnake import Intents # import intents
> from disnake.ext.commands import Bot # import Bot class
>
> bot = Bot(
>    command_prefix=".", # your command prefix
>    owner_ids=[298043305927639041], # put your owner id in here
>    intents=Intents.all() # so you can see users (required for blacklist)
> )
> bot.load_extension("disnake-debug") # load debug extension. one command and that is debug
> 
> @bot.event
> async def on_ready() -> None:
>    print(f"Logged in as {bot.user}")
>
> if __name__ == "__main__":
>    load_dotenv()
>    bot.run(environ["TOKEN"])
> ```

Some pictures:
![](https://media.discordapp.net/attachments/343944376055103488/935290160990535740/unknown.png)
![](https://media.discordapp.net/attachments/926135748451774464/935291231431438366/unknown.png)
![](https://media.discordapp.net/attachments/926135748451774464/935292005699960842/unknown.png)
![](https://media.discordapp.net/attachments/926135748451774464/935292388761546812/unknown.png)
![](https://media.discordapp.net/attachments/926135748451774464/935292483414405120/unknown.png)