Lots of moving parts here, so this is probably more of a request for pointers on where to look to figure out what the problem is. Here is the symptom visually:
I am using Wordpress SSO (via the PrimeTime SSO Plugin, poke @etc ) as well as the wp-discourse plugin (though not using SSO through that plugin because it doesn’t work for me) and I created a new test user in wordpress and then logged in from Discourse as that test user. The letter avatar for the test user shows as in the picture above, i.e. there is no letter.
When I first set up and connected Discourse with WP, using my WP admin account, the avatar created in Discourse was fine for that user:
Having taken a cursory look through the avatar creation code (and not being a ruby dev at all), my first thought was that maybe there is some sequence of events in a wordpress SSO login for a new user where it is trying to create the avatar before it knows the user’s name? Obviously since the first user worked, it doesn’t always happen. I’m sorry but I have no idea what difference there might have been in the sequence of events between the user that worked and the one that didn’t.
I also have the Discourse preference set called “sso overrides avatar”, thinking that if our existing users happened to have an avatar set already in their wordpress profile that it would be good to import it. But looking at the code of the PrimeTime SSO plugin, it looks to me like they are not implementing avatars as part of the SSO payload. In any case, neither my original admin user nor the new test user had wordpress avatars defined.
So, with all that background here are a couple specific questions:
- Where should I look to try to figure out how/why this might be happening?
- Is there any way on the Discourse side to force a “re-creation” of the letter avatar for a specific user?