SyncServer: Existence of module is optional (#5413)

* 'get_repre_icons' have optional sync server

* local settings have optional sync server

* sync server is optional in sceneinventory

* sync server is optional in loader tool

* sync server is optional in library loader

* sync server is optional in host dirmap

* sync server is optional in nuke cache

* sync server is optional in integrate plugin

* added "sync_server" back to ignored modules for openpype package

* fix missing variable

* mark syncserver command as deprecated

* define 'SYNC_SERVER_ROOT'

* added method to receive icon paths

* use sync server module to receive icons

* fix scene inventory
This commit is contained in:
Jakub Trllo 2023-08-07 18:48:27 +02:00 committed by GitHub
parent ae3eb37776
commit a31b2d9d77
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 142 additions and 117 deletions

View file

@ -2955,6 +2955,7 @@ class DirmapCache:
"""Caching class to get settings and sync_module easily and only once."""
_project_name = None
_project_settings = None
_sync_module_discovered = False
_sync_module = None
_mapping = None
@ -2972,8 +2973,10 @@ class DirmapCache:
@classmethod
def sync_module(cls):
if cls._sync_module is None:
cls._sync_module = ModulesManager().modules_by_name["sync_server"]
if not cls._sync_module_discovered:
cls._sync_module_discovered = True
cls._sync_module = ModulesManager().modules_by_name.get(
"sync_server")
return cls._sync_module
@classmethod