[ESS] Emacs freezes upon 'Starting evaluation'

Stephen Eglen sje30 at damtp.cam.ac.uk
Fri Aug 3 00:59:16 CEST 2012


Paul Metzner <paul.metzner <at> gmail.com> writes:

> 
> > Can you please provide the troublesome code?
> 
> I believe this bit of code caused a freeze:
> 
> m <- do.call(rbind, mclapply(d, function(x){ merge(x, y, by = c('a', 'b'))},
>   mc.silent = TRUE))
> 
> It loops through a list of data frames with a multicore lapply and merges each
> data frame with another data frame. The resulting data frames are put together
> into one big data frame with rbind. But like I said, sometimes the code runs
> perfectly, sometimes it doesn't.

Following up on this email from late last year, I had the same problem recently.
I thought initially ESS was at fault when I tried something simple like

mclapply(1:10, rnorm)

within an *R* buffer.  Sometimes it worked, but sometimes it hung, and no amount
of C-g helped.  Trying this in a terminal (not Emacs) also showed the same
problem, so ESS was not at fault.

It turns out that I'd loaded tcltk, which is known to interfere with mclapply
and friends.

https://stat.ethz.ch/pipermail/r-sig-hpc/2009-August/000324.html

Solution of not loading tcltk in a fresh session solved my problem.

Stephen



More information about the ESS-help mailing list