Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 /usr/local/share/emacs/site-lisp/org/)]

2014-10-10 Thread Henrik Singmann

Hi Aaron,

This patch also solves the problem for me. No more ".ess.eval" not found!

Thanks a lot,
Henrik


Am 10.10.2014 um 06:38 schrieb Aaron Ecay:

Hi Henrik,

2014ko urriak 8an, Henrik Singmann-ek idatzi zuen:


I unfortunately can confirm that org-babel-R-initiate-session contains
the lines you mentioned at exactly 15 lines down. Deleting ob-R.elc
(which was of the same date as ob-R.el) didn't affect anything as did
reloading org uncompiled (C-u C-c C-x !).


I could reproduce this, also with recent git org and ESS.  It looks like
ESS is doing more complicated things, necessitating a more thorough
check that the session is in fact ready.

Can you test the attached patch?  It fixed the problem for me.



Thanks,



--
Dr. Henrik Singmann
Albert-Ludwigs-Universität Freiburg, Germany
http://www.psychologie.uni-freiburg.de/Members/singmann



Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 /usr/local/share/emacs/site-lisp/org/)]

2014-10-08 Thread Henrik Singmann


I unfortunately can confirm that org-babel-R-initiate-session contains the 
lines you mentioned at exactly 15 lines down. Deleting ob-R.elc (which was of 
the same date as ob-R.el) didn't affect anything as did reloading org 
uncompiled (C-u C-c C-x !).

Henrik

Am 08.10.2014 um 03:21 schrieb Charles Berry:

Henrik Singmann  psychologie.uni-freiburg.de> writes:



Dear all,

Sorry to resurrect this thread but I still have the issue discussed here.

I get "Error: could not find

function ".ess.eval"" when inside an R code block with :session *R* but
not without :session *R*.



Please confirm that when you do

  M-x find-function RET org-babel-R-initiate-session RET

and scroll down 15 lines:

  M-1 M-5 

you see something like this:

   (ess-wait-for-process
(get-process (or ess-local-process-name
 ess-current-process-name)))


If not, there is something broken in your setup.

If you do see that code, please do

  C-x d 


and verify that ob-R.el is older than ob-R.elc. If it is not older delete
ob-R.elc and restart.

Let us know how it goes either way.

Chuck






--
Dr. Henrik Singmann
Albert-Ludwigs-Universität Freiburg, Germany
http://www.psychologie.uni-freiburg.de/Members/singmann




Re: [O] [PATCH] WAS Re: Bug: problem w/ R code blocks [8.3beta (release_8.3beta-362-ga92789 /usr/local/share/emacs/site-lisp/org/)]

2014-10-07 Thread Henrik Singmann

Dear all,

Sorry to resurrect this thread but I still have the issue discussed here. I get "Error: could 
not find function ".ess.eval"" when inside an R code block with :session *R* but not 
without :session *R*.

More specifically, in the following .org file the first code block works but 
not the second one:

--8<---cut here---start->8---
#+begin_src R
  date()
#+end_src

#+RESULTS:
: Tue Oct 07 19:31:21 2014

#+begin_src R :session *R*
  date()
#+end_src

#+RESULTS:

--8<---cut here---end--->8---

Note that I use the latest Emacs on Windows (24.3.1, i386-mingw-nt6.1.7601) 
with the latest Org-mode (version 8.3beta, release_8.3beta-427-g942eb6) and the 
current development version of ESS (the same happens for ESS 14.09). 
Interestingly and as reported, it does not happen when downgrading to ESS 13.09 
(but as this was handled as an org-mode problem so far I decided to keep it on 
this list).

Furthermore, my .emacs file currently only consists of the following:

--8<---cut here---start->8---

(require 'org)
(require 'ess-site)

(custom-set-variables
 ;; custom-set-variables was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 '(inhibit-startup-screen t)
 )
 
 (custom-set-faces

 ;; custom-set-faces was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 )
 
 
 (org-babel-do-load-languages

  'org-babel-load-languages
  '((emacs-lisp . nil)
(R . t)))

(setq org-babel-R-command "C:/Progra~1/R/R-3.1.1/bin/x64/rterm.exe --slave 
--no-save")

--8<---cut here---end--->8---

The windows is Windows 7, 64 bit.

Can anybody reproduce or solve?

Henrik


Am 19.09.2014 um 00:45 schrieb Charles C. Berry:

On Thu, 18 Sep 2014, Charles C. Berry wrote:


On Thu, 18 Sep 2014, Cook, Malcolm wrote:


Hi,

Hmm, I spoke too soon the problem is only partially fixed by this patch...




Trying to work with in org-mode with R code blocks attached to persistent 
sessions (i.e. adding ':session myRsession' to the code block header ) makes 
things start to break again, at least in my hands.


Really? I have been working for hours using the :session header with no 
problems.

What exactly breaks? Do you have an example?

FWIW, this works when I move my cursor into the source block and C-c C-c.

--8<---cut here---start->8---
#+BEGIN_SRC R :session myRsession
abc <- 1
abc+1
#+END_SRC
--8<---cut here---end--->8---

Producing

--8<---cut here---start->8---
#+RESULTS:
: 2
--8<---cut here---end--->8---

which is what I expect.

I use Org-mode version 8.3beta (release_8.3beta-366-gb2fca7.

(updated a few hours back)



Forget to mention:

ess-version: 14.09 [git: 9c248f1a026b6990d0cd0cd326d82854d5cafb26]


Chuck




--
Dr. Henrik Singmann
Albert-Ludwigs-Universität Freiburg, Germany
http://www.psychologie.uni-freiburg.de/Members/singmann