久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    <bdo id='Uh9Qi'></bdo><ul id='Uh9Qi'></ul>
<legend id='Uh9Qi'><style id='Uh9Qi'><dir id='Uh9Qi'><q id='Uh9Qi'></q></dir></style></legend>

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

<tfoot id='Uh9Qi'></tfoot>

  • <i id='Uh9Qi'><tr id='Uh9Qi'><dt id='Uh9Qi'><q id='Uh9Qi'><span id='Uh9Qi'><b id='Uh9Qi'><form id='Uh9Qi'><ins id='Uh9Qi'></ins><ul id='Uh9Qi'></ul><sub id='Uh9Qi'></sub></form><legend id='Uh9Qi'></legend><bdo id='Uh9Qi'><pre id='Uh9Qi'><center id='Uh9Qi'></center></pre></bdo></b><th id='Uh9Qi'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='Uh9Qi'><tfoot id='Uh9Qi'></tfoot><dl id='Uh9Qi'><fieldset id='Uh9Qi'></fieldset></dl></div>

      1. 403 Forbidden(錯(cuò)誤代碼:50001):添加角色時(shí)缺少訪問(wèn)權(quán)

        403 Forbidden (error code: 50001): Missing Access when adding role | discord.py(403 Forbidden(錯(cuò)誤代碼:50001):添加角色時(shí)缺少訪問(wèn)權(quán)限 |不和諧.py)

        <tfoot id='uVWOF'></tfoot>
          <tbody id='uVWOF'></tbody>

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

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

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

                  本文介紹了403 Forbidden(錯(cuò)誤代碼:50001):添加角色時(shí)缺少訪問(wèn)權(quán)限 |不和諧.py的處理方法,對(duì)大家解決問(wèn)題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)吧!

                  問(wèn)題描述

                  我正在嘗試快速為人們分配不同的角色,以給用戶一種他們的名字是彩虹的印象(是的,我知道它反對(duì) TOS),并且我開(kāi)始在刪除他們之前向人們添加角色.但是,在添加角色時(shí),我在這篇文章的標(biāo)題中得到了錯(cuò)誤.我對(duì)此進(jìn)行了調(diào)查并嘗試了很多方法來(lái)解決它.機(jī)器人的角色比分配的角色更高.這是我的代碼和輸出:

                  I am trying to ass different roles to people rapidly to give users the impression of their name being rainbow ( yes I know its against TOS ), and I am starting by adding roles to people before I remove them. However, when adding roles I get the error in the title of this post. I have looked into this and tried quite a few ways to fix it. The bot has a higher role than the roles being give out. Here is my code and the output:

                  import discord
                  from discord.ext import commands
                  
                  bot = commands.Bot(command_prefix="$")
                  role_name = "Rainbow Six Seige"
                  peopleWithRole = []
                  guild = discord.Guild 
                  
                  @bot.event
                  async def on_ready():
                      print("Logged in as")
                      print(bot.user.name)
                      print("------")
                      guild = bot.guilds[0]
                      colours = [discord.utils.get(guild.roles, name='red'),
                                 discord.utils.get(guild.roles, name='green'),
                                 discord.utils.get(guild.roles, name='blue')
                                 ]
                  
                      role = discord.utils.find(
                          lambda r: r.name == role_name, guild.roles)
                          
                      for user in guild.members:
                          if role in user.roles:
                              peopleWithRole.append(user)
                  
                      for color in colours:
                          for user in peopleWithRole:
                              await user.add_roles(color)
                  
                  bot.run("my token")
                  

                  輸出:

                  Logged in as
                  test bot
                  ------
                  Ignoring exception in on_ready
                  Traceback (most recent call last):
                    File "C:UsersUserAppDataLocalProgramsPythonPython38-32libsite-packagesdiscordclient.py", line 312, in _run_event
                      await coro(*args, **kwargs)
                    File "C:UsersUserDesktop	est	est.py", line 29, in on_ready
                      await user.add_roles(color)
                    File "C:UsersUserAppDataLocalProgramsPythonPython38-32libsite-packagesdiscordmember.py", line 641, in add_roles
                      await req(guild_id, user_id, role.id, reason=reason)
                    File "C:UsersUserAppDataLocalProgramsPythonPython38-32libsite-packagesdiscordhttp.py", line 241, in request
                      raise Forbidden(r, data)
                  discord.errors.Forbidden: 403 Forbidden (error code: 50001): Missing Access
                  

                  推薦答案

                  確保您擁有授予機(jī)器人的角色,該角色可以訪問(wèn) managing roles.此外,當(dāng)您從開(kāi)發(fā)門戶添加機(jī)器人時(shí),您可以為其授予權(quán)限.

                  Make sure you have a role given to the bot which has access to managing roles. Also when you add the bot from the dev portal you can give it permissions.

                  最佳做法是創(chuàng)建一個(gè)名為 BOT 的角色,并擁有所有權(quán)限并將其提供給您在服務(wù)器中擁有的所有機(jī)器人

                  Best practice is to make a role called BOT with all the permissions and give it to all the bots you have in the server

                  這篇關(guān)于403 Forbidden(錯(cuò)誤代碼:50001):添加角色時(shí)缺少訪問(wèn)權(quán)限 |不和諧.py的文章就介紹到這了,希望我們推薦的答案對(duì)大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

                  【網(wǎng)站聲明】本站部分內(nèi)容來(lái)源于互聯(lián)網(wǎng),旨在幫助大家更快的解決問(wèn)題,如果有圖片或者內(nèi)容侵犯了您的權(quán)益,請(qǐng)聯(lián)系我們刪除處理,感謝您的支持!

                  相關(guān)文檔推薦

                  How to make a discord bot that gives roles in Python?(如何制作一個(gè)在 Python 中提供角色的不和諧機(jī)器人?)
                  Discord bot isn#39;t responding to commands(Discord 機(jī)器人沒(méi)有響應(yīng)命令)
                  Can you Get the quot;About mequot; feature on Discord bot#39;s? (Discord.py)(你能得到“關(guān)于我嗎?Discord 機(jī)器人的功能?(不和諧.py))
                  message.channel.id Discord PY(message.channel.id Discord PY)
                  How do I host my discord.py bot on heroku?(如何在 heroku 上托管我的 discord.py 機(jī)器人?)
                  discord.py - Automaticaly Change an Role Color(discord.py - 自動(dòng)更改角色顏色)
                  <tfoot id='CUaLs'></tfoot>
                • <i id='CUaLs'><tr id='CUaLs'><dt id='CUaLs'><q id='CUaLs'><span id='CUaLs'><b id='CUaLs'><form id='CUaLs'><ins id='CUaLs'></ins><ul id='CUaLs'></ul><sub id='CUaLs'></sub></form><legend id='CUaLs'></legend><bdo id='CUaLs'><pre id='CUaLs'><center id='CUaLs'></center></pre></bdo></b><th id='CUaLs'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='CUaLs'><tfoot id='CUaLs'></tfoot><dl id='CUaLs'><fieldset id='CUaLs'></fieldset></dl></div>

                        <tbody id='CUaLs'></tbody>

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

                        • <legend id='CUaLs'><style id='CUaLs'><dir id='CUaLs'><q id='CUaLs'></q></dir></style></legend>

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

                            主站蜘蛛池模板: 日本精品视频在线 | 国产福利91精品一区二区三区 | 午夜激情在线视频 | 久久国产区 | 欧美日韩国产在线观看 | 国产精品99免费视频 | 精品久久久久一区二区国产 | 一区二区三区回区在观看免费视频 | 国产精品成人久久久久 | 久久精品国产一区二区电影 | 91久久久久 | 精品福利一区二区三区 | 成人在线视频网 | 成人av片在线观看 | 成人精品一区二区 | 久久国产精品-国产精品 | 久草视频在线看 | 久免费视频 | 亚洲乱码国产乱码精品精的特点 | 亚洲国产免费 | 国产97色| 青青草一区 | 久久久久久亚洲精品 | 日本手机看片 | 久久久久久久久久爱 | 亚洲一区二区三区视频免费观看 | 久久精品亚洲成在人线av网址 | 国产成人精品免高潮在线观看 | 欧美激情五月 | 午夜电影网 | 久久久久久久久久毛片 | 超级黄色一级片 | 亚洲天堂av在线 | 国产福利91精品一区二区三区 | 日本三级在线网站 | 国产98在线 | 免费, | 日本高清不卡视频 | 成人免费观看男女羞羞视频 | 亚洲精品一二三区 | www.啪啪.com | 成年人在线观看 |