53ee9b69f9e9c44f654e6ce604c57f58a987f749,app/evaluation/views.py,SubmissionCreate,get_context_data,#SubmissionCreate#,104
Before Change
config = Config.objects.get(challenge__pk=self.request.project_pk)
date_from = timezone.now() - timedelta(days=1)
submissions = Submission.objects.filter(
challenge__pk=self.request.project_pk,
creator=self.request.user,
created__gte=date_from,
).order_by("created")
remaining_submissions = config.daily_submission_limit - len(
submissions)
if remaining_submissions <= 0:
next_sub_at = submissions[0].created + timedelta(days=1)
else:
next_sub_at = timezone.now()
After Change
config = Config.objects.get(challenge__pk=self.request.project_pk)
context.update(
self.get_next_submission(max_subs=config.daily_submission_limit)
)
pending_jobs = Job.objects.filter(
challenge__pk=self.request.project_pk,
submission__creator=self.request.user,
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 6
Instances
Project Name: comic/grand-challenge.org
Commit Name: 53ee9b69f9e9c44f654e6ce604c57f58a987f749
Time: 2018-02-22
Author: jamesmeakin@gmail.com
File Name: app/evaluation/views.py
Class Name: SubmissionCreate
Method Name: get_context_data
Project Name: comic/grand-challenge.org
Commit Name: 3c53d87a9515c81df25b818e577d7dce66f18f90
Time: 2013-07-08
Author: w.s.kerkstra@gmail.com
File Name: django/comicsite/tests.py
Class Name: ViewsTest
Method Name: _signup_user
Project Name: comic/grand-challenge.org
Commit Name: 6499769919b50f645fd3d76623225eacf0cd141d
Time: 2013-07-08
Author: w.s.kerkstra@gmail.com
File Name: django/comicsite/tests.py
Class Name: ViewsTest
Method Name: _signup_user