commit/galaxy-central: Dave Bouvier: Handle cases where installed_repostory_dict has a converter_path or display_path set to None.
1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/8ae8e19ea076/ Changeset: 8ae8e19ea076 User: Dave Bouvier Date: 2013-11-25 18:36:34 Summary: Handle cases where installed_repostory_dict has a converter_path or display_path set to None. Affected #: 2 files diff -r 6997fa059319b288877cf0728ac20fbb57e80dee -r 8ae8e19ea0762af833558f75b84fe19840c6e783 lib/galaxy/webapps/galaxy/controllers/admin_toolshed.py --- a/lib/galaxy/webapps/galaxy/controllers/admin_toolshed.py +++ b/lib/galaxy/webapps/galaxy/controllers/admin_toolshed.py @@ -231,10 +231,13 @@ if tool_shed_repository.includes_datatypes: # Deactivate proprietary datatypes. installed_repository_dict = datatype_util.load_installed_datatypes( trans.app, tool_shed_repository, repository_install_dir, deactivate=True ) - if installed_repository_dict and 'converter_path' in installed_repository_dict: - datatype_util.load_installed_datatype_converters( trans.app, installed_repository_dict, deactivate=True ) - if installed_repository_dict and 'display_path' in installed_repository_dict: - datatype_util.load_installed_display_applications( trans.app, installed_repository_dict, deactivate=True ) + if installed_repository_dict: + converter_path = installed_repository_dict.get( 'converter_path' ) + if converter_path is not None: + datatype_util.load_installed_datatype_converters( trans.app, installed_repository_dict, deactivate=True ) + display_path = installed_repository_dict.get( 'display_path' ) + if display_path is not None: + datatype_util.load_installed_display_applications( trans.app, installed_repository_dict, deactivate=True ) if remove_from_disk_checked: try: # Remove the repository from disk. diff -r 6997fa059319b288877cf0728ac20fbb57e80dee -r 8ae8e19ea0762af833558f75b84fe19840c6e783 lib/tool_shed/util/common_install_util.py --- a/lib/tool_shed/util/common_install_util.py +++ b/lib/tool_shed/util/common_install_util.py @@ -61,10 +61,13 @@ repository_install_dir = os.path.abspath( relative_install_dir ) # Activate proprietary datatypes. installed_repository_dict = datatype_util.load_installed_datatypes( trans.app, repository, repository_install_dir, deactivate=False ) - if installed_repository_dict and 'converter_path' in installed_repository_dict: - datatype_util.load_installed_datatype_converters( trans.app, installed_repository_dict, deactivate=False ) - if installed_repository_dict and 'display_path' in installed_repository_dict: - datatype_util.load_installed_display_applications( trans.app, installed_repository_dict, deactivate=False ) + if installed_repository_dict: + converter_path = installed_repository_dict.get( 'converter_path' ) + if converter_path is not None: + datatype_util.load_installed_datatype_converters( trans.app, installed_repository_dict, deactivate=False ) + display_path = installed_repository_dict.get( 'display_path' ) + if display_path is not None: + datatype_util.load_installed_display_applications( trans.app, installed_repository_dict, deactivate=False ) def get_dependencies_for_repository( trans, tool_shed_url, repo_info_dict, includes_tool_dependencies ): """ Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
participants (1)
-
commits-noreply@bitbucket.org