Mercurial > repos > siwaa > erecord_file
diff main_file.py @ 9:21b334392530 draft default tip
planemo upload for repository https://forgemia.inra.fr/nathalie.rousse/erecord-deploy/-/tree/main/galaxy-tools/erecord_file commit c3cff9470de2b6b133d30faefbc0521f458a30d7-dirty
author | siwaa |
---|---|
date | Thu, 15 Feb 2024 17:37:47 +0000 |
parents | b4601b7cf763 |
children |
line wrap: on
line diff
--- a/main_file.py Thu Feb 15 17:33:22 2024 +0000 +++ b/main_file.py Thu Feb 15 17:37:47 2024 +0000 @@ -40,13 +40,7 @@ import argparse import json - import erecord.api.erecord as erecord_api -from erecord.api.erecord import initt -from erecord.api.erecord import conf -from erecord.api.erecord import action -from erecord.api.erecord import error_case - from erecord.api.cmn.views_mixins import ActionViewMixin from erecord.api.cmn.utils.errors import build_error_content @@ -65,7 +59,7 @@ json_response = dict() # default configuration + maybe some modifications -config = conf() ## erecord_api.conf() # default (vle-2.0.0 version) +config = erecord_api.conf() # default (vle-2.0.0 version) config.DB_add_vpz(vpz_id=1312, vpzname="wwdm.vpz", pkgname="wwdm") try : @@ -123,10 +117,10 @@ # configuration if MAIN_DEBUG: r["config"] = config.get_as_dict() # debug - r_init = init(config) ## erecord_api.init(config) + r_init = erecord_api.init(config) if MAIN_DEBUG: r["init"] = r_init # debug - response = action(config, data) ## erecord_api.action(config, data) + response = erecord_api.action(config, data) json_response = json.loads(response) # Restitution : file (experiment.xls, conditions.xls, report.zip) @@ -158,7 +152,7 @@ except Exception as e : - response = error_case(data=data, msg=PM, e=e) ## erecord_api.error_case(data=data, msg=PM, e=e) + response = erecord_api.error_case(data=data, msg=PM, e=e) json_response = json.loads(response) r["response"] = json_response