Page MenuHome

Crash when loading .blend file saved after using Grease Pencil ellipse tool
Closed, ResolvedPublic

Description

System Information
Operating system: Ubuntu 18.04
Graphics card: GeForce MX150

Blender Version
Broken: Blender 2.8, commit 9a63fa21eb4

While editing a 2D animation with grease pencil, I switched to the ellipse tool in draw mode. I then drew an ellipse and tried to switch back to the pencil tool. This didn't work and the interface was unresponsive. When I tried to close Blender it offered to save the file, which I did. When I try to open the file now, blender crashes immediately. It is sometimes possible to avoid the crash for a while, but it will always happen as soon as you try editing the seemingly corrupt GP object.

Load the provided .blend file, switch to draw mode for object "Stroke" and try to use any tool. Experience a crash. Also sometimes the drawing is only visible as long as you drag the timebar.


Details

Type
Bug

Event Timeline

Antonio Vazquez (antoniov) triaged this task as Needs Information from User priority.

I can see the crash opening your file, but it looks the file gets corrupted for any reason.

I cannot reproduce the first part of the error. If you try to draw an ellipse, first you need to draw the shape, and then confirm or cancel. While you are in this stage you cannot use the menus or any other interface element.

Can you reproduce the same error with other files?

@Charlie Jolly (charlie) Can you reproduce the bug (not the crash opening)?

I have done a change, and now the open file crash has gone (b85d5dd9b1a0).

We need to verify how is it possible produce the corrupted file and verify if this was a corner case.

Nice, thanks for the swift fix! I will test this as soon as I can get a build that includes the fix.
The corrupt file was produced by saving while Blender was in the state of waiting for the confirmation or cancellation of the drawing of the ellipse. I mistook this state for a hang, because I had never worked with the tool before and chose it by mistake.
So in order to reproduce, first you need to save a new file (the 2D animation preset works fine). Try to choose the ellipse tool, draw an ellipse, possibly change it a few times, then try to choose the pencil tool again (nothing happens) and then directly try to close the Blender window. The popup offering to save the file should appear and you need to confirm. It doesn't work if you have not saved the file before because the file chooser will be unresponsive in that state.\
What in my opinion should happen is that the drawing of the ellipse should be automatically confirmed when you try switching tools. That's what most other drawing programs do that allow you to draw temporarily adjustable shapes. As a user I don't like to be locked into some state and I can always undo changes I don't like.

I can confirm that the current version (69f50e6ea98) no longer crashes. I have produced a file in that newer version using the process described in my previous comment. It also results in a crash when opened in a version before the fix, so I assume that file is equally corrupted.

If you can open the file with the fix, the corruption is fixed (the read process review the error and fix it automatically). THe reason of the corruption is more related to modal operators.

Antonio Vazquez (antoniov) claimed this task.

I think we can close this report because the crash is fixed. If we need work on modal operators, we can reopen it or create a new task.