<legend id='W5n4T'><style id='W5n4T'><dir id='W5n4T'><q id='W5n4T'></q></dir></style></legend>
<tfoot id='W5n4T'></tfoot>

<small id='W5n4T'></small><noframes id='W5n4T'>

    1. <i id='W5n4T'><tr id='W5n4T'><dt id='W5n4T'><q id='W5n4T'><span id='W5n4T'><b id='W5n4T'><form id='W5n4T'><ins id='W5n4T'></ins><ul id='W5n4T'></ul><sub id='W5n4T'></sub></form><legend id='W5n4T'></legend><bdo id='W5n4T'><pre id='W5n4T'><center id='W5n4T'></center></pre></bdo></b><th id='W5n4T'></th></span></q></dt></tr></i><div id='W5n4T'><tfoot id='W5n4T'></tfoot><dl id='W5n4T'><fieldset id='W5n4T'></fieldset></dl></div>

      • <bdo id='W5n4T'></bdo><ul id='W5n4T'></ul>
    2. TypeError:禁止从 URL 继承类

      时间:2023-10-11

          <tbody id='kE3Vy'></tbody>

        <legend id='kE3Vy'><style id='kE3Vy'><dir id='kE3Vy'><q id='kE3Vy'></q></dir></style></legend>
        <tfoot id='kE3Vy'></tfoot>
      • <small id='kE3Vy'></small><noframes id='kE3Vy'>

          <bdo id='kE3Vy'></bdo><ul id='kE3Vy'></ul>

              • <i id='kE3Vy'><tr id='kE3Vy'><dt id='kE3Vy'><q id='kE3Vy'><span id='kE3Vy'><b id='kE3Vy'><form id='kE3Vy'><ins id='kE3Vy'></ins><ul id='kE3Vy'></ul><sub id='kE3Vy'></sub></form><legend id='kE3Vy'></legend><bdo id='kE3Vy'><pre id='kE3Vy'><center id='kE3Vy'></center></pre></bdo></b><th id='kE3Vy'></th></span></q></dt></tr></i><div id='kE3Vy'><tfoot id='kE3Vy'></tfoot><dl id='kE3Vy'><fieldset id='kE3Vy'></fieldset></dl></div>
              • 本文介绍了TypeError:禁止从 URL 继承类的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                问题描述

                我在尝试运行我为 Discord 制作的机器人时遇到了这个错误.这发生在下载一些模块后.有没有办法解决这个问题?

                I run into this error when trying to run a bot I made for Discord. This occurred after downloading some modules. Is there any way to fix this?

                Traceback (most recent call last):
                  File "C:UsersJerielDesktopJerryBot
                un.py", line 1, in <module>
                    import discord
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesdiscord\__
                init__.py", line 20, in <module>
                    from .client import Client, AppInfo
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesdiscordcl
                ient.py", line 30, in <module>
                    from .guild import Guild
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesdiscordgu
                ild.py", line 39, in <module>
                    from .channel import *
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesdiscordch
                annel.py", line 31, in <module>
                    from .webhook import Webhook
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesdiscordwe
                bhook.py", line 27, in <module>
                    import aiohttp
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttp\__
                init__.py", line 6, in <module>
                    from .client import *  # noqa
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttpcl
                ient.py", line 15, in <module>
                    from . import connector as connector_mod
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttpco
                nnector.py", line 17, in <module>
                    from .client_proto import ResponseHandler
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttpcl
                ient_proto.py", line 6, in <module>
                    from .http import HttpResponseParser, StreamWriter
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttpht
                tp.py", line 8, in <module>
                    from .http_parser import (HttpParser, HttpRequestParser, HttpResponseParser,
                
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttpht
                tp_parser.py", line 15, in <module>
                    from .http_writer import HttpVersion, HttpVersion10
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesaiohttpht
                tp_writer.py", line 304, in <module>
                    class URL(yarl.URL):
                  File "C:UsersJerielAppDataRoamingPythonPython36site-packagesyarl\__ini
                t__.py", line 230, in __init_subclass__
                    "is forbidden".format(cls))
                TypeError: Inheritance a class <class 'aiohttp.http_writer.URL'> from URL is for
                bidden
                

                推荐答案

                Discord.py rewrite 分支最近在 requirements.txt 和 aiohttp 支持上出现了一些问题.需要手动安装低版本的 yarl 来支持 discord.py 所需的 aiohttp 库.

                Discord.py rewrite branch has some problems recently with its requirements.txt and aiohttp support. You need to manually install a lower version of yarl to support discord.py's required aiohttp library.

                您需要运行以下命令:

                pip install "yarl<1.2"
                

                <小时>

                更新

                新版本的 discord.py rewrite 修复了这个问题,您不再需要按照上述解决方案进行操作.正确的做法是从 GitHub 重新下载 discord.py rewrite 并升级包.


                UPDATE

                The new versions of discord.py rewrite fixed this problem, you no longer need to do follow the aforementioned solution. The correct action to take is to re-download discord.py rewrite from GitHub and upgrade the packages.

                这篇关于TypeError:禁止从 URL 继承类的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                上一篇:Discord.py 拼写检查命令 下一篇:如何使用 discord.py 按 ID 删除特定消息

                相关文章

                最新文章

              • <tfoot id='nnpOd'></tfoot>

                  <small id='nnpOd'></small><noframes id='nnpOd'>

                    <legend id='nnpOd'><style id='nnpOd'><dir id='nnpOd'><q id='nnpOd'></q></dir></style></legend>
                    <i id='nnpOd'><tr id='nnpOd'><dt id='nnpOd'><q id='nnpOd'><span id='nnpOd'><b id='nnpOd'><form id='nnpOd'><ins id='nnpOd'></ins><ul id='nnpOd'></ul><sub id='nnpOd'></sub></form><legend id='nnpOd'></legend><bdo id='nnpOd'><pre id='nnpOd'><center id='nnpOd'></center></pre></bdo></b><th id='nnpOd'></th></span></q></dt></tr></i><div id='nnpOd'><tfoot id='nnpOd'></tfoot><dl id='nnpOd'><fieldset id='nnpOd'></fieldset></dl></div>
                    • <bdo id='nnpOd'></bdo><ul id='nnpOd'></ul>