diff options
Diffstat (limited to 'release/scripts/modules/addon_utils.py')
-rw-r--r-- | release/scripts/modules/addon_utils.py | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/release/scripts/modules/addon_utils.py b/release/scripts/modules/addon_utils.py index a65ff15393a..8a074d23db9 100644 --- a/release/scripts/modules/addon_utils.py +++ b/release/scripts/modules/addon_utils.py @@ -172,8 +172,8 @@ def modules_refresh(module_cache=addons_fake_modules): if mod.__file__ != mod_path: print( "multiple addons with the same name:\n" - " " f"{mod.__file__!r}" "\n" - " " f"{mod_path!r}" + " %r\n" + " %r" % (mod.__file__, mod_path) ) error_duplicates.append((mod.bl_info["name"], mod.__file__, mod_path)) @@ -241,7 +241,7 @@ def check(module_name): if loaded_state is Ellipsis: print( - "Warning: addon-module " f"{module_name:s}" " found module " + "Warning: addon-module", module_name, "found module " "but without '__addon_enabled__' field, " "possible name collision from file:", repr(getattr(mod, "__file__", "<unknown>")), @@ -439,8 +439,9 @@ def disable(module_name, *, default_set=False, handle_error=None): handle_error(ex) else: print( - "addon_utils.disable: " f"{module_name:s}" " not", - ("disabled" if mod is None else "loaded") + "addon_utils.disable: %s not %s" % ( + module_name, + "disabled" if mod is None else "loaded") ) # could be in more than once, unlikely but better do this just in case. @@ -502,7 +503,7 @@ def _blender_manual_url_prefix(): else: manual_version = "dev" - return f"https://docs.blender.org/manual/en/{manual_version}" + return "https://docs.blender.org/manual/en/" + manual_version def module_bl_info(mod, info_basis=None): @@ -544,11 +545,11 @@ def module_bl_info(mod, info_basis=None): addon_info["doc_url"] = doc_url if _bpy.app.debug: print( - "Warning: add-on \"{addon_name}\": 'wiki_url' in 'bl_info' " + "Warning: add-on \"%s\": 'wiki_url' in 'bl_info' " "is deprecated please use 'doc_url' instead!\n" - " {addon_path}".format( - addon_name=addon_info['name'], - addon_path=getattr(mod, "__file__", None), + " %s" % ( + addon_info['name'], + getattr(mod, "__file__", None), ) ) |