#Why is guild.categories returning an empty list?
1 messages · Page 1 of 1 (latest)
not sure, maybe it isn't cached properly?
fwiw, you can get a categorychannel from guild.get_channel too
Thats what I'm not sure about, can't see any changes
get_channel returns None too
hmmm
checked permission they are the same
so guild.channels is also returning None? or is that fine
returns an empty list []
hmmmmmmmmmm
just checking, what intents do you have set?
if all else fails, you can use await guild.fetch_channels() to return all channels and then check using that, but you shouldn't have to do that
https://docs.pycord.dev/en/master/api.html#discord.Guild.fetch_channels
all of em
weird
hmmm idt I can use await in __init__
wait
is this being run before on_ready?
like during a cog load
yep
then it's always gonna fail
lol
the cache is only gonna be filled after on_ready has fired
you should use an on_ready listener inside your cog, and inside that you can access the cache
ooh
is this correct? I dont think on_ready() gets run because I dont see --> Timers cog loaded in the output
oop I have a wait until ready there
removing it didnt make any changes
That should work, but maybe in the init include self.GUILD = None?
f#ck it, I put a 2 seconds sleep in main on_ready() so it works now