question

walaber avatar image
walaber asked

NextReset returning strange values

I'm having a problem with the NextReset value returned by the leaderboard API that doesn't seem to the the same as other issues I've found searching the forum.

like many other users, I'm trying to display an in-game timer to indicate how long until the leaderboard resets. I'm querying the leaderboard, and then using the NextReset property, subtracting the current UTC time, and displaying the difference.

My current issue is that I'm not sure NextReset is returning the correct value. Here's a screenshot of my current leaderboard "weekly_time":

as you can see the current version is "31", and it's been live for nearly a week.

however, when I get the request results from the API, it confirms the current version is 31, but states the NextReset time as 8/19/2018, which is more like 2 weeks (8/6 to 8/19). Shouldn't it be returning 8/13?

What am I missing here?

apisLeaderboards and Statistics
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
brendan avatar image
brendan answered

What is your Title ID, so that we can have a look?

7 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

walaber avatar image walaber commented ·

my Title id is: DB3E

0 Likes 0 ·
brendan avatar image brendan walaber commented ·

I just made the GetLeaderboard call for both your weekly resetting leaderboards, and they both came back with the correct information on the next reset (August 19th). If you're seeing something different, can you please specify the API call you're making, including the values you're passing in for the parameters?

0 Likes 0 ·
walaber avatar image walaber brendan commented ·

indeed, calling now in the game it's returning the new version (32), and the reset time is seemingly correct at 8/19/2018. But that doesn't explain why a few days ago before the reset (when the version was 31), it was already returning 8/19 as the reset time... perhaps the issue only appears when the reset is approaching, or there is a (meaningfully long) delay between the leaderboard still reporting the old version, but the server thinks it's already reset and so it's returning the *next* reset time?

At the time of the post above, you can see the web dashboard it was still version 31, and clearly due to reset sooner.

for reference the dashboard now shows that it did indeed reset to version 32, and it happened on 8/13.

0 Likes 0 ·
Show more comments
walaber avatar image walaber commented ·

OK, looking at this again this week, things still look strange. Current version of the leaderboard is still 32. at the time of this post, the leaderboard API is returning a NextReset time of:

08/19/2018 00:00:00

According to Google, at the time of this post it's currently:

08/18/2018 21:35:00 aka 9:35PM on 8/18. So the leaderboard should reset in approximately 2 1/2 hours, correct?

However if I look on the dashboard it claims the leaderboard was last reset on 8/13 morning, which would mean that the leaderboard should actually reset on 8/20/2018 at 00:00:00... is the NextReset returning a value that's 24 hours too early? that would explain the values I'm seeing I think.

0 Likes 0 ·
walaber avatar image walaber walaber commented ·

it looks a lot to me like NextReset value is being reset at the advertised time, but the actual leaderboard itself doesn't reset until 24 hours later.

0 Likes 0 ·
brendan avatar image brendan walaber commented ·

Aha! Yes, now I see what you're pointing out. Thanks for calling that out - I'll get a bug opened on it. The "when is the next reset" logic is indeed one day off from the actual reset time. Not sure when that regression was introduced, but we'll get it fixed ASAP.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.