feat(replication): handle error outside the data protocol
refactor(replication): remove background worker
This commit is contained in:
parent
320745aab3
commit
8f4de7adbf
@ -44,7 +44,7 @@ from . import environment
|
|||||||
|
|
||||||
|
|
||||||
DEPENDENCIES = {
|
DEPENDENCIES = {
|
||||||
("replication", '0.1.9'),
|
("replication", '0.1.10'),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -576,9 +576,13 @@ class SessionApply(bpy.types.Operator):
|
|||||||
|
|
||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
logging.debug(f"Running apply on {self.target}")
|
logging.debug(f"Running apply on {self.target}")
|
||||||
session.apply(self.target,
|
try:
|
||||||
force=True,
|
session.apply(self.target,
|
||||||
force_dependencies=self.reset_dependencies)
|
force=True,
|
||||||
|
force_dependencies=self.reset_dependencies)
|
||||||
|
except Exception as e:
|
||||||
|
self.report({'ERROR'}, repr(e))
|
||||||
|
return {"CANCELED"}
|
||||||
|
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
@ -596,11 +600,13 @@ class SessionCommit(bpy.types.Operator):
|
|||||||
return True
|
return True
|
||||||
|
|
||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
# session.get(uuid=target).diff()
|
try:
|
||||||
session.commit(uuid=self.target)
|
session.commit(uuid=self.target)
|
||||||
session.push(self.target)
|
session.push(self.target)
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
except Exception as e:
|
||||||
|
self.report({'ERROR'}, repr(e))
|
||||||
|
return {"CANCELED"}
|
||||||
|
|
||||||
class ApplyArmatureOperator(bpy.types.Operator):
|
class ApplyArmatureOperator(bpy.types.Operator):
|
||||||
"""Operator which runs its self from a timer"""
|
"""Operator which runs its self from a timer"""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user