Re: programming error: cyclic dependency: example

Richard Shann <[email protected]>
Newsgroups gmane.comp.gnu.lilypond.devel
Message-ID <[email protected]>
On Fri, 2025-08-29 at 06:45 +0000, Werner LEMBERG wrote:
> > The score below has the Bar_number_engraver moved to Staff level:
> 
> > depending on the details of the music this causes an error:
> 
> > 
> 
> > programming error: cyclic dependency:
> 
> >    calculation-in-progress encountered for
> > VerticalAxisGroup.adjacent-pure-heights
> 
> >    continuing, cross fingers
> 
> > 
> 
> > In the real-life example that lead to this MWE the typesetting is
> 
> > ok, so I'm submitting this in the hope it may prove useful for
> 
> > developers.  [...]
> 
> 
> Actually, I'm not surprised by the error message.  Your input code
> can
> be reduced to the following, also shown in the attached image.
> 
> ```
> \version "2.24.0"
> 
> <<
>   \new Staff { \stopStaff
>                f'1 | f'1 }
>   \new Staff { R1  | R1  }
> > > 
> 
> 
> \layout {
>   \context {
>     \Score
>     \remove Bar_number_engraver
>   }
>   \context {
>     \Staff
>     \consists Bar_number_engraver
>     \override BarNumber.break-visibility = #all-visible
>   }
> }
> ```
> 
> As can be seen, there are no bar lines available in the first staff,
> which are needed for the bar number engraver to vertically position a
> bar number. 
So ideally the bar number engraver could be written to not engrave a
bar number if there is no barline?
>  Of course, the error message is cryptic, and my
> interpretation might just be an educated guess – but I believe that a
> error message is OK for this situation.
I'm hoping so, but although there is an ly:expect-warning there doesn't
appear to be an ly:expect-error ...
> 
> What do you *really* want to achieve?
A good question - I'll open a new thread to address that on lilypond-
user, it will take a little work, but I think there may be some user
issues with ossia.
Thank you for the response
Richard Shann
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.