diff data_manager/data_manager_eggnog.py @ 4:fcb8bdd124f4 draft

"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/eggnog_mapper/data_manager_eggnog_mapper_abspath commit e45c15081260025e470d23975ef5a734d3f8fc66"
author galaxyp
date Tue, 25 Jan 2022 13:51:24 +0000
parents b711f5b6bd44
children
line wrap: on
line diff
--- a/data_manager/data_manager_eggnog.py	Fri Feb 19 18:54:00 2021 +0000
+++ b/data_manager/data_manager_eggnog.py	Tue Jan 25 13:51:24 2022 +0000
@@ -42,13 +42,21 @@
     data_table = 'eggnog_mapper_db_versioned'
     dm_dict['data_tables'][data_table]\
         = dm_dict['data_tables'].get(data_table, [])
-    # Versionning is super confusing:
+    # DB versionning was super confusing for eggnog-mapper 2.0.x:
     # eggnog-mapper 1.* needed a db v4.5 (based on eggnog v4.5)
-    # eggnog-mapper 2.0 needs a db v2.0 (based on eggnog v5.0)
-    # db v4.5 are not compatible with eggnog-mapper 2.0
+    # eggnog-mapper 2.x needed a db v2.0 (based on eggnog v5.0)
+    # (db v4.5 are not compatible with eggnog-mapper 2.0)
+    # Starting with eggnog-mapper 2.1.* db versioning looks better: 2.1.0 requires db v5.0.2
     version = "2.0"
     if "4.5" in db_version:
+        # special case: eggnog-mapper 1.x
         version = "1.0"
+    elif db_version.startswith('2.'):
+        # special case: eggnog-mapper 2.0.x
+        version = "2.0"
+    else:
+        # normal case or eggno-mapper >= 2.1
+        version = db_version
     data_table_entry = dict(value=db_version, name=db_version,
                             path=args.install_path, version=version)
     dm_dict['data_tables'][data_table].append(data_table_entry)