Re: [ESS] [R-win] Difficulty installing R packages under Windows 11 / Cygwin

2023-12-03 Thread Dirk Eddelbuettel via ESS-help


On 2 December 2023 at 22:06, Tomas Kalibera via ESS-help wrote:
| R is not being tested under WSL.

(From several arm lengths away:)  WSL2 appears to be very solid.

I had an early alpha tester of my (then brand-new) r2u [1] using and
stressing it, it appears to work a like regular Ubuntu system so 'everything
just works' yet it is on Windows. (Which I haven't touched in a decade+.)

Dirk

[1] r2u provides all of CRAN plus ~ 400 BioC package via apt with bspm as
added interface. So say install.packages(c("tidyverse", "rstan", "brms")) and
everything installs as binaries in 33 secs [2] with _all_ system dependencies
resolved via apt. (Also FYI, Inaki has a similar system for Fedora called
cran2copr.) More about r2u is at https://eddelbuettel.github.io/r2u

[2] Vidoe of that command running in 33 seconds in an empty container with
only R and r2u is at:
https://eddelbuettel.github.io/images/2023-12-03/r2u_tidyverse_rstan_brms_33secs_2023-12-03_07-26.gif

-- 
dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org

__
ESS-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/ess-help


Re: [ESS] [R-win] Difficulty installing R packages under Windows 11 / Cygwin

2023-12-02 Thread Tomas Kalibera via ESS-help



On 12/2/23 18:59, Sparapani, Rodney wrote:


Hi Robert:

Would they allow dual-booting?  I’m not saying that you can’t get ESS

to work under Cygwin.  On the contrary, it did work at one time so

it certainly can be done.  However, that is not currently supported

so you are on your own.  But, perhaps there are others in the same

straight-jacket here on ess-help that might be willing to help?

Please speak up if so!

In regards to WSL, that came out after I permanently switched

to macOS. But, I think it is worth a try too.  Since you will be

running pure Linux binaries, then it might work out of the box.

And maybe there are more people here interested in WSL than

Cygwin. Also, the more recent WSL 2 (released in 2019) sounds

like it is more compatible than WSL 1 (released in 2016).

R is not being tested under WSL. When I tried last time (which is 
several years ago), there were some issues. Maybe they are already gone 
by now, I don't know, but it is not a supported platform.


Tomas


--

Rodney Sparapani, Associate Professor of Biostatistics, He/Him/His

Vice President, Wisconsin Chapter of the American Statistical Association

Institute for Health and Equity, Division of Biostatistics

Medical College of Wisconsin, Milwaukee Campus

*From: *Robert Lerche 
*Date: *Saturday, December 2, 2023 at 11:40 AM
*To: *Sparapani, Rodney , Tomas Kalibera 

*Subject: *RE: [R-win] Difficulty installing R packages under Windows 
11 / Cygwin


ATTENTION: This email originated from a sender outside of MCW. Use 
caution when clicking on links or opening attachments.




Thanks for your thoughtful reply.  Alas, I am using a company-provided 
laptop.  I would much prefer to run Linux as I do on my personal 
system but that is not in the cards.  I have plenty of access to Linux 
servers and of course I can run things there but it’s a bit inconvenient.


I thought about using WSL (Windows Subsystem for Linux). I have some 
experience with early versions of that [which leads me to avoid it ].


It is my fate to cope with legacy junk on projects that were late when 
I joined. Ah well it’s a living.


*From:*Sparapani, Rodney 
*Sent:* Saturday, December 2, 2023 9:28 AM
*To:* Robert Lerche ; Tomas Kalibera 
; ess-help (ess-help@r-project.org) 

*Subject:* Re: [R-win] Difficulty installing R packages under Windows 
11 / Cygwin


[EXTERNAL MESSAGE] Be mindful when clicking links or attachments

Hi Robert:

There was a time when we supported ESS under Cygwin.

In other words, run elisp code assuming UNIX/Linux rather

than Windows even though Windows is the OS.  However,

that was a long time ago: at least 10 years since I last tried it.

Cygwin has largely fallen out of fashion since you can now so

easily install Ubuntu on typical hardware: something that

