fix: handle file not found
exception
This commit is contained in:
@ -63,6 +63,10 @@ class BlFile(ReplicatedDatablock):
|
|||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
super().__init__(*args, **kwargs)
|
super().__init__(*args, **kwargs)
|
||||||
self.instance = kwargs.get('instance', None)
|
self.instance = kwargs.get('instance', None)
|
||||||
|
|
||||||
|
if self.instance and not self.instance.exists():
|
||||||
|
raise FileNotFoundError(self.instance)
|
||||||
|
|
||||||
self.preferences = utils.get_preferences()
|
self.preferences = utils.get_preferences()
|
||||||
self.diff_method = DIFF_BINARY
|
self.diff_method = DIFF_BINARY
|
||||||
|
|
||||||
|
@ -140,10 +140,10 @@ class SessionStartOperator(bpy.types.Operator):
|
|||||||
runtime_settings.is_host = True
|
runtime_settings.is_host = True
|
||||||
runtime_settings.internet_ip = environment.get_ip()
|
runtime_settings.internet_ip = environment.get_ip()
|
||||||
|
|
||||||
|
try:
|
||||||
for scene in bpy.data.scenes:
|
for scene in bpy.data.scenes:
|
||||||
client.add(scene)
|
client.add(scene)
|
||||||
|
|
||||||
try:
|
|
||||||
client.host(
|
client.host(
|
||||||
id=settings.username,
|
id=settings.username,
|
||||||
port=settings.port,
|
port=settings.port,
|
||||||
|
Reference in New Issue
Block a user