Merge remote-tracking branch 'origin/develop' into feature/igniter-improvements

This commit is contained in:
Ondrej Samohel 2021-03-03 17:50:42 +01:00
commit 6c914eecf3
No known key found for this signature in database
GPG key ID: 8A29C663C672C2B7
3 changed files with 7 additions and 17 deletions

View file

@ -149,10 +149,12 @@ class CollectAnatomyInstanceData(pyblish.api.ContextPlugin):
"name": subset_name
})
subset_docs = list(io.find({
"type": "subset",
"$or": subset_filters
}))
subset_docs = []
if subset_filters:
subset_docs = list(io.find({
"type": "subset",
"$or": subset_filters
}))
subset_ids = [
subset_doc["_id"]

View file

@ -404,15 +404,6 @@ class ProjectWidget(SettingsCategoryWidget):
if self is saved_tab_widget:
return
system_settings = get_system_settings()
mongo_url = system_settings["modules"]["avalon"]["AVALON_MONGO"]
if not mongo_url:
mongo_url = os.environ["PYPE_MONGO"]
# If mongo url is not the same as was then refresh projects
if mongo_url != os.environ["AVALON_MONGO"]:
self.project_list_widget.refresh()
def _create_root_entity(self):
self.entity = ProjectSettings(change_state=False)
self.entity.on_change_callbacks.append(self._on_entity_change)

View file

@ -643,10 +643,7 @@ class ProjectListWidget(QtWidgets.QWidget):
items = [self.default]
system_settings = get_system_settings()
mongo_url = system_settings["modules"]["avalon"]["AVALON_MONGO"]
if not mongo_url:
mongo_url = os.environ["PYPE_MONGO"]
mongo_url = os.environ["PYPE_MONGO"]
# Force uninstall of whole avalon connection if url does not match
# to current environment and set it as environment