I'm working in Scheme with Org Babel and came across a nasty problem. "Babel support for session-based Scheme evaluation requires Geiser". And indeed, when evaluating a source block as part of a session, you wind-up evaluating geiser-eval-region/wait. This function takes a timeout parameter, but ob-scheme declines to send one, and so a default value is used: ten seconds. Hard coded; no customization variable. Worse, when you timeout, the queue you share with the underlying Scheme REPL is left in an invalid state, so that no more source blocks may be evaluated.
I worked around the problem with a little advice:
(defvar sp1ff/geiser-default-timeout 120 "Default timeout, in seconds, for Geiser evaluations") (defun geiser-eval-region/wait-default-timeout (args) (list (nth 0 args) (nth 1 args) (or (nth 2 args) sp1ff/geiser-default-timeout))) (advice-add 'geiser-eval-region/wait :filter-args #'geiser-eval-region/wait-default-timeout)
I thought about submitting a PR introducing a customization variable, but I'd rather Geiser simply stop trying to enforce timeouts altogether. There's never a hard & fast limit, no other backend of which I'm aware does so: they let the REPL handle the evaluation asynchronously, so that the user can simply kill the process and/or buffer if they decide it's taking too long.