GNU bug report logs - #69686
Geiser is slow when running with geiser-guile-load-init-file set to t

Previous Next

Package: guix;

Reported by: Tomas Volf <~@wolfsden.cz>

Date: Sun, 10 Mar 2024 01:14:02 UTC

Severity: normal

To reply to this bug, email your comments to 69686 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#69686; Package guix. (Sun, 10 Mar 2024 01:14:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Tomas Volf <~@wolfsden.cz>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sun, 10 Mar 2024 01:14:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Tomas Volf <~@wolfsden.cz>
To: bug-guix <at> gnu.org
Subject: Geiser is slow when running with geiser-guile-load-init-file set to t
Date: Sun, 10 Mar 2024 02:13:04 +0100
[Message part 1 (text/plain, inline)]
Hello,

I discovered that when I run Geiser with geiser-guile-load-init-file set to t,
it results in horrible experience, when the REPL seems to technically work, but
anything takes a long time (completion is on order of seconds).

I found out that it is caused by the readline activation.  I am unsure how to
solve this properly.  For me the workaround was to move the readline check
inside the (unless (getenv "INSIDE_EMACS") ...), since I do not need it there.
I was contemplating sending a patch doing just so, but I realized that also
disables readline in any shell mode.  I personally do not care about that (I
only interact with guile from Emacs using Geiser, at least for now), but someone
else might care.

Ignoring the fact that disabling the colors for ansi-term (and other modes?)
might not be necessary neither, I am not sure how to write more robust check.

The patch I was considering is at the end of the email, feel free to use it if
the trade-off would be acceptable.

diff --git a/gnu/system/shadow.scm b/gnu/system/shadow.scm
index d9f13271d8..fcd1d76c18 100644
--- a/gnu/system/shadow.scm
+++ b/gnu/system/shadow.scm
@@ -215,24 +215,26 @@ (define %default-nanorc

 (define %default-dotguile
   (plain-file "dot-guile"
-              "(cond ((false-if-exception (resolve-interface '(ice-9 readline)))
-       =>
-       (lambda (module)
-         ;; Enable completion and input history at the REPL.
-         ((module-ref module 'activate-readline))))
-      (else
-       (display \"Consider installing the 'guile-readline' package for
-convenient interactive line editing and input history.\\n\\n\")))
+              ";;; -*- mode: scheme -*-

-      (unless (getenv \"INSIDE_EMACS\")
-        (cond ((false-if-exception (resolve-interface '(ice-9 colorized)))
-               =>
-               (lambda (module)
-                 ;; Enable completion and input history at the REPL.
-                 ((module-ref module 'activate-colorized))))
-              (else
-               (display \"Consider installing the 'guile-colorized' package
-for a colorful Guile experience.\\n\\n\"))))\n"))
+(unless (getenv \"INSIDE_EMACS\")
+  (cond ((false-if-exception (resolve-interface '(ice-9 readline)))
+         =>
+         (lambda (module)
+           ;; Enable completion and input history at the REPL.
+           ((module-ref module 'activate-readline))))
+        (else
+         (display \"Consider installing the 'guile-readline' package for
+convenient interactive line editing and input history.\n\n\")))
+
+  (cond ((false-if-exception (resolve-interface '(ice-9 colorized)))
+         =>
+         (lambda (module)
+           ;; Enable completion and input history at the REPL.
+           ((module-ref module 'activate-colorized))))
+        (else
+         (display \"Consider installing the 'guile-colorized' package
+for a colorful Guile experience.\n\n\"))))\n"))

 (define %default-skeleton-home-config
   (plain-file "default-home-config" "\


Have a nice day,
Tomas Volf

--
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 1 year and 100 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.