Hello, how do I fix this? (i'm using the basic discord bot tutorial)

Traceback (most recent call last):
File “main.py”, line 6, in
client = discord.Client()
TypeError: init() missing 1 required keyword-only argument: ‘intents’

client = discord.Client(discord.Intents.defaults()) try this or equivalent. Discord.py now requires intents to be initialized

I tried this, but it just comes up with this

Traceback (most recent call last):
File “main.py”, line 6, in
client = discord.Client(discord.Intents.defaults())
AttributeError: type object ‘Intents’ has no attribute ‘defaults’

I apologize for my typo

import discord

client = discord.Client(intents=discord.Intents.default())

THANK YOU SO MUCH!
thanks!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.