Musescore 3.6.2 crashes when I open Tempochange plugin with error "..Plugin/MuseScore_TempoChanges-3.4.1/TempoChanges.qml:450: TypeError: Property 'get' of object 1 is not a function"

• Dec 1, 2022 - 09:08

Hi,
I've been using Musescore for a long time and have used the TempoChanges plugin in the past.
In my current Fedora 37 based environment everything works fine except this plugin.
If I open scores created in the past for which I have used the TempoChanges plugin, they are played regularly.
Running the application with the "-d" option and opening Tempochanges plugin, I see the error:

[nicola@schumann ~]$ mscore -d
file:///home/nicola/Documenti/MuseScore3/Plugin/MuseScore_TempoChanges-3.4.1/TempoChanges.qml:450: TypeError: Property 'get' of object 1 is not a function
file:///home/nicola/Documenti/MuseScore3/Plugin/MuseScore_TempoChanges-3.4.1/TempoChanges.qml:450: TypeError: Property 'get' of object 1 is not a function
file:///home/nicola/Documenti/MuseScore3/Plugin/MuseScore_TempoChanges-3.4.1/TempoChanges.qml:450: TypeError: Property 'get' of object 1 is not a function
Errore di segmentazione (core dump creato)
[nicola@schumann ~]$

Same error if I use Musescore from the distribution, appimage or flatpak.
Thanks for your attention.


Comments

In reply to by Jojo-Schmitz

This is the version:

[nicola@schumann ~]$ dnf info mscore
Ultima verifica della scadenza dei metadati: 0:15:38 fa il gio 1 dic 2022, 11:08:23.
Pacchetti installati
Name : mscore
Version : 3.6.2
Rilascio : 12.fc37
Architecture : x86_64
Size : 101 M
Sorgente : mscore-3.6.2-12.fc37.src.rpm
Repository : @System
Dal repo : fedora
Summary : Music Composition & Notation Software
URL : https://musescore.org/
Licenza : GPLv2 and LGPLv2+ and LGPLv3 and MIT
Description : MuseScore is a free cross platform WYSIWYG music notation program. Some
: highlights:
:
: * WYSIWYG, notes are entered on a "virtual note sheet"
: * Unlimited number of staves
: * Up to four voices per staff
: * Easy and fast note entry with mouse, keyboard or MIDI
: * Integrated sequencer and FluidSynth software synthesizer
: * Import and export of MusicXML and Standard MIDI Files (SMF)
: * Translated in 26 languages

[nicola@schumann ~]$

In plugin creator Tempochanges opens correctly but if I run it Musescore crashes with the same error:

file:///home/nicola/Documenti/MuseScore3/Plugin/MuseScore_TempoChanges-3.4.1/TempoChanges.qml:450: TypeError: Property 'get' of object 1 is not a function
Errore di segmentazione (core dump creato)

In reply to by nicola.sarti

Could you try the following:
Replace the start of the onCurrentIndexChanged handler (line 450), with the following and see what the plugin creator logs about this?

                  onCurrentIndexChanged: { // update the value fields to match the new beatBase
                  console.log("beatBaseList", beatBaseList, "beatBase.model", beatBase.model, "currentIndex", currentIndex, "previousBeatIndex", previousBeatIndex);
                        var changeFactor = beatBaseList.get(currentIndex).mult / beatBaseList.get(previousBeatIndex).mult;

I'm interested in both the log given when launching the plugin as well as what it shows if you then try and select a different note value from the dropdown (assuming it doesn't crash).

In reply to by jeetee

As far as I can tell that artifact also has this issue, but it doesn't crash

file:///C:/Users/Jojo/Documents/MuseScore3/Plug-Ins/TempoChanges/TempoChanges.qml:onCurrentIndexChanged: beatBaseList null beatBase.model 1 currentIndex 5 previousBeatIndex 5
file:///C:/Users/Jojo/Documents/MuseScore3/Plug-Ins/TempoChanges/TempoChanges.qml:unknown: file:///C:/Users/Jojo/Documents/MuseScore3/Plug-Ins/TempoChanges/TempoChanges.qml:451: TypeError: Cannot call method 'get' of null

In reply to by jeetee

I got a step further:

file:///C:/Users/Jojo/Documents/GitHub/MuseScore_TempoChanges/TempoChanges.qml:unknown: file:///C:/Users/Jojo/Documents/GitHub/MuseScore_TempoChanges/TempoChanges.qml:451: TypeError: Property 'get' of object 1 is not a function
file:///C:/Users/Jojo/Documents/GitHub/MuseScore_TempoChanges/TempoChanges.qml:onCurrentIndexChanged: beatBaseList QQmlListModel(0x7f1e3d50) beatBase.model QQmlListModel(0x7f1e3d50) currentIndex 6 previousBeatIndex 5

So fails the 1st time (initialisation?) but works the 2nd time (the actual run?)?

I've replaced all ' (single quotes) with " (double quotes)

In reply to by Jojo-Schmitz

Hi Jojo-Schmitz,
I tried both versions you posted, but without success; exact same mistake and Musescore falls.
This is the output if I run the command line:

file:///home/nicola/Documenti/MuseScore3/Support/02-TempoChanges.qml:451: TypeError: Property 'get' of object 1 is not a function
Segmentation fault (core dump created)

In reply to by Jojo-Schmitz

The code, lines 449-452:

                  onCurrentIndexChanged: { // update the value fields to match the new beatBase
                        console.log("beatBaseList:", beatBaseList, "beatBase.model:" , beatBase.model, "currentIndex:", currentIndex, "previousBeatIndex:", previousBeatIndex);
                        if (!beatBaseList || beatBase.model === 1) return;
                        var changeFactor = beatBase.model.get(currentIndex).mult / beatBase.model.get(previousBeatIndex).mult;

Do you still have an unanswered question? Please log in first to post your question.