diff --git a/InvenTree/plugin/plugin.py b/InvenTree/plugin/plugin.py index 38d4982f6e..b59b42bc3b 100644 --- a/InvenTree/plugin/plugin.py +++ b/InvenTree/plugin/plugin.py @@ -275,7 +275,11 @@ class InvenTreePlugin(MixinBase, MetaBase): """Path to the plugin.""" if self._is_package: return self.__module__ # pragma: no cover - return pathlib.Path(self.def_path).relative_to(settings.BASE_DIR) + + try: + return pathlib.Path(self.def_path).relative_to(settings.BASE_DIR) + except ValueError: + return pathlib.Path(self.def_path) @property def settings_url(self):