message.content blank
See original GitHub issueSummary
missing data from discord
Reproduction Steps
Running the code snippet below just prints blanks across multiple servers I’ve tried
Minimal Reproducible Code
`
import discord
class MyClient(discord.Client):
async def on_ready(self):
print('Logged on as', self.user)
async def on_message(self, message):
print(message.content)
client = MyClient()
client.run('token')
`
Expected Results
should print message
Actual Results
blank
Intents
bot=false
System Information
- Python v3.8.5-final
- discord.py v1.6.0-final
- aiohttp v3.7.3
- system info: Linux 5.4.0-65-generic #73-Ubuntu SMP Mon Jan 18 17:25:17 UTC 2021 root@ubuntu-s-1vcpu-1gb-nyc1-01:~/discord#
Checklist
- I have searched the open issues for duplicates.
- I have shown the entire traceback, if possible.
- I have removed my token from display, if visible.
Additional Context
No response
Issue Analytics
- State:
- Created 2 years ago
- Comments:12 (4 by maintainers)
Top Results From Across the Web
Pycord message.content is empty - python - Stack Overflow
It seems using discord.py message.content will always be empty. ... You can solve this by enabling the MESSAGE CONTENT INTENT for your bot ......
Read more >message.content is always empty? : r/Discord_Bots - Reddit
OK so basically here's my code, when I print message.content to the console it always prints an empty string no matter what my...
Read more >OS12 Mail message content is blank - Apple Community
OS12 Mail message content is blank -- updated to 12.5, still a problem. Open Mail, and the sender/subject line appear in the preview...
Read more >Empty messages from discord - Repl.it Python Discord Bot
It seems that the messages from discord are triggering the code, but there is nothing in message.content. So replies based on content in...
Read more >Message Content Privileged Intent FAQ - Developers - Discord
If your bot or app is not approved for message content, the following fields of the message object in Gateway and API payloads...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yes, I realize that but in my case this applies to all messages coming through the stream not exclusively embeds or any other message type that would cause the content to be blank. Pure text content is missing
Judging from the comments and the parent issue this seems to only affect self-bots. Self-bots are deprecated and unsupported in v1.7. They are getting removed in v2.0. If this issue can be reproduced with a real bot account then I would have heard about it from official sources and other libraries, but since I haven’t I’m assuming this doesn’t apply to real bots.