ssb22 / jianpu-ly

Jianpu in Lilypond
http://ssb22.user.srcf.net/mwrhome/jianpu-ly.html
Apache License 2.0
74 stars 19 forks source link

barcheck fail needs clarifying for non-Lilypond users #61

Closed LS-Shandong closed 3 weeks ago

LS-Shandong commented 3 weeks ago
title=test
1=Bb
4/4
instrument=Tuba

q5 5 q1'. s3' 5' q5'. s5' 5' q4' q3' q2' q1' q2' q3' 1' q5. s5 5 q1'. s2' 3' q2' s3' s4' q5' s5' s5' q5' q5' 5' q4' q3' 2'. q5 3'. q2' q2'. s1' q1'. s7 7 q6 s7 s1' q2' q5 q5 q5 5 q1'. s2' 3' q2' s3' s4' q5' q3' q4' q2' 1' - q1'. s1' 7 6 - q1'. s1' s7' q6 q6 3' - q3' s3' s3' q3' q3' 4' q3' ( q2' ) q1'. s1' q7. ( s6 ) 7 - 1' 7 6 - q1' s1' s7 q6 q6 3' - q1' s7 q1' q2' q3' q3' q3' ( q2' ) q1'. s6 q7 q1' 6 q0 q5 5 q1'. s3' 5' q5'. s5' 5' q4' s3' s3' q2' q1' q2' q3' 1' q5 s5 s5 5 q1'. s2' 3' q2' s3' s4' q5' s5' s5' q5' q5' 5' q4' q3' 2'. q5 3'. q2' q2' s1' s1' q1' ( q7 ) 7 q6 s7 s1' q2' q5 q5 q5 5 q1'. s2' 3' q2' s3' s4' q5' q3' q4' q2' 1'.

Hello,I run jianpu-lily test.txt > test.ly,it returns Exception: (notesHad=5 5 1 3 5 5) barcheck fail: note crosses barline at "5" with 1 beams (12 skipped from 56 to 68, bypassing 64), scoreNo=1 barNo=1 (but the error could be earlier)

ssb22 commented 3 weeks ago

The error is correct because you forgot to tell the program about the anacrusis (pick-up bar). Your music is in 4/4 time (4 beats per bar) but there is a 0.5-beat anacrusis before the first bar starts. I can tell that, because I'm a human musician, but jianpu-ly doesn't know unless it's told: your time signature setting should be not just 4/4 but 4/4,8

You also have a separate mistake where you put q1' s7 q1' q2': this does not add up to a whole number of beats and I think you forgot to type a dot (.) after that q1'

ssb22 commented 3 weeks ago

So the bug here is, that error message needs to have its words changed so that more people will understand what they need to check when that happens...

LS-Shandong commented 3 weeks ago

I changed the code to look like this:

title=test
1=Bb
4/4,8
instrument=Tuba

q5 5 q1'. s3' 5' q5'. s5' 5' q4' q3' q2' q1' q2' q3'
1' q5. s5 5 q1'. s2' 3' q2' s3' s4' q5' s5' s5' q5' q5' 5' q4' q3' 2'. q5
3'. q2' q2'. s1' q1'. s7 7 q6 s7 s1' q2' q5 q5 q5 5 q1'. s2' 3' q2' s3' s4'
q5' q3' q4' q2' 1' - q1'. s1' 7 6 - q1'. s1' s7' q6 q6 3' -
q3' s3' s3' q3' q3' 4' q3' ( q2' ) q1'. s1' q7. ( s6 ) 7 - 1' 7 6 -
q1' s1' s7 q6 q6 3' - q1'. s7 q1' q2' q3' q3' q3' ( q2' ) q1'. s6 q7 q1' 6 q0 q5
5 q1'. s3' 5' q5'. s5' 5' q4' s3' s3' q2' q1' q2' q3' 1' q5 s5 s5 5 q1'. s2'
3' q2' s3' s4' q5' s5' s5' q5' q5' 5' q4' q3' 2'. q5 3'. q2' q2' s1' s1' q1' ( q7 )
7 q6 s7 s1' q2' q5 q5 q5 5 q1'. s2' 3' q2' s3' s4' q5' q3' q4' q2' 1'.

However, it still returns Exception: (notesHad=5 5 1 3 5 5 5 5 4 3 2 1 2 3 1 5 5 5 1 2 3 2 3 4 5 5 5 5 5 5 4 3 2 5 3 2 2 1 1 7 7 6 7 1 2 5 5 5 5 1 2 3 2 3 4 5 3 4 2 1 - 1 1 7 6 - 1 1 7 6 6 3 -) barcheck fail: note crosses barline at "-3" with 0 beams (16 skipped from 52 to 68, bypassing 64), scoreNo=1 barNo=12 (but the error could be earlier)

ssb22 commented 3 weeks ago

Correct: it's trying to tell you the bar q1'. s1' s7' q6 q6 3' - is wrong. (It might help you proofread your input if you use | or new-line to separate bars.) In this case I think that q1' should not have a dot, because it has two semiquavers after the quaver.

LS-Shandong commented 3 weeks ago

My problem is solved, thank you.