has markedly improved since 2013.  Therefore, I would not

expect Cygwin support to work out of the box since there

has been no recent testing.  Also, Windows is not very

popular with R users since there is no forking support

for the parallel package.  So switching to Linux is well

worth it.  I used to run Windows inside VirtualBox when

I needed to do PC stuff like Office and iTunes

(before switching to macOS and never looking back ;o)

--

Rodney Sparapani, Associate Professor of Biostatistics, He/Him/His

Vice President, Wisconsin Chapter of the American Statistical Association

Institute for Health and Equity, Division of Biostatistics

Medical College of Wisconsin, Milwaukee Campus

*From: *ESS-bugs  on behalf of Robert 
Lerche 

*Date: *Saturday, December 2, 2023 at 11:04 AM
*To: *Tomas Kalibera , 
ess-b...@r-project.org 
*Cc: *ess-bugs-ow...@r-project.org , 
r-wind...@r-project.org 
*Subject: *RE: [R-win] Difficulty installing R packages under Windows 
11 / Cygwin


ATTENTION: This email originated from a sender outside of MCW. Use 
caution when clicking on links or opening attachments.



Let me try raw text:

Tomas, my thanks for your prompt and useful response. I followed your 
instructions and the Windows (MinGW/MSYS2) R and ggplot2 of course 
work perfectly well launched from a Cygwin bash shell.  Alas, ESS 
inside Cygwin Emacs 29.1 doesn't quite work, launching an R process 
gives an error and although R is running with stdin/stdout directed to 
the Emacs buffer there is no tab completion.


[background for the benefit of ess-b...@r-project.org]

I recently received a new Windows 11 laptop from our IT department and 
I'm trying to recreate my R environment (Cygwin/Emacs/ESS/R/ggplot2). 
Originally I installed R 4.3.0 as packaged in Cygwin's setup.exe 
utility (in the Math section). I was unable to add ggplot2. Tomas 
kindly pointed me to the pre-built Windows binaries and as expected 
installing it and ggplot2 went smoothly.


I perused 

Re: [ESS] [R-win] Difficulty installing R packages under Windows 11 / Cygwin

2023-12-02 Thread Sparapani, Rodney via ESS-help
Hi Robert:

Would they allow dual-booting?  I’m not saying that you can’t get ESS
to work under Cygwin.  On the contrary, it did work at one time so
it certainly can be done.  However, that is not currently supported
so you are on your own.  But, perhaps there are others in the same
straight-jacket here on ess-help that might be willing to help?
Please speak up if so!

In regards to WSL, that came out after I permanently switched
to macOS.  But, I think it is worth a try too.  Since you will be
running pure Linux binaries, then it might work out of the box.
And maybe there are more people here interested in WSL than
Cygwin.  Also, the more recent WSL 2 (released in 2019) sounds
like it is more compatible than WSL 1 (released in 2016).

--
Rodney Sparapani, Associate Professor of Biostatistics, He/Him/His
Vice President, Wisconsin Chapter of the American Statistical Association
Institute for Health and Equity, Division of Biostatistics
Medical College of Wisconsin, Milwaukee Campus

From: Robert Lerche 
Date: Saturday, December 2, 2023 at 11:40 AM
To: Sparapani, Rodney , Tomas Kalibera 

Subject: RE: [R-win] Difficulty installing R packages under Windows 11 / Cygwin
ATTENTION: This email originated from a sender outside of MCW. Use caution when 
clicking on links or opening attachments.

Thanks for your thoughtful reply.  Alas, I am using a company-provided laptop.  
I would much prefer to run Linux as I do on my personal system but that is not 
in the cards.  I have plenty of access to Linux servers and of course I can run 
things there but it’s a bit inconvenient.

I thought about using WSL (Windows Subsystem for Linux). I have some experience 
with early versions of that [which leads me to avoid it  ].

It is my fate to cope with legacy junk on projects that were late when I 
joined. Ah well it’s a living.

From: Sparapani, Rodney 
Sent: Saturday, December 2, 2023 9:28 AM
To: Robert Lerche ; Tomas Kalibera 
; ess-help (ess-help@r-project.org) 

