Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Embeds not compatible with Pycord master branch #82

Closed
tibue99 opened this issue May 2, 2023 · 8 comments
Closed

Embeds not compatible with Pycord master branch #82

tibue99 opened this issue May 2, 2023 · 8 comments
Assignees
Labels
bug Something isn't working

Comments

@tibue99
Copy link

tibue99 commented May 2, 2023

DiscordChatExporterPy Version

2.5.3

Discord Version

py-cord-2.4.1.dev76+g7a6a42c5

Bug Description

Pycord added new parameters (author, footer, image, thumbnail) to discord.Embed in #1996.

This is currently only in their master branch, but this update breaks embeds for chat exporter.

Bug Traceback

Traceback (most recent call last):
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\transcript.py", line 166, in export
    return await super().build_transcript()
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\transcript.py", line 55, in build_transcript
    message_html, meta_data = await gather_messages(
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\message.py", line 389, in gather_messages
    content_html, meta_data = await MessageConstruct(
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\message.py", line 83, in construct_message
    await self.build_message()
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\message.py", line 91, in build_message
    await self.build_assets()
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\message.py", line 226, in build_assets
    self.embeds += await Embed(e, self.guild).flow()
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\assets\embed.py", line 57, in flow
    await self.build_author()
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\chat_exporter\construct\assets\embed.py", line 109, in build_author
    self.author = html.escape(self.embed.author.name) if self.embed.author.name != self.check_against else ""
  File "C:\Users\Timo\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\embeds.py", line 704, in author
    return EmbedAuthor(**getattr(self, "_author", {}))  # type: ignore
TypeError: EmbedAuthor.__init__() missing 1 required positional argument: 'name'
Please send a screenshot of the above error to https://www.github.com/mahtoid/DiscordChatExporterPy

Additional Information

No response

@tibue99 tibue99 added the bug Something isn't working label May 2, 2023
@mahtoid mahtoid self-assigned this May 3, 2023
@mahtoid
Copy link
Owner

mahtoid commented May 3, 2023

Hello @tibue99,

Thank you for letting me know. Do you know when they plan to release this, just so I can schedule a release around the same time including the fix?

@tibue99
Copy link
Author

tibue99 commented May 3, 2023

Hey, thank you for taking care of this.

Pycord devs said they want to push for a release "very soon", so I'd guess they'll release it within the next 2 weeks, perhaps even sooner.

@mahtoid
Copy link
Owner

mahtoid commented May 4, 2023

Okay, I'll try solve and get a release out on Saturday to cover this. Thank you again! 💜

@mahtoid
Copy link
Owner

mahtoid commented May 6, 2023

Just to update, this seems to be an issue on Pycords end. I have dropped an issue on their Github and will follow through with what they say there.

@tibue99
Copy link
Author

tibue99 commented May 9, 2023

Thanks, this issue seems to be resolved after #2061, I tested exporting embeds with the current master branch.

@tibue99 tibue99 closed this as completed May 9, 2023
@Lulalaby
Copy link

Lulalaby commented May 9, 2023

Reopen, this fix gonna be reverted bcs invalid

@mahtoid mahtoid reopened this May 10, 2023
@mahtoid
Copy link
Owner

mahtoid commented May 13, 2023

Closing this out, solved this in the 2.6.0 branch using Pycords latest solution. Will get a release out soon.

@mahtoid mahtoid closed this as completed May 13, 2023
@Lulalaby
Copy link

perfect

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants