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

When participant p1 is assigned to participant p2 then p2 should not be assigned to participant p1 so that it is always possible to remove a participant #544

Open
mbt-eric-b opened this issue Dec 21, 2021 · 3 comments

Comments

@mbt-eric-b
Copy link

To date, if p1 and p2 are participant to each other, you cannot remove one of them because the remaining participant would become self-assigned
In order to prevent this, participants should be assigned to one another like a chianed list :

  1. randomly order the participants
  2. assign each participant to the next one in the list
  3. assign the first participant of the list to the last participant of the list

This way, removing one will not create a self-assigned participant until there are only 2 participants left

@mbt-eric-b mbt-eric-b changed the title When participant p1 is assigned to participant p2 then p2 should not be assign to participant p1 so that it is always possible to remove a participant When participant p1 is assigned to participant p2 then p2 should not be assigned to participant p1 so that it is always possible to remove a participant Dec 21, 2021
@tvlooy
Copy link
Collaborator

tvlooy commented Dec 21, 2021

This is too easy to be true unfortunately. This was our initial "algorithm" but no longer works when taking excludes into account.

@benji1000
Copy link

Hello! I'm bumping this issue because I too, think it is annoying that pairs of participants are created. Not because it isn't possible to remove one of them as Eric mentioned, but because we think it is far less fun! I used the website two years in a row, and each year, it created two pairs amongst the 8 participants (the same pairs each year, what are the odds!).

I don't see why it wouldn't be possible to proceed this way, even when dealing with exclusions. At least, as long as exclusions are made beforehand and nobody leaves the party. Which, I'm thinking, should match with the vast majority of cases.

So I think an option should be added on the admin panel to prevent the creation of pairs of attendees. Again, maybe that it won't match 100% of cases, but it should work for the vast majority of cases, and shouldn't be hard to implement.

@tvlooy
Copy link
Collaborator

tvlooy commented Jan 30, 2023

it should be possible to add and remove people. We already have pretty clever code for that. I don't have a good solution for the shuffler, so give it a try and I welcome your contribution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants