v0.3.3 Release Notes
Released
v0.3.2 -> v0.3.3
Summary
Fixes
Input.ChannelName always being "" on Discord. The intent bitmask was missing IntentGuilds, so the gateway never delivered GUILD_CREATE / CHANNEL_* events—Session.State had no channel data and State.Channel(channelID) always returned not-found, making the v0.3.2 ChannelName accessor silently useless. Adding IntentGuilds to Identify.Intents restores state cache population; ChannelName now resolves zero-round-trip as designed.翻譯
修正 v0.3.2Input.ChannelName 在 Discord 永遠是空字串的問題。Identify.Intents 缺 IntentGuilds,gateway 不會推 GUILD_CREATE / CHANNEL_* 事件——Session.State 拿不到 channel 資料、State.Channel(id) 永遠 not-found,v0.3.2 才剛加的 channelName accessor 形同擺設。bitmask 加上 IntentGuilds 後 state cache 才會被 gateway 餵資料,ChannelName 也才真的拿得到值。Changes
FIX
- Add IntentGuilds so Discord state cache populates ChannelName (@pardnchiu) [d40c349]
翻譯
discord.New的Identify.Intents加IntentGuilds(非 privileged,不需 Developer Portal 開)- 修復 v0.3.2
Input.ChannelName一直拿到空字串的 root cause(state cache 沒被 gateway 餵資料)
Scope
discord/bot.go— FIX(api.Identify.Intents加discordgo.IntentGuilds)
Generated by SKILL