Badge granted when topic created

AI-generated summary

The discussion addresses a discrepancy where a topic badge displayed a grant date of 16 hours ago (topic creation) rather than the actual time the 10th like was received. EJGamerCake noted the badge appeared to be granted upon topic creation. codinghorror queried the desired behavior, to which sam explained that while the 10th like is the intended trigger, calculating the exact timestamp is technically expensive. Falco suggested using CURRENT_TIMESTAMP, but sam argued this creates inconsistencies during backfills, particularly in edge cases where a topic is deleted and undeleted, causing the badge to be re-granted at a different time. Falco countered that granting the badge upon system job execution is preferable, as it aligns with user expectations of periodic system checks, similar to how banking transactions or MMO achievements are processed with slight delays.

When I got a nice topic badge, it said that it was granted 16 hours ago, which was when I created the topic.

I did not receive the badge 16 hours ago, it hit 10 likes a few minutes ago.

「いいね!」 2

What is the desired behavior here @sam?

「いいね!」 1

Desired is 10th like but it’s technically very expensive to find the 10th like so you have the date

「いいね!」 4

Is this the minutely BadgeGranter job? What about using CURRENT_TIMESTAMP for the date?

「いいね!」 1

That works but does not work for backfills (which are always running and fixing stuff) and you end up having an inconsistent badge grant date.

Example edge case:

  • You are granted badge
  • Someone deletes topic
  • You are ungranted badge
  • Someone undeletes topic
  • You are granted the badge at a completely different date
「いいね!」 3

I would argue that it’s better that way, even on this edge case, because people would understand that the grant occurred when the system saw the topic was back.

Like I think it’s better to grant on job execution because people would understand that the system checks are periodic.

This map to know stuff on a lot of real and virtual stuff: bank system payments on weekend show as monday, MMO RPG granting a quest or achievement on a later date etc.

But I digress. Don’t want to bike-shed more :smile:.

「いいね!」 1