MuseScore Crashes for one file
While I have made multiple backups of this score, I recently enlarged the Instruments playing it to flesh out the orchestration, and after saving it, the file would not open again. I happened to put days of effort into that one version, and would love to have it back, as 're-creating' it will mean re-composing much of it, and I am worried that after all that double-work, the crash may happen again. Anyone know how to fix or de-bug the file?
Attachment | Size |
---|---|
2. The_Ending_is_the_Hardest_Part_F.mscz | 73.75 KB |
Comments
Crash confirmed, even in latest development build, stack trace:
1 Ms::Segment::setNext segment.h 89 0xd42e07
2 Ms::SegmentList::insert segmentlist.cpp 113 0x7e08f7
3 Ms::Measure::createEndBarLines measure.cpp 3658 0x8d4f2d
4 Ms::Score::collectSystem layout.cpp 3320 0x8af78a
5 Ms::LayoutContext::collectPage layout.cpp 4198 0x8b488d
6 Ms::LayoutContext::layout layout.cpp 4508 0x8b65c9
7 Ms::Score::doLayoutRange layout.cpp 4493 0x8b64ca
8 Ms::Score::update cmd.cpp 221 0x9bcbe7
9 Ms::readScore file.cpp 2356 0x65ddfa
10 Ms::MuseScore::readScore file.cpp 349 0x64c2da
11 Ms::MuseScore::openScore file.cpp 327 0x64c1a0
12 Ms::MuseScore::loadFiles file.cpp 304 0x64be4e
13 Ms::MuseScore::cmd musescore.cpp 6098 0x508f74
14 Ms::MuseScore::cmd musescore.cpp 5906 0x50812c
15 Ms::MuseScore::qt_static_metacall moc_musescore.cpp 861 0x40b892
16 ZN11QMetaObject8activateEP7QObjectiiPPv 0x68c82545
17 ZN12QActionGroup7hoveredEP7QAction 0x27844ee5
Have you tried that last backup file, ".2. The_Ending_is_the_Hardest_Part_F.mscz,"?
See https://musescore.org/en/node/52116
I MacGyvered the code a bit and got it to read the score without crashing, saved it and now the regular version can read it without crashing too
And with this I'm calling it a day and go to bed ;-)
In reply to I MacGyvered the code a bit… by Jojo-Schmitz
You are a genius. I am so grateful to you, I can't adequately express it. THANK you.
In reply to You are a genius. I am so… by jchrismucci
The question now is whether my MacGyvered code would be something to make permanent, integrate into the next version, to prevent such a crash.
For decision on that it'd be helpful to know how that score got into this state.
In reply to You are a genius. I am so… by jchrismucci
If you'd like to see the previous versions of the file before the crash happened, I append them here. What I was doing was adding staves in order to expand the vocal lines, as well as add some new measures
In reply to I MacGyvered the code a bit… by Jojo-Schmitz
Nice work, Jojo! But as you can well imagine, this does not fix the real problem, and the fact that
el->prev()
is NULL even thoughel
is not equal tofirst()
is an indication that something is really wrong.The real problem occurs on line 2399 of measure.cpp where it is assumed that
e.tick()
is going to be equal to the last tick of the measure, and therefore, sincefermata
is not NULL, a fermata should be added over the barline. But it turns out thate.tick()
may not necessarily be equal to the last tick of the measure (in the case of deleted rests), in which case the fermata should be added to a ChordRest segment. The fix for this is easy enough.If this error is worthy of a brown paper bag, I am afraid that it would have to go to me.
In reply to Nice work, Jojo! But as you… by mattmcclinch
Yes, my fix does feel pretty MacGyverish... Are you going to PR your's
Edit: I see you created #294156: Incorrect segment type for fermata
In reply to Yes, my fix does feel pretty… by Jojo-Schmitz
Done. See https://github.com/musescore/MuseScore/pull/5310.