file name conversion problem -- name too long?

Hi! I've upgraded to the new R Studio version (1.3.959) and when trying to use the new 'Tutorial' feature I get the following error:

Error in file.exists(children) :
file name conversion problem -- name too long?
Traceback (most recent calls last):
13: (...)
12: .rs.tutorial.installPackageDependencies(name, package)
11: renv::dependencies(path, quiet = TRUE)
10: delegate(renv_dependencies_impl)
9: eval(call, envir = parent.frame(2))
8: eval(call, envir = parent.frame(2))
7: (...)
6: renv_dependencies_find(path, root)
5: lapply(path, renv_dependencies_find_impl, root = root)
4: FUN(X[[i]], ...)
3: renv_dependencies_find_dir(path, root)
2: renv_dependencies_find_dir_children(path, root)
1: file.exists(children)
Error in file.exists(children) :
file name conversion problem -- name too long?
Traceback (most recent calls last):
13: (...)
12: .rs.tutorial.installPackageDependencies(name, package)
11: renv::dependencies(path, quiet = TRUE)
10: delegate(renv_dependencies_impl)
9: eval(call, envir = parent.frame(2))
8: eval(call, envir = parent.frame(2))
7: (...)
6: renv_dependencies_find(path, root)
5: lapply(path, renv_dependencies_find_impl, root = root)
4: FUN(X[[i]], ...)
3: renv_dependencies_find_dir(path, root)
2: renv_dependencies_find_dir_children(path, root)
1: file.exists(children)

This is my sessionInfo() output:

R version 4.0.0 (2020-04-24)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18363)

Matrix products: default

locale:
[1] LC_COLLATE=Spanish_Argentina.1252 LC_CTYPE=Spanish_Argentina.1252 LC_MONETARY=Spanish_Argentina.1252 LC_NUMERIC=C LC_TIME=Spanish_Argentina.1252

attached base packages:
[1] stats graphics grDevices utils datasets methods base

loaded via a namespace (and not attached):
[1] compiler_4.0.0 rsconnect_0.8.16 htmltools_0.4.0 tools_4.0.0 curl_4.3 yaml_2.2.1 Rcpp_1.0.4.6 rmarkdown_2.1 knitr_1.28 jsonlite_1.6.1 xfun_0.14
[12] digest_0.6.25 renv_0.10.0 openssl_1.4.1 rlang_0.4.6 evaluate_0.14 askpass_1.1

Does anybody know what could be wrong?

Tks!

1 Like

Hi,

Welcome to the RStudio community!

According to a similar post, it might be an issue with R itself and could be fixed be reinstalling R (not RStudio).

Hope this helps,
PJ

Hi! Unfortunately that didn't help me, I've installed it but nothing changed.

Here is my .libPaths() output if it helps:

[1] "C:/Users/augus/Documents/R/win-library/4.0" "C:/Program Files/R/R-4.0.0/library"

Hi,

I realise now that you're using the RStudio preview version.Since this is not a fully stable version yet, it might indeed lead to some issues. As I don't know what to do anymore, I'll make sure to alert someone else from the RStudio team to see if they can help you.

The only thing I can think of is that R sometimes gets in trouble with path names that contain special characters. So if the tutorial files are in a folder that have a path containing special characters (e.g. accents, Chinese, ...) try and put it in another one and see if it solves the issue. Your two base folders seem to be OK.

PJ

Hi! thanks!
The RStudio version is the latest, but not the preview version: https://download1.rstudio.org/desktop/windows/RStudio-1.3.959.exe

I don't have any special charachters in between the path... strange really...

I've tried on RStudio Server (on Ubuntu 16) and I have a similar problema with paths:

Couldn't normalize path in addResourcePath, with arguments: prefix = 'mathjax-local'; directoryPath = '/usr/lib/rstudio-server/resources/mathjax-26'

I'll follow this on another thread.

Same problem here with RStudio Version 1.3.959 and R version 4.0, did you find a solution?

Nothing new here... Still the same problem.. :neutral_face:

Hi,

I contacted the RStudio team again to remind them of this issue.

If you don't get a reply here within the next 24h, I advice you to open a ticket on the GitHub page, since this is related to a preview version of RStudio:

You can use this guide to provide all info

Fingers crossed :slight_smile:
PJ

1 Like

Sorry for the problems being encountered here. We are looking into it now and will reply once we have determine a workaround and/or code fix.

I suspect this is actually a bug in the renv package, used behind the scenes by learnr when determining what packages are required by a particular tutorial. See:

You could try installing the development version of renv , with:

renv::install("rstudio/renv")

and then trying to run their tutorials again once more. If this does indeed resolve the issue, I will push an updated version of renv to CRAN ASAP.

3 Likes

Hi Kevin and Gary,

indeed, I was able to use the Tutorials after installing the development version of renv!

When the package renv was released I had the same issue, but didn't realized that they were related.

I truly appreciate your help!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

An update for anyone watching this thread (or who stumbles upon it later): this issue should now be fixed in renv 0.11.0. Use:

install.packages("renv")

to install the latest version of renv available from CRAN.