Skip to content

Cannot install r-languageserver in treesitter (Neovim) when R-CoprManager installed #48

@py9mrg

Description

@py9mrg

Hello,

As per title, when I have R-CoprManager installed I cannot install r-languageserver in treesitter (using Neovim, but I guess it's the same for other editors).

In my case (here using LazyVim, but I also tried with the Quarto kickstarter) I get the following error:

Cloning into '.'...
        From https://github.com/mason-org/r-languageserver
         * tag               v0.3.16    -> FETCH_HEAD
        + ./bin/install v0.3.16
        Downloading GitHub repo jozefhajnala/languageserversetup@HEAD
        ── R CMD build ─────────────────────────────────────────────────────────────────
        * checking for file/tmp/Rtmp5NKZFW/remotes862952236f5d/jozefhajnala-languageserversetup-3daf44a/DESCRIPTION... OK
        * preparinglanguageserversetup:
        * checking DESCRIPTION meta-information ... OK
        * checking for LF line-endings in source and make files and shell scripts
        * checking for empty or unneeded directories
        OmittedLazyDatafrom DESCRIPTION
        * buildinglanguageserversetup_0.1.2.900.tar.gz* installing *source* packagelanguageserversetup...
        ** using staged installation
        ** R
        ** inst
        ** byte-compile and prepare package for lazy loading
        ** help
        *** installing help indices
            finding HTML links ...  converting help for packagelanguageserversetupdone
            languageserver_add_to_rprofile          html  
            languageserver_detect                   html  
            languageserver_install                  html  
            languageserver_remove_from_rprofile     html  
            languageserver_startup                  html  
        ** building package indices
        ** testing if installed package can be loaded from temporary location
        ** testing if installed package can be loaded from final location
        ** testing if installed package keeps a record of temporary installation path
        * DONE (languageserversetup)
        Keeping option:langserver_libraryvalue: /home/XXX/.local/share/nvim/mason/staging/r-languageserver/build
        Setting option:langserver_processPattto: languageserver::run
        Keeping option:langserver_quietvalue: FALSE
        Setting option:langserver_quiet_serverprocto: FALSE
        Setting option:langserver_rprofile_candidatesto: /home/XXX/.Rprofile
        system_dep_available not found, determining
            sysname is linux, pid is: 34345
            get_docall_args: class(pid)=linux, pid=34345
            setting get_docall_args: system2, list(command = "ps", args = c("-p", "34345", "-o", "command", "--no-headers"), stdout = FALSE)
        <environment: namespace:languageserversetup>
        system_dep_available determined: TRUE
        langserver_install Starting
        determined new .lib.loc: /home/XXX/.local/share/nvim/mason/staging/r-languageserver/build, /usr/share/R/library
        assigning /home/XXX/.local/share/nvim/mason/staging/r-languageserver/build/usr/share/R/library to .lib.loc
        running dev installation
        installing remotes into: /home/XXXX/.local/share/nvim/mason/staging/r-languageserver/build
        Error: dbus: Call failed: [Errno 6] No such device or address: '/proc/34345/fd/2'
        langserver_install Exiting
        Execution halted
        spawn: bash failed with exit code 1 and signal 0. 

Doing some searching, dbus issues seem to be related to bspm not being installed in R. If I manually do it and then add bspm::enable() to .Rprofile it doesn't help so I'm at a bit of a loss?

My current solution is simply to uninstall R-CoprManager while installing r-languageserver in treesitter, and then reinstalling it. But I don't know if this "solution" will break something later.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions