Discord XF users not being added to Discord server after associating account?

Heyoo!!! I'm sure I've done something wrong haha, so I'm not posting this as a bug report.

I have my Discord bot set up and it's posting XF posts to the Discord server correctly. Each forum's posts and replies are going to the right Discord channel. Perfect.

However, when users associate their Discord account with their XF account and authorise the bot... they never get added to the Discord server, and their associated accounts page just says "Join Pending".

If they join via a manual link, they don't get Discord roles assigned, even on a manual server sync.

Bot is the second highest role in the server, has all the correct permissions... What step have I missed to make it work? (I have ADHD, I'm very used to missing a step and it being the vital one lmao).
 
Okay, I'm noticing that roles are getting added about 24ish hours after the user (manually) joins the server, then the bot is associating their XF and Discord accounts about 48 hours after they joined the server.

Is there a cron job I need to run more frequently? And why didn't this happen after a manual sync?
 
Sorry for the delay, been away for a couple days.

has all the correct permissions
If you check Admin -> Discord -> Discord servers, does the bot have permission to invite people here (create instant invite) or have admin?

Okay, I'm noticing that roles are getting added about 24ish hours after the user (manually) joins the server, then the bot is associating their XF and Discord accounts about 48 hours after they joined the server.
This suggests you might have an add-on or something conflicting with the process. User sync is triggered whenever a user's usergroups change so in theory, it should be almost instantaneous to propagate role changes to Discord. If another add-on does something wonky with user group additions / removals, it can affect the sync though. If you open a ticket here with your add-on list, I can give it a look.
Is there a cron job I need to run more frequently?
Because of the above, there isn't a cron but I might look in to something to catch things like this.
And why didn't this happen after a manual sync?
I don't have the code in front of me right now but if I recall, the manual sync button you clicked only pulls in up to date server information.
That said, roles only got added to two of four users and several days later it's stayed that way.
Are the other users admins or otherwise outranking the bot with their current roles?
 
Back
Top