Re: Need help with \force-hshift or \shiftO... (off, on, onn, onnn, etc.)
I think you mean \mergeDifferentlyDotted Paul From: Mats Bengtsson To: , Kevin Cole Sent: 28/03/2022 7:50 Subject: Re: Need help with \force-hshift or \shiftO... (off, on, onn, onnn, etc.) On 2022-03-28 03:54, Kevin Cole wrote: Ah. I think you're right. And, when I do what you suggested in the minimal example, it works as described: Your example looks like the image I sent. But when I inject it into the full score I get the attached, which still merges the dotted eighth with the sixteenth at the start of the measure. You don't happen to have a \mergeDifferentlyHeadedOn somewhere in your full score code, do you? /Mats
Re: Placing stanza's at repeat
Op 27-03-2022 om 22:33 schreef Carl Sorensen: Hi, Jogchum, Please use Reply All to keep the messages on the user list. Oeps, not or the first time On Sun, Mar 27, 2022 at 1:00 PM Jogchum Reitsma wrote: Op 27-03-2022 om 20:14 schreef Carl Sorensen: On Sun, Mar 27, 2022 at 10:31 AM Jogchum Reitsma wrote: Hi, Brahms' Waldesnacht has an intro stanza number one, and after that a twice repeated melody, with stanza's 2 and three. How can I achieves those stanza's to begin at the repeat? <.snip> Not too much time; you already had things set up very well to allow the changes to be made easily. It's just easier to see the structure if you have fewer notes and lyrics... So I understand the \set associatedVoice isn't usable for this construct. I'm not sure exactly why the \new Voice = "sopra_repeat" doesn't cause the lyrics to start at the beginning of the repeat. I'd guess it has to do with having the \new Voice inside an automatically generated Voice context (when you put \soprano inside the Staff, a Voice is created. And then you create a new Voice inside that automatically-created Voice, so I assume things get confused. I ran a little test to see the differences between using \set associatedVoice and \lyricsto. I can make them both work. See the attached code. But not that in both cases, I separate the notes from the contexts, and I explicitly create my contexts, which I think is good practice. HTH, Carl; This works indeed, and also when one changes the associated voice to m2, and place it in the lyrThree-part: \version "2.22.1" musI = \relative {c'4 d e f} musII = \relative {g'4 a b c} lyrI = \lyricmode {\set stanza = "1. " One one one one} lyrII = \lyricmode {\set stanza = "2. " Two two two two} lyrIII = \lyricmode {\set stanza = "3. " Three three three three} \score{ << \new Staff { \new Voice = "m1" \musI \new Voice = "m2" \musII } \new Lyrics="lyrOne" { % \set associatedVoice = "m1" { \lyrI \lyrII } } \new Lyrics ="lyrThree" { \set associatedVoice = "m2" \lyricsto "m2" { \lyrIII} } >> % end of music \layout{} } % end of score As so many times, I learned a lot again. For example, the #(skip-of-length construct was new to me. regards, Jogchum version "2.22.1" musI = \relative {c'4 d e f} musII = \relative {g'4 a b c} lyrI = \lyricmode {\set stanza = "1. " One one one one} lyrII = \lyricmode {\set stanza = "2. " Two two two two} lyrIII = \lyricmode {\set stanza = "3. " Three three three three} \score{ << \new Staff { \new Voice = "m1" \musI \new Voice = "m2" \musII } \new Lyrics="lyrOne" { \set associatedVoice = "m1" { \lyrI \lyrII } } \new Lyrics ="lyrThree" { \lyricsto "m2" { \lyrIII} } >> % end of music \layout{} } % end of score \score{ << \new Staff << \new Voice = "m1" {\musI \musII} \new NullVoice = "m2" { #(skip-of-length musI) \musII } >> \new Lyrics="lyrOne" \lyricsto "m1" { { \lyrI \lyrII } } \new Lyrics ="lyrThree" { \lyricsto "m2" {\set stanza = "3. " \lyrIII} } >> % end of music \layout{} } % end of score
Re: Running 2.23.7 on Linux
Op 28-03-2022 om 07:29 schreef Kevin Pye: (OpenSUSE Leap 15.3 to be precise) So I've downloaded 2.23.7 and untarred into ~/Software/lilypond-2.23.7, created a symbolic link from ~/Software/lilypond-2.23.7/bin/lilypond to ~/bin/lilypond, and get the following... > ~/bin/lilypond --version GNU LilyPond 2.23.7 (running Guile 2.2) Copyright (c) 1996--2022 by Han-Wen Nienhuys Jan Nieuwenhuizen and others. This program is free software. It is covered by the GNU General Public License and you are welcome to change it and/or distribute copies of it under certain conditions. Invoke as `lilypond --warranty' for more information. > ~/bin/lilypond x.ly GNU LilyPond 2.23.7 (running Guile 2.2) Uncaught exception: Throw to key misc-error with args ("primitive-load-path" "Unable to find file ~S in load path" ("ice-9/boot-9") #f)Cannot exit gracefully when init is in progress; aborting. Aborted (core dumped) (with the same result whether the file exists or not). However... > ~/Software/lilypond-2.23.7/bin/lilypond x.ly GNU LilyPond 2.23.7 (running Guile 2.2) warning: cannot find file: `x.ly' fatal error: failed files: "x.ly" So it works if run directly from the installation directory, but not via a symbolic link. Any ideas? Kevin. Hi Kevin, I would throw this question on the opensuse-support list., since it's more OS-related than lilypond specific,I would think. I don't have the expertise to tell what goes wrong here, but it could be something with relative paths, which are different in case one starts from another point in the file system. I'm on Opensuse Tumbleweed, and there the version of lilypond is kept reasonably actual. regards, Jogchum
Re: Need help with \force-hshift or \shiftO... (off, on, onn, onnn, etc.)
On Mon, Mar 28, 2022 at 4:42 AM Paul Hodges wrote: > > I think you mean \mergeDifferentlyDotted > >> From: Mats Bengtsson >> >> You don't happen to have a \mergeDifferentlyHeadedOn somewhere in your full >> score code, do you? Ah. I had both: Due to my continued inability to hold the whole of it in my head, I've been working from a Frankensteinian template that I cobbled together which, up until now, has worked for the stuff I've been transcribing. The template had both \mergeDifferentlyHeadedOn and \mergeDifferentlyDottedOn. (I don't recall which scores in the book wanted those.) Anyway, I removed both and all is looking good now. Thanks.
Re: Running 2.23.7 on Linux
On 2022-03-28 12:02, Jogchum Reitsma wrote: Op 28-03-2022 om 07:29 schreef Kevin Pye: (OpenSUSE Leap 15.3 to be precise) So I've downloaded 2.23.7 and untarred into ~/Software/lilypond-2.23.7, created a symbolic link from ~/Software/lilypond-2.23.7/bin/lilypond to ~/bin/lilypond, and get the following... > ~/bin/lilypond --version GNU LilyPond 2.23.7 (running Guile 2.2) Copyright (c) 1996--2022 by Han-Wen NienhuysJan Nieuwenhuizen and others. This program is free software. It is covered by the GNU General Public License and you are welcome to change it and/or distribute copies of it under certain conditions. Invoke as `lilypond --warranty' for more information. > ~/bin/lilypond x.ly GNU LilyPond 2.23.7 (running Guile 2.2) Uncaught exception: Throw to key misc-error with args ("primitive-load-path" "Unable to find file ~S in load path" ("ice-9/boot-9") #f)Cannot exit gracefully when init is in progress; aborting. Aborted (core dumped) (with the same result whether the file exists or not). However... > ~/Software/lilypond-2.23.7/bin/lilypond x.ly GNU LilyPond 2.23.7 (running Guile 2.2) warning: cannot find file: `x.ly' fatal error: failed files: "x.ly" So it works if run directly from the installation directory, but not via a symbolic link. Any ideas? Kevin. Hi Kevin, I would throw this question on the opensuse-support list., since it's more OS-related than lilypond specific,I would think. I don't have the expertise to tell what goes wrong here, but it could be something with relative paths, which are different in case one starts from another point in the file system. I'm on Opensuse Tumbleweed, and there the version of lilypond is kept reasonably actual. I just tried doing a similar soft link in Ubuntu and I get exactly the same error message, so it's most likely not OS related. /Mats
Re: Running 2.23.7 on Linux
On Mon, Mar 28, 2022 at 6:56 AM Mats Bengtsson wrote: > > On 2022-03-28 12:02, Jogchum Reitsma wrote: > > Op 28-03-2022 om 07:29 schreef Kevin Pye: > > (OpenSUSE Leap 15.3 to be precise) > > So I've downloaded 2.23.7 and untarred into ~/Software/lilypond-2.23.7, > created a symbolic link from ~/Software/lilypond-2.23.7/bin/lilypond to > ~/bin/lilypond, and get the following... > > > ~/bin/lilypond --version > GNU LilyPond 2.23.7 (running Guile 2.2) > > Copyright (c) 1996--2022 by > Han-Wen Nienhuys > Jan Nieuwenhuizen > and others. > > This program is free software. It is covered by the GNU General Public > License and you are welcome to change it and/or distribute copies of it > under certain conditions. Invoke as `lilypond --warranty' for more > information. > > > ~/bin/lilypond x.ly > GNU LilyPond 2.23.7 (running Guile 2.2) > Uncaught exception: > Throw to key misc-error with args ("primitive-load-path" "Unable to find > file ~S in load path" ("ice-9/boot-9") #f)Cannot exit gracefully when init > is in progress; aborting. > Aborted (core dumped) > > (with the same result whether the file exists or not). > > However... > > > ~/Software/lilypond-2.23.7/bin/lilypond x.ly > GNU LilyPond 2.23.7 (running Guile 2.2) > warning: cannot find file: `x.ly' > fatal error: failed files: "x.ly" > > So it works if run directly from the installation directory, but not via a > symbolic link. > > Any ideas? > > Kevin. > > Hi Kevin, > > I would throw this question on the opensuse-support list., since it's more > OS-related than lilypond specific,I would think. > > I don't have the expertise to tell what goes wrong here, but it could be > something with relative paths, which are different in case one starts from > another point in the file system. > > I'm on Opensuse Tumbleweed, and there the version of lilypond is kept > reasonably actual. > > I just tried doing a similar soft link in Ubuntu and I get exactly the > same error message, so it's most likely not OS related. > Just a wild guess. Do you have ~/bin/lilypond in your path? Carl
Re: Running 2.23.7 on Linux
On 2022-03-28 15:35, Carl Sorensen wrote: I just tried doing a similar soft link in Ubuntu and I get exactly the same error message, so it's most likely not OS related. Just a wild guess. Do you have ~/bin/lilypond in your path? Carl Yes, that's the soft link that I added in my previous attempt, but it doesn't matter. If I remove the link from ~/bin/, instead add a link from /tmp/lilypond and call it, I get the same error: > /tmp/lilypond GNU LilyPond 2.23.7 (running Guile 2.2) Uncaught exception: Throw to key misc-error with args ("primitive-load-path" "Unable to find file ~S in load path" ("ice-9/boot-9") #f)Cannot exit gracefully when init is in progress; aborting. Abort (core dumped) /Mats
Re: Running 2.23.7 on Linux
On Mon, Mar 28, 2022 at 6:55 AM Mats Bengtsson wrote: > > > On 2022-03-28 15:35, Carl Sorensen wrote: >> >> >> I just tried doing a similar soft link in Ubuntu and I get exactly the same >> error message, so it's most likely not OS related. > > > Just a wild guess. Do you have ~/bin/lilypond in your path? > > Carl > > Yes, that's the soft link that I added in my previous attempt, but it doesn't > matter. If I remove the link from ~/bin/, instead add a link from > /tmp/lilypond and call it, I get the same error: > > > /tmp/lilypond > GNU LilyPond 2.23.7 (running Guile 2.2) > Uncaught exception: > Throw to key misc-error with args ("primitive-load-path" "Unable to find file > ~S in load path" ("ice-9/boot-9") #f)Cannot exit gracefully when init is in > progress; aborting. > Abort (core dumped) > > /Mats I know it doesn't solve the symlink problem, but here is what my ~/bin/lilypond looks like, and it works fine: ### #!/bin/bash LY_HOME="${LY_HOME:-/home/knute/lilypond/lilypond-2.23.7/bin}" $LY_HOME/lilypond $@ ### If I want another version of LilyPond to execute, I can issue the commands: $ export LY_HOME=/home/knute/lilypond/lilypond-2.22.2/bin $ lilypond --version GNU LilyPond 2.22.2 -- Knute Snortum
Re: Running 2.23.7 on Linux
On Mon, 2022-03-28 at 16:29 +1100, Kevin Pye wrote: > (OpenSUSE Leap 15.3 to be precise) > > So I've downloaded 2.23.7 and untarred into ~/Software/lilypond- > 2.23.7, created a symbolic link from ~/Software/lilypond- > 2.23.7/bin/lilypond to ~/bin/lilypond, and get the following... > > [...] > > > ~/bin/lilypond x.ly > GNU LilyPond 2.23.7 (running Guile 2.2) > Uncaught exception: > Throw to key misc-error with args ("primitive-load-path" "Unable to > find file ~S in load path" ("ice-9/boot-9") #f)Cannot exit gracefully > when init is in progress; aborting. > Aborted (core dumped) Correct, the relocation doesn't follow symlinks, I've opened https://gitlab.com/lilypond/lilypond/-/issues/6314 For the time being, you'll need to create a wrapper shell script that just calls lilypond with its full path. Jonas signature.asc Description: This is a digitally signed message part
Re: Running 2.23.7 on Linux
Le 28/03/2022 à 21:10, Jonas Hahnfeld via LilyPond user discussion a écrit : Correct, the relocation doesn't follow symlinks, I've opened https://gitlab.com/lilypond/lilypond/-/issues/6314 For the time being, you'll need to create a wrapper shell script that just calls lilypond with its full path. Relatedly, I am seeing hardcoded paths apparently coming from your computer in the binaries. Is that expected? $ ~/lilypond2.23.7/bin/lilypond scheme-sandbox [...] scheme@(#{ g102}#)> %load-path $1 = ("/home/jean/lilypond2.23.7/share/lilypond/2.23.7/scm" "/home/jean/lilypond2.23.7/share/guile/2.2" "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile/2.2" "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile/site/2.2" "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile/site" "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile") Jean
Re: Running 2.23.7 on Linux
On Mon, 2022-03-28 at 21:14 +0200, Jean Abou Samra wrote: > Le 28/03/2022 à 21:10, Jonas Hahnfeld via LilyPond user discussion a écrit : > > Correct, the relocation doesn't follow symlinks, I've opened > > https://gitlab.com/lilypond/lilypond/-/issues/6314 For the time being, > > you'll need to create a wrapper shell script that just calls lilypond > > with its full path. > > Relatedly, I am seeing hardcoded paths apparently coming from > your computer in the binaries. Is that expected? > > $ ~/lilypond2.23.7/bin/lilypond scheme-sandbox > [...] > scheme@(#{ g102}#)> %load-path > $1 = ("/home/jean/lilypond2.23.7/share/lilypond/2.23.7/scm" > "/home/jean/lilypond2.23.7/share/guile/2.2" > "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile/2.2" > > "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile/site/2.2" > > "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile/site" > > "/home/lily/lilypond-2.23.7/release/binaries/dependencies/install/guile-2.2.7/share/guile") Yes, it's the place where I build the binaries in my VM. I think you can partly see the same with the GUB binaries. Not for %load-path though, where it actually includes /usr/share/guile/1.8 from the system, which is arguably worse - including a non-existing path at least doesn't do any harm. At some point, I'll maybe go through all dependencies and teach them that they should forget about the place where they were built / installed. Jonas signature.asc Description: This is a digitally signed message part
Re: LilyPond 2.23.7 released
On Sat, Mar 26 2022 at 22:36:05 +0100, Jonas Hahnfeld via Discussions on LilyPond development wrote: Starting with this release, LilyPond requires Guile 2.2 Can anybody remind me how to build guile2 alongside guile1.8? And which precautions should I take? I use to build the latest lilypond dev version alongside the stable version in Frescobaldi flatpak package. Until 2.24 is released, I must build both versions of guile.
Re: Running 2.23.7 on Linux
On Mon 28 Mar 2022 at 21:10:03 (+0200), Lilypond-User wrote: > Correct, the relocation doesn't follow symlinks, I've opened > https://gitlab.com/lilypond/lilypond/-/issues/6314 For the time being, > you'll need to create a wrapper shell script that just calls lilypond > with its full path. … or even an alias. (Debian.) Cheers, David.
Feature request: Fix cascading error messages
I have a request concerning Lilypond that has bothered me for a while, but which I haven't seen any one else complain about. It is the cascade of error messages you get when you leave out a right-brace or some other symbol. Maybe this could be added as an option to lilypond? lilypond --cascade-level=N file.ly which, for any given line, prints the first N error messages, and after that a message saying that further error messages have been suppressed. A default value for N might be 3 or 4. What does everyone think? --- Christopher Heckman
Re: Feature request: Fix cascading error messages
+1 From: lilypond-user on behalf of Christopher Heckman Date: Monday, March 28, 2022 at 7:11 PM To: lilypond-user@gnu.org Subject: Feature request: Fix cascading error messages I have a request concerning Lilypond that has bothered me for a while, but which I haven't seen any one else complain about. It is the cascade of error messages you get when you leave out a right-brace or some other symbol. Maybe this could be added as an option to lilypond? lilypond --cascade-level=N file.ly which, for any given line, prints the first N error messages, and after that a message saying that further error messages have been suppressed. A default value for N might be 3 or 4. What does everyone think? --- Christopher Heckman
Re: Feature request: Fix cascading error messages
Christopher Heckman writes: > I have a request concerning Lilypond that has bothered me for a while, > but which I haven't seen any one else complain about. It is the > cascade of error messages you get when you leave out a right-brace or > some other symbol. > > Maybe this could be added as an option to lilypond? > > lilypond --cascade-level=N file.ly > > which, for any given line, prints the first N error messages, and > after that a message saying that further error messages have been > suppressed. A default value for N might be 3 or 4. > > What does everyone think? The problems from followup errors do not magically disappear because they are not reported. The only thing that would make sense is better error recovery (which is pretty hard but can partly be achieved by inserting "error" productions matching typical error scenarios into the grammar: that causes a more targeted recovery and is arguably underutilised in LilyPond's grammar) but not pretending to be fine. The problem with the followup errors is that there is no way that LilyPond can actually be sure that they are followup errors. Good heuristics for error recovery productions in the grammar are tricky to do, and since they are only relevant for erroneous input, they tend not to be assigned a high priority. On the other hand, I found excellent error recovery to be of high importance when the normal workflow was sucking a stack of punch cards through the reader and then checking your output shelf hours later for a stack of line printer paper with the results of your compilation (and hopefully execution, possibly accompanied by a post mortem dump listing the COMPASS assembly instructions running into problems). I rarely find myself working an error log off sequentially these days rather than just restarting compilation after fixing a limited set of problems. -- David Kastrup
Re: Feature request: Fix cascading error messages
On Mon, Mar 28, 2022 at 4:58 PM David Kastrup wrote: > > Christopher Heckman writes: > > > I have a request concerning Lilypond that has bothered me for a while, > > but which I haven't seen any one else complain about. It is the > > cascade of error messages you get when you leave out a right-brace or > > some other symbol. > > > > Maybe this could be added as an option to lilypond? > > > > lilypond --cascade-level=N file.ly > > > > which, for any given line, prints the first N error messages, and > > after that a message saying that further error messages have been > > suppressed. A default value for N might be 3 or 4. > > > > What does everyone think? > > The problems from followup errors do not magically disappear because > they are not reported. The only thing that would make sense is better > error recovery (which is pretty hard but can partly be achieved by > inserting "error" productions matching typical error scenarios into the > grammar: that causes a more targeted recovery and is arguably > underutilised in LilyPond's grammar) but not pretending to be fine. > I'm not saying that LilyPond should say that everything is fine, just that it not report every single error for a line. If you have 8 or 9 errors on one line, there's something wrong a basic level. For instance, suppose I misspell markuplist on line 94. The next few errors look like SyntacticStructuresInMusic.ly:94:1: error: unknown escaped string: `\markuplst' \markuplst { SyntacticStructuresInMusic.ly:94:12: error: syntax error, unexpected '{', expecting '.' or '=' \markuplst { SyntacticStructuresInMusic.ly:100:1: error: unknown escaped string: `\new-chapter' \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:1: error: string outside of text script or \lyricmode \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:16: error: not a note name: Chapter \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:27: error: not a note name: The \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:31: error: not a note name: Basic \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:37: error: not a note name: Syntactic \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:47: error: not a note name: Structure \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:102:1: error: unknown escaped string: `\flushpar' \flushpar { SyntacticStructuresInMusic.ly:102:1: error: string outside of text script or \lyricmode --- (If you're upset that this is looks illegible in an email, then you understand my point; it doesn't look much nicer in a Terminal set to 108 characters wide.) What I'm saying is that the errors for line 100 should look like the following instead (when N = 4) --- SyntacticStructuresInMusic.ly:100:1: error: unknown escaped string: `\new-chapter' \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:1: error: string outside of text script or \lyricmode \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:16: error: not a note name: Chapter \new-chapter { Chapter 1. The Basic Syntactic Structure } SyntacticStructuresInMusic.ly:100:27: error: not a note name: The \new-chapter { Chapter 1. The Basic Syntactic Structure } Warning: Lilypond has possibly suppressed further error messages for line 100. SyntacticStructuresInMusic.ly:102:1: error: unknown escaped string: `\flushpar' \flushpar { --- and so on. > The problem with the followup errors is that there is no way that > LilyPond can actually be sure that they are followup errors. > True, but if you have a cascade of errors on a particular line, you definitely need to fix what's causing the cascade. Once you've done this, and you re-run Lilypond, it will now report only the errors that aren't followups. --- Christopher Heckman > Good heuristics for error recovery productions in the grammar are tricky > to do, and since they are only relevant for erroneous input, they tend > not to be assigned a high priority. > > On the other hand, I found excellent error recovery to be of high > importance when the normal workflow was sucking a stack of punch cards > through the reader and then checking your output shelf hours later for a > stack of line printer paper with the results of your compilation (and > hopefully execution, possibly accompanied by a post mortem dump listing > the COMPASS assembly instructions running into problems). > > I rarely find myself working an error log off sequentially these days > rather than just restarting compila
Re: Feature request: Fix cascading error messages
+1. I think making it customizable (with a --cascade-level parameter) wouldn't add much value considering developing effort, though. Lilypond, like Python f. ex., should simply report the first error (and ideally immediately abort compilation). —Martín. www.martinrinconbotero.com > > On Mar 29, 2022 at 2:36 AM, (mailto:christopher.heck...@asu.edu)> wrote: > > > > On Mon, Mar 28, 2022 at 4:58 PM David Kastrupwrote: > > > Christopher Heckmanwrites: > > > I > have a request concerning Lilypond that has bothered me for a while, > > > but which I haven't seen any one else complain about. It is the > > > cascade of error messages you get when you leave out a right-brace or > > > some other symbol. > > > > Maybe this could be added as an option to > lilypond? > > > > lilypond --cascade-level=N file.ly > > > > > which, for any given line, prints the first N error messages, and > > > after that a message saying that further error messages have been > > > suppressed. A default value for N might be 3 or 4. > > > > What does > everyone think? > > The problems from followup errors do not magically > disappear because > they are not reported. The only thing that would make > sense is better > error recovery (which is pretty hard but can partly be > achieved by > inserting "error" productions matching typical error > scenarios into the > grammar: that causes a more targeted recovery and is > arguably > underutilised in LilyPond's grammar) but not pretending to be > fine. > I'm not saying that LilyPond should say that everything is fine, > just that it not report every single error for a line. If you have 8 or 9 > errors on one line, there's something wrong a basic level. For instance, > suppose I misspell markuplist on line 94. The next few errors look like > SyntacticStructuresInMusic.ly:94:1: error: unknown escaped string: > `\markuplst' \markuplst { SyntacticStructuresInMusic.ly:94:12: error: syntax > error, unexpected '{', expecting '.' or '=' \markuplst { > SyntacticStructuresInMusic.ly:100:1: error: unknown escaped string: > `\new-chapter' \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:1: error: string outside of text script or > \lyricmode \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:16: error: not a note name: Chapter > \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:27: error: not a note name: The > \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:31: error: not a note name: Basic > \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:37: error: not a note name: Syntactic > \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:47: error: not a note name: Structure > \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:102:1: error: unknown escaped string: > `\flushpar' \flushpar { SyntacticStructuresInMusic.ly:102:1: error: string > outside of text script or \lyricmode --- (If you're upset that this is looks > illegible in an email, then you understand my point; it doesn't look much > nicer in a Terminal set to 108 characters wide.) What I'm saying is that the > errors for line 100 should look like the following instead (when N = 4) --- > SyntacticStructuresInMusic.ly:100:1: error: unknown escaped string: > `\new-chapter' \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:1: error: string outside of text script or > \lyricmode \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:16: error: not a note name: Chapter > \new-chapter { Chapter 1. The Basic Syntactic Structure } > SyntacticStructuresInMusic.ly:100:27: error: not a note name: The > \new-chapter { Chapter 1. The Basic Syntactic Structure } Warning: Lilypond > has possibly suppressed further error messages for line 100. > SyntacticStructuresInMusic.ly:102:1: error: unknown escaped string: > `\flushpar' \flushpar { --- and so on. > The problem with the followup > errors is that there is no way that > LilyPond can actually be sure that > they are followup errors. > True, but if you have a cascade of errors on a > particular line, you definitely need to fix what's causing the cascade. Once > you've done this, and you re-run Lilypond, it will now report only the errors > that aren't followups. --- Christopher Heckman > Good heuristics for error > recovery productions in the grammar are tricky > to do, and since they are > only relevant for erroneous input, they tend > not to be assigned a high > priority. > > On the other hand, I found excellent erro
Re: Feature request: Fix cascading error messages
Le 29/03/2022 à 08:46, Martín Rincón Botero a écrit : +1. I think making it customizable (with a --cascade-level parameter) wouldn't add much value considering developing effort, though. Lilypond, like Python f. ex., should simply report the first error (and ideally immediately abort compilation). I strongly disagree :-) When there is an error, the default should be to continue as long as possible. For large projects where the compilation takes time, you want to have some viewable output even if there is a glitch somewhere. I also think you are overestimating the "developing effort" -- such an option would be absolutely trivial to add. I am not sure it is worth it though. As David said, hiding errors is always a heuristic process. I think this would be better addressed by a convenient "jump to first error" button in Frescobaldi. Jean