Remove legacy integrator (#4786)

This commit is contained in:
Roy Nieterau 2023-04-11 10:23:58 +02:00 committed by Jakub Trllo
parent c10781a662
commit 1597306f45
4 changed files with 0 additions and 1372 deletions

View file

@ -148,14 +148,8 @@ class IntegrateAsset(pyblish.api.InstancePlugin):
"project", "asset", "task", "subset", "version", "representation",
"family", "hierarchy", "username", "user", "output"
]
skip_host_families = []
def process(self, instance):
if self._temp_skip_instance_by_settings(instance):
return
# Mark instance as processed for legacy integrator
instance.data["processedWithNewIntegrator"] = True
# Instance should be integrated on a farm
if instance.data.get("farm"):
@ -201,39 +195,6 @@ class IntegrateAsset(pyblish.api.InstancePlugin):
# the try, except.
file_transactions.finalize()
def _temp_skip_instance_by_settings(self, instance):
"""Decide if instance will be processed with new or legacy integrator.
This is temporary solution until we test all usecases with new (this)
integrator plugin.
"""
host_name = instance.context.data["hostName"]
instance_family = instance.data["family"]
instance_families = set(instance.data.get("families") or [])
skip = False
for item in self.skip_host_families:
if host_name not in item["host"]:
continue
families = set(item["families"])
if instance_family in families:
skip = True
break
for family in instance_families:
if family in families:
skip = True
break
if skip:
break
if skip:
self.log.debug("Instance is marked to be skipped by settings.")
return skip
def filter_representations(self, instance):
# Prepare repsentations that should be integrated
repres = instance.data.get("representations")

File diff suppressed because it is too large Load diff

View file

@ -365,9 +365,6 @@
}
]
},
"IntegrateAsset": {
"skip_host_families": []
},
"IntegrateHeroVersion": {
"enabled": true,
"optional": true,

View file

@ -993,37 +993,6 @@
}
]
},
{
"type": "dict",
"collapsible": true,
"key": "IntegrateAsset",
"label": "Integrate Asset",
"is_group": true,
"children": [
{
"type": "list",
"key": "skip_host_families",
"label": "Skip hosts and families",
"use_label_wrap": true,
"object_type": {
"type": "dict",
"children": [
{
"type": "hosts-enum",
"key": "host",
"label": "Host"
},
{
"type": "list",
"key": "families",
"label": "Families",
"object_type": "text"
}
]
}
}
]
},
{
"type": "dict",
"collapsible": true,