Skip to content

Commit

Permalink
fix: null handling for parentJob
Browse files Browse the repository at this point in the history
  • Loading branch information
harmbrugge committed Oct 10, 2024
1 parent fde8ce8 commit e24a16f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,10 @@ public GraphQLFieldDefinition.Builder createMutation(Database database, TaskServ
Schema schema = database.createSchema(name, description);
if (template != null) {
Task task = DataModels.getImportTask(schema, template, includeDemoData);
Task parentTask = taskService.getTask(parentTaskId);
task.setParentTask(parentTask);
if (parentTaskId != null) {
Task parentTask = taskService.getTask(parentTaskId);
task.setParentTask(parentTask);
}
String id = taskService.submit(task);
result.setTaskId(id);
} else {
Expand Down
2 changes: 2 additions & 0 deletions tools/pyclient/src/molgenis_emx2_pyclient/client.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import csv
import json
import logging
import sys
import pathlib
import time
from functools import cache
Expand All @@ -19,6 +20,7 @@
PermissionDeniedException, TokenSigninException, NonExistentTemplateException)
from .metadata import Schema

logging.basicConfig(stream=sys.stdout, level=logging.DEBUG)
log = logging.getLogger("Molgenis EMX2 Pyclient")


Expand Down

0 comments on commit e24a16f

Please sign in to comment.