asfenstealth.blogg.se

Discord translate bot
Discord translate bot




  1. #Discord translate bot update
  2. #Discord translate bot full
  3. #Discord translate bot professional

#Discord translate bot update

UPDATE : From what it seems, the problem happens inside the library, however this can happen if the parameter given to the library function is ill-formed. Have you tried changing your function's signature to this : async def translate(self, ctx, message): Have you tried debugging and checking at each step what the variables are and if they are not what you think they should beįinally, I also think that maybe your variable message is always empty, since you catch other parameters with * right before message so this makes the message parameter a keyword-only parameter, which, to the best of my knowledge cannot be passed when using a bot command

#Discord translate bot full

I cannot add comments since I do not have enough reputation, so I will edit this post once I get more information about your code.Ĭould you please upload the full traceback? Also what happens if before calling the method group on the object, you ensures that it is not None ? (I don't know if this is in your code or in the library) The above exception was the direct cause of the following exception:įile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\discord\ext\commands\bot.py", line 902, in invokeįile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\discord\ext\commands\core.py", line 864, in invokeįile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\discord\ext\commands\core.py", line 94, in wrappedĭ.CommandInvokeError: Command raised an exception: AttributeError: 'NoneType' object has no attribute 'group' Where am I going wrong? Any help would be much appreciated!Įdit: the full traceback: Ignoring exception in command translate:įile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\discord\ext\commands\core.py", line 85, in wrappedįile "C:\Users\wave computer\PycharmProjects\pythonProject\cogs\translate.py", line 13, in translateįile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\googletrans\client.py", line 255, in detectĭata = self._translate(text, 'en', 'auto', kwargs)įile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\googletrans\client.py", line 78, in _translateįile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\googletrans\gtoken.py", line 194, in doįile "C:\Users\wave computer\PycharmProjects\pythonProject\venv\lib\site-packages\googletrans\gtoken.py", line 62, in _updateĬode = self.RE_TKK.search(r.text).group(1).replace('var ', '')ĪttributeError: 'NoneType' object has no attribute 'group' Translation = anslate(message)Įmbed = discord.Embed(color=_theme())Įmbed.add_field(name=f"Language: ')īut it shows this error: .CommandInvokeError: Command raised an exception: AttributeError: 'NoneType' object has no attribute 'group'. My following cog code is: "Tl", "Translate"])Īsync def translate(self, ctx, *, message):

discord translate bot

So after my import statements, I have translator = Translator(). It seems fairly simple and it should have worked without any hassle, or so I thought. Let QuillBot’s AI sift through research papers, news articles, or long-winded emails to identify the main points and give you a high-level overview of the material.I've been trying to make my discord bot translate texts using a module called googletrans. When it comes to staying on top of your reading list, try our instant text summary tool-a.k.a. With one click, QuillBot will scan your writing and alert you to any errors in grammar, spelling, punctuation, word misuse, and more so that you can easily see what’s amiss and fix it fast. When your draft is complete, and you’ve ironed out all of the bumps in your content, put the final polish on your written work quickly and easily with our new Grammar Checker. If you’re looking to paraphrase online, there’s only one place to go, and you’re already here. Writing with confidence will change the way you interact with the world, and QuillBot is ready to help you elevate your skills.

#Discord translate bot professional

Authors, students, researchers, journalists, attorneys, and everyone in between have employed the paraphraser to reword writing for school essays, professional correspondence, creative storytelling, and personal projects.

discord translate bot discord translate bot discord translate bot

No matter who you are or what you do, QuillBot has writing and research tools to support you in making your work come alive. Whether you’re writing emails, essays, or social media posts, QuillBot's paraphrasing tool has your back.






Discord translate bot