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

Feature Request: Allow Final match to be a draw #160

Closed
GrimLothar opened this issue Jan 11, 2023 · 3 comments
Closed

Feature Request: Allow Final match to be a draw #160

GrimLothar opened this issue Jan 11, 2023 · 3 comments
Labels
wontfix This will not be worked on

Comments

@GrimLothar
Copy link

Although it's definitely an edge case, we are seeing the possibility of a final match in an elimination tournament to have a no-show on both participants. After some thought, we figure that the best resolution in this case, would be for them both to share the 1st place.

The match would of course would have no winners, so I tried setting the match as a draw. Good news is that it allowed me to do it.
Bad news is that the Brackets UI is not showing the match as finished. It's still showing it with the default dashes:

Screen Shot 2023-01-11 at 4 47 28 PM

Second bad news is that when I try to get the final standings, for some reason it's just removing one of the final participants from the rank:

  { id: 24, name: '37oe...gepS', rank: 1 },
  { id: 1, name: 'Lothar', rank: 2 },
  { id: 6, name: 'LotharLurker', rank: 2 }

You can reference the above image as well for the full list of participants. It removed the Ayrious2 participant.

Would it be too hard to allow for this scenario to happen? And if you don't have the time to support it, do you mind sharing some pointers on what would need to be changed and I can try to make a PR myself?

Thanks!

@Drarig29 Drarig29 added the enhancement New feature or request label Feb 5, 2023
@Drarig29
Copy link
Owner

Drarig29 commented Feb 5, 2023

Hey! Sorry for the delay.

The match would of course have no winners, so I tried setting the match as a draw. Good news is that it allowed me to do it.

The lib is actually ignoring the result: "draw" value when you use manager.update.match(). It's not "allowing you to do it", it's just doing nothing silently. If you look at the JSON, the final match will still be running ("status": 2), without any result. So the viewer behaves correctly.


Second bad news is that when I try to get the final standings, for some reason it's just removing one of the final participants from the rank

That's weird because with my snippet, the lib throws a "Participant not found." error, since the final match doesn't have a winner. I'll add a better error message for this.


Would it be too hard to allow for this scenario to happen?

I won't even try to evaluate the difficulty for this, because I simply won't let this happen and won't accept a PR for it, I'm sorry. This is more than an "edge case": it's an invalid case in this format of tournament.

The [single elimination format] is less suited to games where draws are frequent. In chess, each fixture in a single-elimination tournament must be played over multiple matches, because draws are common, and because white has an advantage over black. In association football, games ending in a draw may be settled in extra time and eventually by a penalty shootout or by replaying the fixture. (Source: Wikipedia)

The only update I would be willing to do to the lib is to throw an error message when trying to set a draw as a result in an elimination tournament (single and double elimination).

As you said this is an edge case for you, I'll let you support this on your side. If you really want to display this case with the viewer, I suggest you override the result with "opponent1": {"result": "loss"}, "opponent2": {"result": "loss"}:

image

(This works because the viewer doesn't have any "tournament logic", it will simply display what you give to it.)

@Drarig29 Drarig29 closed this as completed Feb 5, 2023
@Drarig29
Copy link
Owner

Drarig29 commented Feb 5, 2023

All online tournament management tools I know do not support this case either.

Toornament

image

Challonge

image

@Drarig29 Drarig29 added wontfix This will not be worked on and removed enhancement New feature or request labels Feb 11, 2023
@GrimLothar
Copy link
Author

Thank you as always for your detailed responses! I fully understand your decision to not support this scenario. I agree it's super edge case. Will figure out what to do with it when/if it happens. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants