Potential fix for #3273 where renamed drawings might not get moved on Windows.

This commit is contained in:
Dion Moult
2023-07-28 15:35:02 +10:00
parent 472da333b9
commit 4b5fcdf30f
+5 -1
View File
@@ -884,7 +884,11 @@ class Drawing(blenderbim.core.tool.Drawing):
@classmethod
def move_file(cls, src, dest):
shutil.move(src, dest)
try:
shutil.move(src, dest)
except:
# Perhaps the file is locked in Windows?
shutil.copy(src, dest)
@classmethod
def generate_drawing_name(cls, target_view, location_hint):