blender_vscode
blender_vscode copied to clipboard
Opening a blend file crashes Blender
Description
When trying to open a new Blender file, from within a running Blender instance, Blender crashes.
How to reproduce the error
- Write a new .py file with the content down below.
- Run the
Blender: Startcommand - Run the
Blender: Run Scriptcommand while having the new .py file active - Notice that Blender crashes, and the following message is printed to the console
Read blend: "<A VALID PATH TO A .BLEND FILE>"
Error : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FF611911637
Module : blender.exe
Thread : 0000a0fc
Writing: C:\Users\USER\AppData\Local\Temp\blender\debug_logs\File to load V1.crash.txt
The .py file's content (replace <A VALID PATH TO A .BLEND FILE> with your own path):
import bpy
BLEND_FILE_TO_LOAD_PATH = "<A VALID PATH TO A .BLEND FILE>"
bpy.ops.wm.open_mainfile(filepath=BLEND_FILE_TO_LOAD_PATH)
Here is the automatically generated crash log by Blender File to load V1.crash.txt
I have tested running the script in a normal Blender instance without using the VSCode addon. In that case, the opening of the file functions normally.