Subject: Re: [R-win] Difficulty installing R packages under Windows 11 / Cygwin


[EXTERNAL MESSAGE] Be mindful when clicking links or attachments
Hi Robert:

There was a time when we supported ESS under Cygwin.
In other words, run elisp code assuming UNIX/Linux rather
than Windows even though Windows is the OS.  However,
that was a long time ago: at least 10 years since I last tried it.
Cygwin has largely fallen out of fashion since you can now so
easily install Ubuntu on typical hardware: something that
has markedly improved since 2013.  Therefore, I would not
expect Cygwin support to work out of the box since there
has been no recent testing.  Also, Windows is not very
popular with R users since there is no forking support
for the parallel package.  So switching to Linux is well
worth it.  I used to run Windows inside VirtualBox when
I needed to do PC stuff like Office and iTunes
(before switching to macOS and never looking back ;o)

--
Rodney Sparapani, Associate Professor of Biostatistics, He/Him/His
Vice President, Wisconsin Chapter of the American Statistical Association
Institute for Health and Equity, Division of Biostatistics
Medical College of Wisconsin, Milwaukee Campus

From: ESS-bugs 
mailto:mailman-boun...@stat.ethz.ch>> on behalf 
of Robert Lerche 
mailto:rler...@pacificbiosciences.com>>
Date: Saturday, December 2, 2023 at 11:04 AM
To: Tomas Kalibera mailto:tomas.kalib...@gmail.com>>, 
ess-b...@r-project.org 
mailto:ess-b...@r-project.org>>
Cc: ess-bugs-ow...@r-project.org 
mailto:ess-bugs-ow...@r-project.org>>, 
r-wind...@r-project.org 
mailto:r-wind...@r-project.org>>
Subject: RE: [R-win] Difficulty installing R packages under Windows 11 / Cygwin
ATTENTION: This email originated from a sender outside of MCW. Use caution when 
clicking on links or opening attachments.


Let me try raw text:

Tomas, my thanks for your prompt and useful response. I followed your 
instructions and the Windows (MinGW/MSYS2) R and ggplot2 of course work 
perfectly well launched from a Cygwin bash shell.  Alas, ESS inside Cygwin 
Emacs 29.1 doesn't quite work, launching an R process gives an error and 
although R is running with stdin/stdout directed to the Emacs buffer there is 
no tab completion.

[background for the benefit of 
ess-b...@r-project.org]

I recently received a new Windows 11 laptop from our IT department and I'm 
trying to recreate my R environment (Cygwin/Emacs/ESS/R/ggplot2). Originally I 
installed R 4.3.0 as packaged in Cygwin's setup.exe utility (in the Math 
section). I was unable to add ggplot2. Tomas kindly pointed me to the pre-built 
Windows binaries and as expected installing it and ggplot2 went smoothly.

I perused 

Re: [ESS] [R-win] Difficulty installing R packages under Windows 11 / Cygwin

2023-12-02 Thread Sparapani, Rodney via ESS-help
Hi Robert:

There was a time when we supported ESS under Cygwin.
In other words, run elisp code assuming UNIX/Linux rather
than Windows even though Windows is the OS.  However,
that was a long time ago: at least 10 years since I last tried it.
Cygwin has largely fallen out of fashion since you can now so
easily install Ubuntu on typical hardware: something that
has markedly improved since 2013.  Therefore, I would not
expect Cygwin support to work out of the box since there
has been no recent testing.  Also, Windows is not very
popular with R users since there is no forking support
for the parallel package.  So switching to Linux is well
worth it.  I used to run Windows inside VirtualBox when
I needed to do PC stuff like Office and iTunes
(before switching to macOS and never looking back ;o)

--
Rodney Sparapani, Associate Professor of Biostatistics, He/Him/His
Vice President, Wisconsin Chapter of the American Statistical Association
Institute for Health and Equity, Division of Biostatistics
Medical College of Wisconsin, Milwaukee Campus

From: ESS-bugs  on behalf of Robert Lerche 

Date: Saturday, December 2, 2023 at 11:04 AM
To: Tomas Kalibera , ess-b...@r-project.org 

