Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix duplicate tournament stat entries #572

Closed
wants to merge 2 commits into from

Conversation

hburn7
Copy link
Collaborator

@hburn7 hburn7 commented Dec 24, 2024

When re-running the processor/dataworker flow multiple times, tournament stats will be generated and attempted to be inserted multiple times. This PR adds a check to skip adding new tournament stats if they already exist for the player, for the current tournament.

Depends on:

@myssto can you confirm if this is a safe implementation? I think so because tournament stats don't seem to be variable between runs.

@hburn7 hburn7 added bug A confirmed or reported event of unexpected behavior area:processing project:DataWorkerService Items related to the DataWorkerService project labels Dec 24, 2024
@hburn7 hburn7 requested a review from myssto as a code owner December 24, 2024 13:47
@myssto
Copy link
Contributor

myssto commented Dec 25, 2024

I think so because tournament stats don't seem to be variable between runs.

They are variable between runs because they take a total rating delta over all matches played. They need to be truncated before each ratings processor run

@hburn7
Copy link
Collaborator Author

hburn7 commented Dec 25, 2024

Okay will implement that on the processor and probably close this then?

@hburn7
Copy link
Collaborator Author

hburn7 commented Dec 26, 2024

@hburn7 hburn7 closed this Dec 26, 2024
@hburn7 hburn7 deleted the hotfix/duplicate-stat-entry branch December 26, 2024 23:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:processing bug A confirmed or reported event of unexpected behavior project:DataWorkerService Items related to the DataWorkerService project size/XS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants