mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 09:36:08 +08:00
vjudge: luogu: progress report
This commit is contained in:
1 parent
c8ec439b96
commit
d8bfbb0a22
3 files changed
+3
-2
No files matched your search
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@hydrooj/vjudge",
|
||||
"version": "1.4.6",
|
||||
"version": "1.4.7",
|
||||
"description": "Submit problems to remote oj",
|
||||
"main": "package.json",
|
||||
"repository": "https://github.com/hydro-dev/Hydro.git",
|
||||
|
||||
@@ -33,7 +33,7 @@ class Service {
|
||||
try {
|
||||
const rid = await this.api.submitProblem(task.target, task.lang, task.code, task, next, end);
|
||||
if (!rid) return;
|
||||
await next({ status: STATUS.STATUS_JUDGING });
|
||||
await next({ status: STATUS.STATUS_JUDGING, message: `ID = ${rid}` });
|
||||
await this.api.waitForSubmission(rid, next, end);
|
||||
} catch (e) {
|
||||
end({ status: STATUS.STATUS_SYSTEM_ERROR, message: e.message });
|
||||
|
||||
@@ -122,6 +122,7 @@ export default class LuoguProvider implements IBasicProvider {
|
||||
let fail = 0;
|
||||
let count = 0;
|
||||
let finished = 0;
|
||||
next({ progress: 5 });
|
||||
while (count < 120 && fail < 5) {
|
||||
await sleep(1500);
|
||||
count++;
|
||||
|
||||
Reference in new issue
Block a user