refactor: disable force apply during the reparent
This commit is contained in:
@ -44,7 +44,7 @@ from . import environment
|
|||||||
|
|
||||||
|
|
||||||
DEPENDENCIES = {
|
DEPENDENCIES = {
|
||||||
("replication", '0.0.21a15'),
|
("replication", '0.0.21a17'),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -47,7 +47,7 @@ def np_load_collection(dikt: dict, collection: bpy.types.CollectionProperty, att
|
|||||||
:type attributes: list
|
:type attributes: list
|
||||||
"""
|
"""
|
||||||
if not dikt or len(collection) == 0:
|
if not dikt or len(collection) == 0:
|
||||||
logging.warning(f'Skipping collection')
|
logging.debug(f'Skipping collection')
|
||||||
return
|
return
|
||||||
|
|
||||||
if attributes is None:
|
if attributes is None:
|
||||||
|
@ -119,14 +119,14 @@ class ApplyTimer(Timer):
|
|||||||
|
|
||||||
if node_ref.state == FETCHED:
|
if node_ref.state == FETCHED:
|
||||||
try:
|
try:
|
||||||
session.apply(node, force=True)
|
session.apply(node)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logging.error(f"Fail to apply {node_ref.uuid}: {e}")
|
logging.error(f"Fail to apply {node_ref.uuid}: {e}")
|
||||||
elif node_ref.state == REPARENT:
|
elif node_ref.state == REPARENT:
|
||||||
# Reload the node
|
# Reload the node
|
||||||
node_ref.remove_instance()
|
node_ref.remove_instance()
|
||||||
node_ref.resolve()
|
node_ref.resolve()
|
||||||
session.apply(node, force=True)
|
session.apply(node)
|
||||||
for parent in session._graph.find_parents(node):
|
for parent in session._graph.find_parents(node):
|
||||||
logging.info(f"Applying parent {parent}")
|
logging.info(f"Applying parent {parent}")
|
||||||
session.apply(parent, force=True)
|
session.apply(parent, force=True)
|
||||||
|
Reference in New Issue
Block a user