Closed sortedcord closed 2 years ago
Because the 5th event of that user is a UserSupportAgainEvent
, which means they bought supporter ("again", ie it wasn't their first time buying supporter). The scoreRank
attribute obviously won't exist on this event; the only attribute that does is .user
. You'll need to check what type of event recent_activity
is before accessing any attributes.
Oh, thanks for that. Also, I shouldn't be piggybacking this issue, but whenever there is an achievement event in the recent activities it returns a ValueError: None is not a valid GameMode
instead of an AchiementEvent Object. Maybe something to do with the default value set here?
you linked code for ossapi and not ossapiv2, so unless you're using api v1 I don't think that's related ;)
the actual issue was that mode could be null for EventAchivement
. closed by ccd0d6898802c23d4f4c9be7fc30165e5c9d9d25, will be fixed in next release
Thanks again
Saw this happen with
api.user_recent_activity
.This works well but whenever I change the limit to be greater than 5, it always gives this error
If I check the type of
recent_activity
whenever the limit is greater than 4, it returnsRankEvent
orRankLostEvent
, so what is theUserSupportAgainEvent
?