From 10a57f88da49cd99d4a8c20d8d8ce39fcd9d25cc Mon Sep 17 00:00:00 2001 From: undefined Date: Thu, 10 Dec 2020 22:56:07 +0800 Subject: [PATCH] =?UTF-8?q?judge:=20=E6=B5=8B=E8=AF=95=E7=82=B9=E4=B8=AD?= =?UTF-8?q?=E4=B8=8D=E4=BC=A0=E5=85=A5STATUS=5FJUDGING?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/hydrojudge/package.json | 2 +- packages/hydrojudge/src/judge/default.ts | 2 -- packages/hydrooj/src/handler/problem.ts | 3 --- 3 files changed, 1 insertion(+), 6 deletions(-) diff --git a/packages/hydrojudge/package.json b/packages/hydrojudge/package.json index 11da4c22f..4c79ad68d 100644 --- a/packages/hydrojudge/package.json +++ b/packages/hydrojudge/package.json @@ -1,7 +1,7 @@ { "name": "@hydrooj/hydrojudge", "bin": "bin/hydrojudge.js", - "version": "2.1.33", + "version": "2.1.34", "main": "package.json", "author": "masnn", "repository": "https://github.com/hydro-dev/Hydro.git", diff --git a/packages/hydrojudge/src/judge/default.ts b/packages/hydrojudge/src/judge/default.ts index 2cad0f986..222a48d52 100644 --- a/packages/hydrojudge/src/judge/default.ts +++ b/packages/hydrojudge/src/judge/default.ts @@ -22,7 +22,6 @@ function judgeCase(c, sid) { || (ctxSubtask.subtask.type === 'max' && ctxSubtask.score === ctxSubtask.subtask.score) || (ctxSubtask.subtask.if && ctx.failed[sid])) { ctx.next({ - status: STATUS.STATUS_JUDGING, case: { status: STATUS.STATUS_CANCELED, score: 0, @@ -87,7 +86,6 @@ function judgeCase(c, sid) { ctx.total_time_usage_ms += time_usage_ms; ctx.total_memory_usage_kb = Math.max(ctx.total_memory_usage_kb, memory_usage_kb); ctx.next({ - status: STATUS.STATUS_JUDGING, case: { status, score: 0, diff --git a/packages/hydrooj/src/handler/problem.ts b/packages/hydrooj/src/handler/problem.ts index a60f6265f..7e3103447 100644 --- a/packages/hydrooj/src/handler/problem.ts +++ b/packages/hydrooj/src/handler/problem.ts @@ -11,7 +11,6 @@ import { streamToBuffer } from '../utils'; import { Pdoc, User, Rdoc, PathComponent, } from '../interface'; -import { Logger } from '../logger'; import paginate from '../lib/paginate'; import { isTitle, isContent, isPid } from '../lib/validator'; import { ProblemAdd } from '../lib/ui'; @@ -29,7 +28,6 @@ import { export const parseCategory = (value: string) => flatten(value.split('+').map((e) => e.split(','))).map((e) => e.trim()); export const parsePid = (value: string) => (isSafeInteger(value) ? parseInt(value, 10) : value); -const logger = new Logger('problem'); export class ProblemHandler extends Handler { async __prepare() { @@ -228,7 +226,6 @@ export class ProblemDetailHandler extends ProblemHandler { async postRejudge(domainId: string, pid: number) { this.checkPerm(PERM.PERM_REJUDGE_PROBLEM); // TODO maybe async? - console.log(await record.getMulti(domainId, { pid }).count()); await record.getMulti(domainId, { pid }).forEach(async (doc) => { await record.reset(domainId, doc._id, true); await record.judge(domainId, doc._id, -1);