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

History competition order on persons page #9526

Open
oyyq99999 opened this issue Jun 8, 2024 · 1 comment
Open

History competition order on persons page #9526

oyyq99999 opened this issue Jun 8, 2024 · 1 comment
Labels
SERVICE: person TYPE: bug Bug reported by a stakeholder

Comments

@oyyq99999
Copy link
Contributor

Describe the bug
Let's look at https://www.worldcubeassociation.org/persons/2022PHAN03?event=222
We can see that it LOOKS LIKE he broke the NR average with 1.06 in Sunway Velocity Mall Open 2024, and then broke it again with a 1.09 average in Singapore Mini 2024, which is confusing.

It can be much better, but NOT FIXED by adding Competitions.end_date DESC after Competitions.start_date DESC in

@results = @person.results.includes(:competition, :event, :format, :round_type).order("Events.rank, Competitions.start_date DESC, Competitions.id, RoundTypes.rank DESC")
, which should make more cases correct.

I'm not quite sure if there's any more elegant way to resolve that so didn't make a PR, sorry about that.

To Reproduce
Steps to reproduce the behavior:
N/A

Desktop (please complete the following information):
N/A

Smartphone (please complete the following information):
N/A

Additional context

@dunkOnIT
Copy link
Contributor

We can't determine on what date a specific result was achieved (long story, but slated to be fixed soon).

Your approach is appealing because of its simplicity. My question would be: What do you think about the opposite edge cases this creates - where someone breaks a record FIRST at a competition that ends later, than at a competition that ends earlier. (My suspicion is that we have less edge cases with using end_date, but would appreciate your thoughts/research on this).

There might also be a frontend-based approach where we reorder the items in the table based on if there are inconsistent record markers, but I'd hold off on anything like that until the Person page is transitioned to React.

@dunkOnIT dunkOnIT added TYPE: bug Bug reported by a stakeholder SERVICE: person labels Jun 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
SERVICE: person TYPE: bug Bug reported by a stakeholder
Projects
None yet
Development

No branches or pull requests

2 participants