Cc: ess-bugs-ow...@r-project.org , 
r-wind...@r-project.org 
Subject: RE: [R-win] Difficulty installing R packages under Windows 11 / Cygwin
ATTENTION: This email originated from a sender outside of MCW. Use caution when 
clicking on links or opening attachments.


Let me try raw text:

Tomas, my thanks for your prompt and useful response. I followed your 
instructions and the Windows (MinGW/MSYS2) R and ggplot2 of course work 
perfectly well launched from a Cygwin bash shell.  Alas, ESS inside Cygwin 
Emacs 29.1 doesn't quite work, launching an R process gives an error and 
although R is running with stdin/stdout directed to the Emacs buffer there is 
no tab completion.

[background for the benefit of ess-b...@r-project.org]

I recently received a new Windows 11 laptop from our IT department and I'm 
trying to recreate my R environment (Cygwin/Emacs/ESS/R/ggplot2). Originally I 
installed R 4.3.0 as packaged in Cygwin's setup.exe utility (in the Math 
section). I was unable to add ggplot2. Tomas kindly pointed me to the pre-built 
Windows binaries and as expected installing it and ggplot2 went smoothly.

I perused 
https://urldefense.com/v3/__https://ess.r-project.org/index.php?Section=home__;!!H8mHWRdzp34!7kh3oo0D5fJMElRU8O3Xz6Hmc-Y0ufB8oSgC1uqX1yvGwlD9fv0aJdrxgnpo0X7E1tfYMI0XU5Y1iNnIKnpbUlLT$
  and pulled the latest ESS via git clone. Make worked but now when I try to 
launch R inside Emacs [with (require 'ess-r-mode) in my .emacs file] an error 
message appears:

ess-r--init-error-handler: Wrong type argument: listp, "Caused by error: R 
error during background ESS command base::tryCatch(
 base::local({
   
base::source('/usr/share/emacs/site-lisp/ess/etc/ESSR/R/.load.R', local=TRUE) 
#define load.ESSR
   .ess.ESSR.load('/usr/share/emacs/site-lisp/ess/etc/ESSR/R')
 }),
 error = function(cnd) {
   msg <- paste0('ESSR::ERROR \"', conditionMessage(cnd), '\"')
   writeLines(msg)
 }
   )
Error: cannot open the connection"

Following this the buffer is live but tab completion fails.

I attach the ess build log:

G6WM1J3-89CBD7 ~ $ git clone 
https://urldefense.com/v3/__https://github.com/emacs-ess/ESS.git__;!!H8mHWRdzp34!7kh3oo0D5fJMElRU8O3Xz6Hmc-Y0ufB8oSgC1uqX1yvGwlD9fv0aJdrxgnpo0X7E1tfYMI0XU5Y1iNnIKr2dFRa2$
  ess-latest
Cloning into 'ess-latest'...
remote: Enumerating objects: 44632, done.
remote: Counting objects: 100% (1252/1252), done.
remote: Compressing objects: 100% (424/424), done.
remote: Total 44632 (delta 904), reused 1152 (delta 827), pack-reused 43380
Receiving objects: 100% (44632/44632), 27.28 MiB | 1.76 MiB/s, done.
Resolving deltas: 100% (33688/33688), done.
G6WM1J3-89CBD7 ~ $ cd ess-latest/
G6WM1J3-89CBD7 ~/ess-latest $ make
* VERSIONS **
GNU Emacs 29.1
ESS 18.10.3snapshot
ESSR 1.8
*
make -C lisp all
make[1]: Entering directory '/home/rlerche/ess-latest/lisp'
which: no wget in (/cygdrive/c/Program 
Files/R/R-4.3.2/bin:/usr/local/bin:/usr/bin:/cygdrive/c/Program Files 
(x86)/Common 
Files/Oracle/Java/javapath:/cygdrive/c/WINDOWS/system32:/cygdrive/c/WINDOWS:/cygdrive/c/WINDOWS/System32/Wbem:/cygdrive/c/WINDOWS/System32/WindowsPowerShell/v1.0:/cygdrive/c/WINDOWS/System32/OpenSSH:/cygdrive/c/Program
 Files/PuTTY:/cygdrive/c/Program Files