From 79b379e267bdcf06430888b9f0b58d34e26a4317 Mon Sep 17 00:00:00 2001 From: Clemens Klug Date: Mon, 11 Jun 2018 15:51:08 +0200 Subject: [PATCH] improve NC integration --- clients/webclients.py | 8 ++++++-- selector/temp_config.py | 11 +++++++++-- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/clients/webclients.py b/clients/webclients.py index f414da1..aa4e94c 100644 --- a/clients/webclients.py +++ b/clients/webclients.py @@ -106,14 +106,18 @@ class BiogamesClient(Client): return self.download_files([i["file_url"] for i in self.list()]) class GeogamesClient(Client): - config_fields = ("host", "path") + config_fields = ("host",) def __init__(self, **kwargs): for field in self.config_fields: if not field in kwargs: raise ValueError(f"missing parameter: {field}") self.host = kwargs['host'] - self.path = kwargs['path'] + self.path = "neocartographer" + self.config = kwargs + + def login(self): + return True def list(self): logs = self.get(self.path) diff --git a/selector/temp_config.py b/selector/temp_config.py index 7875531..46de267 100644 --- a/selector/temp_config.py +++ b/selector/temp_config.py @@ -122,7 +122,7 @@ ACTIVITY = """{ ] }""" -CONFIGS = { # TODO +CONFIGS = { # TODO: more "KML": KML, "ActivityMapper": ACTIVITY, } @@ -130,4 +130,11 @@ CONFIGS = { # TODO URLS = { "KML": "/", "ActivityMapper": "#", -} \ No newline at end of file +} + +HOSTS = { + "Biogames": "http://biogames.potato.kinf.wiai.uni-bamberg.de", + "Geogames": "http://log_data/", +} + +RESULT_HOST = "http://results.ma.potato.kinf.wiai.uni-bamberg.de/" \ No newline at end of file