Layout that leads to the encounter of two frames causes a crash

• Sep 27, 2015 - 10:35
Type
Functional
Severity
S2 - Critical
Status
closed
Project

Nightly 7885daf / Windows 7

This issue is related to this thread: https://musescore.org/en/node/81356

Steps for reproduce from scratch:

- First minimal scenario

1) Load this file: test file.mscz

2) Select the last measure -> Add -> Frames -> Append Horizontal Frame

(or, more faster: select the last measure -> right-click above the blue rectangle -> Frames -> Append Horizontal frame)

3) Repeat step #2 (append an horizontal frame): so, you get two frames side by side

4) Double-click (for edition) on the frame to the right, like image below -> with the handle, go the left to cross the first frame.
1edit.jpg

Result: crash (click 1 or 2 times on the score to accelerate it)
2crash frames.jpg


Comments

A variation:

1) Load this file: piano test file.mscz

2) Select the last measure -> from the palette: Insert an Horizontal Frame

3) Select again the last measure -> Add -> Frames -> Append Vertical Frame

4) Select this measure 4 (between the two frames) -> Delete (Ctrl + Del)

5) Select the bracket, like image below -> Cut (Ctrl + X)
vertical frame.jpg

Result: crash (ditto click one or more times on the score)

---------------------

- A last variation , with the "original" fixed file (provisionally fixed)

1) So, load this file: 1Solar Wendel.mscz

2) Go to end of the score: select last measure -> from the palette: Insert Horizontal Frame

3) Delete (Ctrl + Del) this last measure

Result: crash

After checking, this issue occurs on June 27

- I could load the original file ( Solar Wendel.mscz ) or cannot reproduce from scratch, for instance with the first minimal scenario, with this Nightly on June 26: ea43dd9

From scratch ("My First Score"), I receive this, by editing and moving the second frame to the left:
26 juin.jpg

- I receive a crash by opening the original file, or can reproduce from scratch, with this one: 83ae627

From scratch, always with the first minimal scenario, the layout is "blocked" (always after editing and moving the second frame to the left), and I get a crash, as mentioned first.

- So, after seeing, this issue might be a side effect of this commit? https://github.com/musescore/MuseScore/pull/2068/files
To fix: #54221: Horizontal frame before last measure of system creates crowded layout
or, less likely of the previous one? : https://github.com/musescore/MuseScore/pull/2093/files

A new variation, interesting may be for another facet of understanding.

1) Load this file (after an Horizontal Frame appending) : Adding Vertical.mscz

2) Add -> Frames -> Append Vertical Frame

Result: crash

Note: with the Nightly of June 26, this Vertical Frame is not really added (the caracteristic dotted blue lines doesn't appear on the score), but the layout is affected, and I receive the same result and same image, but with one "single" frame (?), that on the previous message.

Status (old) active patch (ready to commit)

Brilliant work again! This analysis led me quickly and directly to the solution, which was to correct a very simple oversight in my original fix for #54221: Horizontal frame before last measure of system creates crowded layout.

The following fixes all the variations of the issue identified here, and also allows the two scores attached to the original forum post to load without problems:

https://github.com/musescore/MuseScore/pull/2236