minio
This commit is contained in:
@@ -8,9 +8,9 @@ from django.http import JsonResponse, HttpResponse
|
||||
from django.utils import timezone
|
||||
|
||||
from Checker.models import Checker
|
||||
from FileStorage.sync import synchronized_method
|
||||
from Main.models import Solution, SolutionFile, ExtraFile, Progress
|
||||
from SprintLib.queue import send_to_queue
|
||||
from SprintLib.redis import lock
|
||||
from SprintLib.utils import generate_token
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ def status(request):
|
||||
return JsonResponse({"status": "incorrect token"}, status=403)
|
||||
|
||||
|
||||
@synchronized_method
|
||||
@lock('checker')
|
||||
def available(request):
|
||||
try:
|
||||
checker = Checker.objects.get(dynamic_token=request.GET['token'])
|
||||
|
Reference in New Issue
Block a user