The error is triggered by the use of \global in the midi block when
global contains "\time 4/4". Incidentally, if the midi block contains
a \key signature, but no \time, then it works fine in 2.19.80.
I can understand that \time is irrelevant to midi (as is \key?), but
I've used this lazily in the past because it works.
It is intended to work. I am surprised that this has been overlooked
for so long.
I'd be interested to know if you think the correct fix is to restore
the original 2.18.2 behaviour, or to output an error message that
identifies the line that causes the problem.
I'm currently writing two fixes. One makes a better warning, the other
does not trigger it.