Skip to content
Snippets Groups Projects
Commit b1f92530 authored by AndiMajore's avatar AndiMajore
Browse files

fixed dataset loading

Former-commit-id: af723743
parent 7922e806
No related branches found
No related tags found
No related merge requests found
...@@ -234,14 +234,12 @@ def create_network(request) -> Response: ...@@ -234,14 +234,12 @@ def create_network(request) -> Response:
def latest_datasets(ds): def latest_datasets(ds):
dataset_dict = {} dataset_dict = {}
for d in ds: for d in ds:
print(d)
name = d.name+"_"+str(d.licenced) name = d.name+"_"+str(d.licenced)
if name not in dataset_dict: if name not in dataset_dict:
dataset_dict[name] = d dataset_dict[name] = d
continue continue
if dataset_dict[name].version < d.version: if dataset_dict[name].version < d.version:
dataset_dict[name] = d dataset_dict[name] = d
print(dataset_dict)
return dataset_dict.values() return dataset_dict.values()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment