lilypond-user
[Top][All Lists]
Advanced

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

Re: Guile REPL Server


From: Jonas Hahnfeld
Subject: Re: Guile REPL Server
Date: Thu, 19 May 2022 09:28:54 +0200
User-agent: Evolution 3.44.1

Hi,

coming back to the start of this thread:

On Mon, 2022-05-16 at 18:29 -0400, Hendursaga wrote:
> Hello LilyPond users!
> 
> I'm trying to start a REPL server[1] inside LilyPond's Guile interpreter, but 
> I can't get it to even load readline support. Note that I am running the 
> precompiled Linux unstable release binary, because I want to be able to use 
> Guile 2.
> 
> ```
> $ lilypond scheme-sandbox
> GNU LilyPond 2.23.8 (running Guile 2.2)
> Processing `/usr/local/share/lilypond/2.23.8/ly/scheme-sandbox.ly'
> Parsing...
> /usr/local/share/lilypond/2.23.8/ly/scheme-sandbox.ly:21:2: error: GUILE 
> signaled an error for the expression beginning here
> #
>  (load-user-init)
> no code for module (ice-9 readline)

Note that this is not coming directly from LilyPond, scheme-sandbox
doesn't need (ice-9 readline). From the call of (load-user-init), do
you maybe load that module as part of your ~/.guile ?


> GNU Guile 2.2.7
> Copyright (C) 1995-2019 Free Software Foundation, Inc.
> 
> Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
> This program is free software, and you are welcome to redistribute it
> under certain conditions; type `,show c' for details.
> 
> Enter `,help' for help.
> scheme@(#{ g102}#)> (use-modules (system repl server))
> scheme@(#{ g102}#)> (run-server)
> system/repl/server.scm:75:36: In procedure make-tcp-server-socket:
> In procedure module-lookup: Unbound variable: INADDR_LOOPBACK
> 
> Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.
> scheme@(#{ g102}#) [1]> ,q
> scheme@(#{ g102}#)> ,q
> Success: compilation successfully completed
> ```

As you can see, the REPL itself works just fine. What does not work is
the REPL server because we disable all networking functionality in our
Guile build. Here I'm even more hesitant to change direction because
everything interfacing with network is security-sensitive...


> Nor can the Guile debugger script run, either..

As Jean has pointed out, the debugger support is broken with Guile 2.2
for other reasons, so that would need to be fixed first. Whether we
need readline support afterwards for it to work, I don't know - given
that the REPL works (see above), it may not be needed at all.

Jonas

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

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