Sometimes when I open a legacy blend file (below 0.3x), in rare cases, pressing Space to bring up the convenient search menu for adding meshes, etc will conveniently crash UPBGE 0.35.
I think this might be a bug. Adding objects manually via the header interface and clicking on Add Mesh does not cause a crash, but I think this is a bug that occurs with older files, etc. I’m not entirely sure where the root cause lies within UPBGE. All it gives in the console is just a segmentation fault.
I have found a fix, which involves appending the object into a blank file, deleting the reference pointer to the borked file, and then saving over it.
This happens to mostly legacy blend files and when you import certain object types, although the latter is rare. I don’t really like sharing blend files. As this is an UPBGE/Blender bug that seems to have occured in 0.35, it needs to be fixed. I just want to get the UPBGE and Blender dev teams aware of this issue.
UPBGE versions below 0.35 didn’t do this, so I think this is a bug.
Steps to reproduce:
Open any old legacy Blender/UPBGE file (like from 2.79) in 0.35, or try importing certain model types.
Then push Space to try and bring up the search menu. There is a chance that UPBGE will immediately (on OS X) exit due to a crash, or on PC it will be slightly different, as it will say that it has “stopped working”, but since I am on a mac, it immediately exits.
If crash logs are enabled on macOS, you will get a crash dialog. This can be helpful when diagnosing what happened when UPBGE crashed.
So, what is happening?
It seems to me that UPBGE is trying to execute a line of code or something that is responsible for bringing up the menu. In the case of when this fails, instead of raising an error or warning, the entire app will crash due to some kind of conflicting error or “fault”, with another issue. In the case of imported objects and their formats, it seems to be the data, but even after deletion and saving the file, the crash still remains when you press space, indicating a more severe problem at play here. In the case of legacy blend files, this seems to be more of a problem with how old versions of UPBGE and Blender structured the file data or something, leading to the chance of crashing the app when opening the spacebar menu.
This doesn’t explain why it’s only this menu that crashes - all the other ones work fine. This is a mystery to me.