Fix errors when setting up evals not being caught
This commit is contained in:
parent
0dfa5fddd4
commit
32e297ee07
1 changed files with 9 additions and 9 deletions
|
@ -120,6 +120,7 @@ class LanguageHandler extends AkairoHandler {
|
|||
return evalQueue.enqueue(async () => {
|
||||
const { name } = await setupQueue.enqueue(() => this.setupContainer(dockerID));
|
||||
const now = Date.now();
|
||||
try {
|
||||
await exec(`docker exec ${name} mkdir eval/${now}`);
|
||||
await exec(`docker exec ${name} chmod 777 eval/${now}`);
|
||||
const proc = childProcess.spawn('docker', [
|
||||
|
@ -129,7 +130,6 @@ class LanguageHandler extends AkairoHandler {
|
|||
]);
|
||||
|
||||
const timeout = this.getCompilerConfig(dockerID, 'timeout', 'number');
|
||||
try {
|
||||
const result = await this.handleSpawn(proc, timeout);
|
||||
await exec(`docker exec ${name} rm -rf eval/${now}`);
|
||||
return result;
|
||||
|
|
Loading…
Reference in a new issue