forked from Rapptz/discord.py
-
Notifications
You must be signed in to change notification settings - Fork 196
Open
Labels
unconfirmed bugUnconfirmed bugUnconfirmed bug
Description
Summary
Guild not imported in str
Reproduction Steps
- Call
str
on instance ofdiscord.GuildFolder
:
str(guild_folder)
I added: from .guild import Guild in __str__
and it worked after that.
Code
Code:
class MyClient(discord.Client):
async def on_ready(self) -> None:
assert(self.settings)
for folder in self.settings.guild_folders:
print(str(folder))
Error:
NameError: name 'Guild' is not defined
│ 1196 │ def __str__(self) -> str: │
│ ❱ 1197 │ │ return self.name or ', '.join(guild.name for guild in [guild for guild in self.g │
Expected Results
Return str representation of GuildFolder.
Actual Results
N/A
System Information
N/A
Checklist
- I have confirmed I am using unmodified discord.py-self and not the upstream discord.py.
- I am using a user token (and it isn't visible in the code).
- I have searched the open issues for duplicates.
- I have searched closed issues for resolved duplicates.
- I have confirmed the development version doesn't resolve the issue.
- I have shared the entire traceback.
Additional Information
No response
Metadata
Metadata
Assignees
Labels
unconfirmed bugUnconfirmed bugUnconfirmed bug