Module Contents


class oioioi.quizzes.problem_sources.EmptyQuizSource[source]

Bases: oioioi.problems.problem_sources.ProblemSource

key = emptyquiz_source[source]
problem_controller_class = oioioi.quizzes.controllers.QuizProblemController[source]
view(request, contest, existing_problem=None)[source]

Renders the view where the user can upload the file or point out where to get the problem from.

If the request method is GET, it should return rendered HTML, which will be injected in an appropriate div element. TemplateResponse is fine, too.

If the request method is POST, it should start the unpacking process. If no errors occur, it should return HttpResponseRedirect (e.g. to a view with problem packages queued for processing).

  • request – Django request

  • contestContest where the problem is going to be attached (or is already attached); may be None.

  • existing_problemProblem to update (if problem update was requested)