lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: "Programming error" bug?


From: Jean Abou Samra
Subject: Re: "Programming error" bug?
Date: Sun, 14 Nov 2021 16:13:59 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.2.1

Le 13/11/2021 à 20:41, David Sumbler a écrit :
I have just started on a new Lilypond project, having had little interaction with Lilypond for several months.  I installed v.2.23.4.

Although I have so far only set 3 lines of music on 2 staves, the message "programming error: cyclic dependency: calculation-in-progress encountered for #'adjacent-pure-heights (VerticalAxisGroup)" is issued 8 times when compiling.

From the very little I could find searching online, it seems as if it might have something to do with my having moved Mark-engraver etc. from their usual context.  It was also suggested that this is a bug.

Is there some way of suppressing these messages?  I know how to suppress warnings, but that won't work with these error messages.

The code I am using to set up the "staff" containing metronome marks etc. is:

\layout {
  \context {
    \name "MarkLine"
    \type "Engraver_group"
    \consists Output_property_engraver
    \consists Axis_group_engraver
    \consists Mark_engraver
    \consists Metronome_mark_engraver
    \consists Text_spanner_engraver
    \override RehearsalMark.extra-spacing-width = #'(0 . 1)
    \override MetronomeMark.extra-spacing-width = #'(0.5 . -inf.0)
    \override TextSpanner.Y-offset = #3.5
    \override VerticalAxisGroup.minimum-Y-extent = #'(-2 . 2)
    \override VerticalAxisGroup.staff-staff-spacing =
    #'((basic-distance . 1)
       (minimum-distance . 1)
       (padding . 1)
       (stretchability . 3))
  }
  \context {
    \Score
    \remove Mark_engraver
    \remove Metronome_mark_engraver
    \accepts MarkLine
  }
}

I can't remember where I got this code from.  Is there something that needs to be changed in it?


You also have to move the Staff_collecting engraver,
as documented at
https://lilypond.org/doc/v2.23/Documentation/internals/mark_005fengraver

Giving:

\version "2.23.4"

\layout {
  \context {
    \name "MarkLine"
    \type "Engraver_group"
    \consists Output_property_engraver
    \consists Axis_group_engraver
    \consists Mark_engraver
    \consists Metronome_mark_engraver
    \consists Text_spanner_engraver
    \consists Staff_collecting_engraver
    \override RehearsalMark.extra-spacing-width = #'(0 . 1)
    \override MetronomeMark.extra-spacing-width = #'(0.5 . -inf.0)
    \override TextSpanner.Y-offset = #3.5
    \override VerticalAxisGroup.minimum-Y-extent = #'(-2 . 2)
    \override VerticalAxisGroup.staff-staff-spacing =
    #'((basic-distance . 1)
       (minimum-distance . 1)
       (padding . 1)
       (stretchability . 3))
  }
  \context {
    \Score
    \remove Mark_engraver
    \remove Metronome_mark_engraver
    \accepts MarkLine
  }
}

<<
  \new MarkLine { \mark \default }
  { a1 }
>>


Note that the programming errors appeared because
an internal check was enabled. In other words, it
is worth fixing your code even with older versions
even if there is no warning (observe how the vertical
spacing gets different in the example above).

Best,
Jean




reply via email to

[Prev in Thread] Current Thread [Next in Thread]