Exported XMLs Contain Undesired Extra Voices With Whole Bar Rests

An XML exported from Dorico contains empty voices with whole rests (only in some bars). A concrete example is this bar in Dorico:

The exported XML contains following elements in the bar:

      <note>
        <rest measure="yes"/>
        <duration>16</duration>
        <voice>3</voice>
        <staff>1</staff>
      </note>
    <note>
        <rest measure="yes"/>
        <duration>16</duration>
        <voice>4</voice>
        <staff>2</staff>
      </note>

Other similar bars do not contain whole rests when exported.

I noticed this issue because those whole rests are shown in Newzik. What is the reason behind this behaviour?

(In case you want to fix it reasonably simply):

Does this piece require more than one voice in each staff? If not, just select everything and make it into Up-stem Voice 1.

The extra Bar Rests are most likely there because there’s no music for a voice.

Certain bars require multiple voices, so there are indeed 4 voices in the whole piece. However, there are many bars like the one above, that have notes only in two voices, and yet those other bars do not contain the extra bar rests. For some reason, those rests are added only to some bars.

You’re welcome to upload a short project as an example and someone can (hopefully) explain what’s going on.

2 Likes

Sure, here is a part of the piece:

Humoresque.dorico (1.3 MB)

Humoresque.mxl.zip (8.0 KB)

For example, bars 2 and 3 do not contain whole rests in the XML, but bar 5 does.

Below is a screenshot of the XML import. The only thing I did was remove the System Breaks and turn on Voice Colors:

I can’t see any whole rests? And I can’t see any in the whole project, apart from where the music stops and there are empty bars.

And, to be honest, I can’t see any in your original screenshot. Is it possible there is a mix-up with terminology?

NB one thing I DO notice is that the voices are all Down-stem, rather than the default Up-stem.

Dorico doesn’t seem to show the extra rests when importing MusicXML back in, but as stated in the original post, Newzik shows extra rests. For what it’s worth, so do MuseScore and Finale.

I’m not sure why Dorico’s exporting these rests.

What’s the status of the Starts Voice and Ends Voice properties of the notes on either side of the rest(s) in question?

Off. Check out the Dorico file for yourself.
They’re secondary voices so Dorico’s automatically hiding bar rests in these voices.

1 Like