ly:book-scores includes other elements

Singon <[email protected]> Fri, 24 Jul 2026 20:30:25 +0200
Newsgroups gmane.comp.gnu.lilypond.bugs
Message-ID <[email protected]>
This is a multi-part message in MIME format.
--------------LEiTnujxsQ0EHgO2dKRm3bEL
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit

Dear LilyPond developers,

I am not sure if this is a bug or not, but judging by the documentation, 
the Scheme function `ly:book-scores` should only return scores. Instead, 
it includes other top-level elements like markup. In the attached 
example, I would have expected it to print only `#<Score>`, but I see 
the `(This is not a score!)` as well. Is this a desired behaviour?

Thanks in advance.

Jan "Singon" Slany

--------------LEiTnujxsQ0EHgO2dKRm3bEL
Content-Type: text/x-lilypond; charset=UTF-8; name="example.ly"
Content-Disposition: attachment; filename="example.ly"
Content-Transfer-Encoding: base64

XHZlcnNpb24gIjIuMjYiCgpccmVsYXRpdmUgYycgeyBjNCBkIGUgZiBnIH0KClxtYXJrdXAg
IlRoaXMgaXMgbm90IGEgc2NvcmUhIgoKIyhkZWZpbmUgdG9wbGV2ZWwtYm9vay1oYW5kbGVy
IChsYW1iZGEgKGJvb2spCiAgICAoZm9yLWVhY2gKICAgICAgICAobGFtYmRhIChzY29yZSkg
KGZvcm1hdCAjdCAiXG4qIH5hIiBzY29yZSkpCiAgICAgICAgKGx5OmJvb2stc2NvcmVzIGJv
b2spKSkpCg==

--------------LEiTnujxsQ0EHgO2dKRm3bEL--