Skip to content

Conversation

@bbearce
Copy link
Collaborator

@bbearce bbearce commented Jun 6, 2023

This is code to fix the queue error when adding a competition manually with the editor.

Manually creating a comp with queue throws wrong datatype error. We need to be able to set queue when creating competiton.

Issues this PR resolves

Checklist

  • Code review by me
  • Hand tested by me
  • I'm proud of my work
  • Code review by reviewer
  • Hand tested by reviewer
  • CircleCi tests are passing
  • Ready to merge

@Didayolo
Copy link
Member

Didayolo commented Jun 6, 2023

@bbearce Thanks for the PR.

There is no way to avoid the new class CompetitionCreateSerializer by having somehow the queue = None optionnaly in CompetitionSerializer?

I am testing the change right now.

Not sure if it's due to this change, but I need to search for my queue to have it shown. By just clicking, I have "no results found", while on codabench.org I can see all queues:

Capture d’écran 2023-06-06 à 13 24 27

@bbearce
Copy link
Collaborator Author

bbearce commented Jun 6, 2023

Did you have a queue created? You need to have made one first. I imagine you did but not sure. Regarding the CompetitionCreateSerializer, there may be a way to just use the CompetitionSerializer and set queue = None after the fact. The CompetitionUpdateSerializer does the same pattern as CompetitionCreateSerializer. I copied the pattern.

Perhaps after instatiating the CompetitionSerializer we can do something like CompetitionSerializer.queue = None...

@Didayolo
Copy link
Member

Didayolo commented Jun 6, 2023

@bbearce I had a queue created. On your side, when you simply click without searching for a queue using a keyword, does the queue appear?

EDIT: I confirm it's working. I guess it was an issue of refreshing with the new queue in.

@Didayolo Didayolo merged commit f55e5cc into develop Jun 6, 2023
@Didayolo Didayolo deleted the manual_comp_create_queue branch June 6, 2023 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants