[ESS] Change in ESS affects Org generating images through R session

Lionel Henry ||one|@hry @end|ng |rom gm@||@com
Fri Apr 8 21:35:36 CEST 2016


I think this is linked to https://github.com/emacs-ess/ESS/issues/314 <https://github.com/emacs-ess/ESS/issues/314>

I'm looking into it.

Lionel


> On 8 avr. 2016, at 19:19, Charles C. Berry <ccberry using ucsd.edu> wrote:
> 
> On Fri, 8 Apr 2016, William Denton wrote:
> 
>> It's possible a recent change in ESS has broken generating images with R in Org. I raised this on the Org list and was asked to bring it over here (see below).
>> 
> 
> I get the same error without org-mode.
> 
>> This works in Org, and generates an image:
>> 
>> #+BEGIN_SRC R :results graphics :file example.png
>> plot(1)
>> #+END_SRC
>> 
>> But if I start an R session (M-x R) and then run this, with :session, I get an error.
>> 
>> #+BEGIN_SRC R :session :results graphics :file example.png
>> plot(1)
>> #+END_SRC
> 
> 
> The code this passes to ESS is
> 
> #+BEGIN_SRC R
>  png(filename="example.png"); tryCatch({
>      plot(1)
>  },error=function(e){plot(x=-1:1, y=-1:1, type='n', xlab='', ylab='', axes=FALSE); text(x=0, y=0, labels=e$message, col='red'); paste('ERROR', e$message, sep=' : ')}); dev.off()
> #+END_SRC
> 
> and if I paste this into a *.R buffer and try to run ess-eval-buffer it returns the same error.
> 
> Repreating `ess-eval-line-step' will run this flawlessly.
> 
> This is with
> 
> ess-version: 15.09-2 patched [git: e87714be20a038b650e49cb2d798531175a8654f]
> 
> 
>> 
>> The error is
>> 
>> + + Error: unexpected symbol in:
>> "plot(1)
>> },error=function(e){plot(x=-1:1, y=-1:1, type='n"
>> 
> 
> [snip]
> 
> HTH,
> 
> Chuck
> 
> ______________________________________________
> ESS-help using r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/ess-help


	[[alternative HTML version deleted]]




More information about the ESS-help mailing list