You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not sure what's happening but the object returned from get_top_clans seems to bug when iterated through. When I print the object, I get this single item I requested (limit=1). But when I iterate through it I get a near infinite loop of objects.
CODE
officialClient = clashroyale.official_api.Client(officialAPIToken)
lTopClans = officialClient.get_top_clans(limit=1)
print('Number of Clans:', len(lTopClans))
for i in lTopClans:
print(i.tag)
EXPECTED:
Number of Clans: 1
#GYUQQCLV
ACTUAL:
Number of Clans: 1
#GYUQQCLV
#GYUQQCLV
#2CLV2RP0
#GYUQQCLV
#2CLV2RP0
#2GGR2GPQ0
#GYUQQCLV
#2CLV2RP0
#2GGR2GPQ0
#2LJ0ULYCC
#GYUQQCLV
#2CLV2RP0
#2GGR2GPQ0
#2LJ0ULYCC
#GUPYJ2
You'll see there's actually a pattern to it: it's returning like this:
Hello,
Not sure what's happening but the object returned from get_top_clans seems to bug when iterated through. When I print the object, I get this single item I requested (limit=1). But when I iterate through it I get a near infinite loop of objects.
CODE
EXPECTED:
ACTUAL:
You'll see there's actually a pattern to it: it's returning like this:
But obviously, it was only supposed to return 1 item altogether.
The text was updated successfully, but these errors were encountered: