# HG changeset patch # User fubar_too # Date 1621849292 0 # Node ID 372903c598a8b1e231cda49d6fd44cdaab341f78 # Parent 1bdd651a784faa4cc8fad904077ab7bfb8117872 Uploaded diff -r 1bdd651a784f -r 372903c598a8 toolfactory/ToolFactory.py --- a/toolfactory/ToolFactory.py Mon May 24 02:37:52 2021 +0000 +++ b/toolfactory/ToolFactory.py Mon May 24 09:41:32 2021 +0000 @@ -866,7 +866,7 @@ a("--galaxy_venv", default="/galaxy_venv") a("--collection", action="append", default=[]) a("--include_tests", default=False, action="store_true") - a("--install", default="1") + a("--install_flag", action = "store_false", default=True) a("--admin_only", default=False, action="store_true") a("--untested_tool_out", default=None) a("--local_tools", default="tools") # relative to $__root_dir__ @@ -879,19 +879,20 @@ % (args.bad_user, args.bad_user) ) assert args.tool_name, "## Tool Factory expects a tool name - eg --tool_name=DESeq" - r = Tool_Factory(args) - r.writeShedyml() - r.makeTool() - r.makeToolTar() - if args.install: + tf = Tool_Factory(args) + tf.writeShedyml() + tf.makeTool() + tf.makeToolTar() + if args.install_flag: # always true except during toolfactory test - only works if the appliance rpyc server is running try: conn = rpyc.connect("planemo-server", port=9999, config={'sync_request_timeout':1200}) except ConnectionRefusedError: - print('### no remote rpyc server found on port 9999 - this only works in the ToolFactory Appliance with that server running...') + print('### Remote rpyc server not available - cannot install new tool %s. This only works in the ToolFactory Appliance with the server running' % args.tool_name) sys.exit(1) res = conn.root.tool_updater(galaxy_root=args.galaxy_root, - tool_conf_path=args.tool_conf_path, new_tool_archive_path=os.path.abspath(r.newtarpath), - new_tool_name=r.tool_name, local_tool_dir=args.local_tools) + tool_conf_path=args.tool_conf_path, new_tool_archive_path=os.path.abspath(tf.newtarpath), + new_tool_name=tf.tool_name, local_tool_dir=args.local_tools) + # code all moved to the server. No need for rsync other than there now. if __name__ == "__main__": main() diff -r 1bdd651a784f -r 372903c598a8 toolfactory/ToolFactory.xml --- a/toolfactory/ToolFactory.xml Mon May 24 02:37:52 2021 +0000 +++ b/toolfactory/ToolFactory.xml Mon May 24 09:41:32 2021 +0000 @@ -261,7 +261,9 @@ --collection '{"name": "$collect.name", "kind": "$collect.kind", "discover": "$collect.discover", "label": "$collect.label"}' #end for --untested_tool_out "$generated_xml" ---install "$install" +#if $install == "0": +--install_flag +#end if --galaxy_root "$__root_dir__" --tool_dir "$__tool_directory__" #end if