Hi R Developers, I have found what I think is a bug in the RScript.exe in version 3.5.0 of R for Windows. When I call Rscript.exe for Version 3.5 of R, it is unable to open the file if the file name or path has a space in it. As an example of what happens, I saved 2 files with the code: cat("What do you get when you multiply 6 * 9?") as C:\foo bar.R and as C:\foo_bar.R When I in a DOS command window try to run these using version 3.4.3 and 3.5: C:\>"C:\Program Files\R\R-3.4.3\bin\x64\Rscript.exe" "C:\foo bar.R" What do you get when you multiply 6 * 9? C:\>"C:\Program Files\R\R-3.4.3\bin\x64\Rscript.exe" "C:\foo_bar.R" What do you get when you multiply 6 * 9? C:\>"C:\Program Files\R\R-3.5.0\bin\x64\Rscript.exe" "C:\foo bar.R" Fatal error: cannot open file 'C:\foo': No such file or directory C:\>"C:\Program Files\R\R-3.5.0\bin\x64\Rscript.exe" "C:\foo_bar.R" What do you get when you multiply 6 * 9? C:\> When I try to run the file with a space in the name in version 3.5.0 of R, there is a fatal error saying there is no such file. Kerry Jackson Job title: Senior Account Manager, Ipsos Connect US RA Testing GMU Phone: (203) 840-3443 [[alternative HTML version deleted]]
Thanks for the report. A quick workaround before this gets fixed is to add an extra first argument that has no space in it, e.g. Rscript --vanilla "foo bar.R" The problem exists on all systems, not just Windows. Best Tomas On 04/25/2018 09:55 PM, Kerry Jackson wrote:> Hi R Developers, > I have found what I think is a bug in the RScript.exe in version 3.5.0 of R for Windows. > When I call Rscript.exe for Version 3.5 of R, it is unable to open the file if the file name or path has a space in it. > As an example of what happens, I saved 2 files with the code: > cat("What do you get when you multiply 6 * 9?") > as C:\foo bar.R and as C:\foo_bar.R > When I in a DOS command window try to run these using version 3.4.3 and 3.5: > C:\>"C:\Program Files\R\R-3.4.3\bin\x64\Rscript.exe" "C:\foo bar.R" > What do you get when you multiply 6 * 9? > C:\>"C:\Program Files\R\R-3.4.3\bin\x64\Rscript.exe" "C:\foo_bar.R" > What do you get when you multiply 6 * 9? > C:\>"C:\Program Files\R\R-3.5.0\bin\x64\Rscript.exe" "C:\foo bar.R" > Fatal error: cannot open file 'C:\foo': No such file or directory > > > C:\>"C:\Program Files\R\R-3.5.0\bin\x64\Rscript.exe" "C:\foo_bar.R" > What do you get when you multiply 6 * 9? > C:\> > When I try to run the file with a space in the name in version 3.5.0 of R, there is a fatal error saying there is no such file. > > > Kerry Jackson > Job title: Senior Account Manager, Ipsos Connect US RA Testing GMU > Phone: (203) 840-3443 > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-devel at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel
Fixed in R-devel. I will port to R-patched after more testing. Tomas On 04/26/2018 01:52 AM, Tomas Kalibera wrote:> Thanks for the report. A quick workaround before this gets fixed is to > add an extra first argument that has no space in it, e.g. > > Rscript --vanilla "foo bar.R" > > The problem exists on all systems, not just Windows. > > Best > Tomas > > On 04/25/2018 09:55 PM, Kerry Jackson wrote: >> Hi R Developers, >> I have found what I think is a bug in the RScript.exe in version >> 3.5.0 of R for Windows. >> When I call Rscript.exe for Version 3.5 of R, it is unable to open >> the file if the file name or path has a space in it. >> As an example of what happens, I saved 2 files with the code: >> cat("What do you get when you multiply 6 * 9?") >> as C:\foo bar.R and as C:\foo_bar.R >> When I in a DOS command window try to run these using version 3.4.3 >> and 3.5: >> C:\>"C:\Program Files\R\R-3.4.3\bin\x64\Rscript.exe" "C:\foo bar.R" >> What do you get when you multiply 6 * 9? >> C:\>"C:\Program Files\R\R-3.4.3\bin\x64\Rscript.exe" "C:\foo_bar.R" >> What do you get when you multiply 6 * 9? >> C:\>"C:\Program Files\R\R-3.5.0\bin\x64\Rscript.exe" "C:\foo bar.R" >> Fatal error: cannot open file 'C:\foo': No such file or directory >> >> >> C:\>"C:\Program Files\R\R-3.5.0\bin\x64\Rscript.exe" "C:\foo_bar.R" >> What do you get when you multiply 6 * 9? >> C:\> >> When I try to run the file with a space in the name in version 3.5.0 >> of R, there is a fatal error saying there is no such file. >> >> >> Kerry Jackson >> Job title: Senior Account Manager, Ipsos Connect US RA Testing GMU >> Phone: (203) 840-3443 >> >> >> ????[[alternative HTML version deleted]] >> >> ______________________________________________ >> R-devel at r-project.org mailing list >> https://stat.ethz.ch/mailman/listinfo/r-devel > >