Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

devtools::install_git fails #23

Open
1 task done
bainadeashish opened this issue Jul 23, 2021 · 6 comments
Open
1 task done

devtools::install_git fails #23

bainadeashish opened this issue Jul 23, 2021 · 6 comments

Comments

@bainadeashish
Copy link

bainadeashish commented Jul 23, 2021

Issue: devtools::install_git fails for below cmd

devtools::install_git(GIT_URL)
Error: Failed to install 'unknown package' from Git:
Error in 'git2r_remote_ls': malformed URL 'GIT_URL'


Environment (conda list):
root@3f49d12504a3:/# conda list
# packages in environment at /opt/miniconda:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
_r-mutex                  1.0.1               anacondar_1    conda-forge
binutils_impl_linux-64    2.33.1               he1b5a44_7    conda-forge
binutils_linux-64         2.33.1              h9595d00_17    conda-forge
brotlipy                  0.7.0           py38h27cfd23_1003  
bwidget                   1.9.14               ha770c72_0    conda-forge
bzip2                     1.0.8                h516909a_3    conda-forge
ca-certificates           2021.5.30            ha878542_0    conda-forge
cairo                     1.16.0            h3fc0475_1005    conda-forge
certifi                   2021.5.30        py38h578d9bd_0    conda-forge
cffi                      1.14.3           py38h261ae71_2  
chardet                   3.0.4           py38h06a4308_1003  
conda                     4.10.3           py38h578d9bd_0    conda-forge
conda-package-handling    1.7.2            py38h03888b9_0  
cryptography              3.2.1            py38h3c74f83_1  
curl                      7.71.1               he644dc0_3    conda-forge
fontconfig                2.13.1            h7e3eb15_1002    conda-forge
freetype                  2.10.4               h7ca028e_0    conda-forge
fribidi                   1.0.10               h36c2ea0_0    conda-forge
gcc_impl_linux-64         7.3.0                habb00fd_1  
gcc_linux-64              7.3.0               h553295d_17    conda-forge
gfortran_impl_linux-64    7.3.0                hdf63c60_5    conda-forge
gfortran_linux-64         7.3.0               h553295d_17    conda-forge
glib                      2.68.2               h36276a3_0  
graphite2                 1.3.13            h58526e2_1001    conda-forge
gsl                       2.6                  hf94e986_0    conda-forge
gxx_impl_linux-64         7.3.0                hdf63c60_1  
gxx_linux-64              7.3.0               h553295d_17    conda-forge
harfbuzz                  2.7.2                hee91db6_0    conda-forge
icu                       67.1                 he1b5a44_0    conda-forge
idna                      2.10                       py_0  
jpeg                      9d                   h36c2ea0_0    conda-forge
krb5                      1.17.2               h926e7f8_0    conda-forge
ld_impl_linux-64          2.33.1               h53a641e_7  
libblas                   3.9.0                8_openblas    conda-forge
libcblas                  3.9.0                8_openblas    conda-forge
libcurl                   7.71.1               hcdd3856_3    conda-forge
libedit                   3.1.20191231         h14c3975_1  
libffi                    3.3                  he6710b0_2  
libgcc-ng                 9.1.0                hdf63c60_0  
libgfortran-ng            7.5.0               h14aa051_19    conda-forge
libgfortran4              7.5.0               h14aa051_19    conda-forge
libgit2                   1.0.1                h0b03e73_1    conda-forge
libiconv                  1.16                 h516909a_0    conda-forge
liblapack                 3.9.0                8_openblas    conda-forge
libopenblas               0.3.12          pthreads_hb3c22a3_1    conda-forge
libpng                    1.6.37               h21135ba_2    conda-forge
libssh2                   1.9.0                hab1572f_5    conda-forge
libstdcxx-ng              9.1.0                hdf63c60_0  
libtiff                   4.1.0                hc3755c2_3    conda-forge
libuuid                   2.32.1            h14c3975_1000    conda-forge
libxcb                    1.13              h14c3975_1002    conda-forge
libxml2                   2.9.10               h68273f3_2    conda-forge
lz4-c                     1.9.2                he1b5a44_3    conda-forge
make                      4.3                  hd18ef5c_1    conda-forge
ncurses                   6.2                  he6710b0_1  
openssl                   1.1.1h               h516909a_0    conda-forge
pango                     1.42.4               h7062337_4    conda-forge
pcre                      8.44                 he1b5a44_0    conda-forge
pcre2                     10.35                h279444b_1    conda-forge
pip                       19.3.1                   py38_0  
pixman                    0.38.0            h516909a_1003    conda-forge
pthread-stubs             0.4               h36c2ea0_1001    conda-forge
pycosat                   0.6.3            py38h7b6447c_1  
pycparser                 2.20                       py_2  
pyopenssl                 19.1.0             pyhd3eb1b0_1  
pysocks                   1.7.1            py38h06a4308_0  
python                    3.8.5                h7579374_1  
python_abi                3.8                      2_cp38    conda-forge
r                         4.0             r40hd8ed1ab_1004    conda-forge
r-askpass                 1.1               r40hcdcec82_2    conda-forge
r-assertthat              0.2.1             r40hc72bb7e_2    conda-forge
r-backports               1.2.0             r40h9e2df91_0    conda-forge
r-base                    4.0.2                he766273_1    conda-forge
r-base64enc               0.1_3           r40hcdcec82_1004    conda-forge
r-boot                    1.3_28            r40hc72bb7e_0    conda-forge
r-brew                    1.0_6           r40hc72bb7e_1003    conda-forge
r-callr                   3.7.0             r40hc72bb7e_0    conda-forge
r-class                   7.3_17            r40hcdcec82_1    conda-forge
r-cli                     3.0.1             r40hc72bb7e_0    conda-forge
r-clipr                   0.7.1             r40hc72bb7e_0    conda-forge
r-cluster                 2.1.0             r40h31ca83e_4    conda-forge
r-codetools               0.2_18            r40hc72bb7e_0    conda-forge
r-commonmark              1.7             r40hcdcec82_1002    conda-forge
r-covr                    3.5.1             r40h0357c0b_0    conda-forge
r-crayon                  1.4.1             r40hc72bb7e_0    conda-forge
r-credentials             1.3.0             r40hc72bb7e_0    conda-forge
r-crosstalk               1.1.1             r40hc72bb7e_0    conda-forge
r-curl                    4.3               r40hcdcec82_1    conda-forge
r-desc                    1.3.0             r40hc72bb7e_0    conda-forge
r-devtools                2.4.2             r40hc72bb7e_0    conda-forge
r-digest                  0.6.27            r40h1b71b39_0    conda-forge
r-dt                      0.18              r40hc72bb7e_0    conda-forge
r-ellipsis                0.3.1             r40hcdcec82_0    conda-forge
r-evaluate                0.14              r40hc72bb7e_2    conda-forge
r-fansi                   0.4.1             r40hcdcec82_1    conda-forge
r-foreign                 0.8_80            r40hcdcec82_0    conda-forge
r-fs                      1.5.0             r40h0357c0b_0    conda-forge
r-gert                    1.0.2             r40h9e2df91_0    conda-forge
r-gh                      1.3.0             r40hc72bb7e_0    conda-forge
r-git2r                   0.27.1            r40h7253d3a_0    conda-forge
r-gitcreds                0.1.1             r40hc72bb7e_0    conda-forge
r-glue                    1.4.2             r40hcdcec82_0    conda-forge
r-highr                   0.9               r40hc72bb7e_0    conda-forge
r-htmltools               0.5.0             r40h0357c0b_0    conda-forge
r-htmlwidgets             1.5.3             r40hc72bb7e_0    conda-forge
r-httr                    1.4.2             r40hc72bb7e_0    conda-forge
r-ini                     0.3.1           r40hc72bb7e_1003    conda-forge
r-jsonlite                1.7.1             r40hcdcec82_0    conda-forge
r-kernsmooth              2.23_18           r40h7679c2e_0    conda-forge
r-knitr                   1.33              r40hc72bb7e_0    conda-forge
r-later                   1.1.0.1           r40h0357c0b_0    conda-forge
r-lattice                 0.20_41           r40hcdcec82_2    conda-forge
r-lazyeval                0.2.2             r40hcdcec82_2    conda-forge
r-lifecycle               0.2.0             r40h6115d3f_1    conda-forge
r-magrittr                2.0.1             r40h9e2df91_1    conda-forge
r-markdown                1.1               r40hcdcec82_1    conda-forge
r-mass                    7.3_53            r40hcdcec82_0    conda-forge
r-matrix                  1.2_18            r40h7fa42b6_3    conda-forge
r-memoise                 1.1.0           r40h6115d3f_1004    conda-forge
r-mgcv                    1.8_33            r40h7fa42b6_0    conda-forge
r-mime                    0.9               r40hcdcec82_1    conda-forge
r-nlme                    3.1_150           r40h31ca83e_0    conda-forge
r-nnet                    7.3_14            r40hcdcec82_1    conda-forge
r-openssl                 1.4.3             r40he5c4762_0    conda-forge
r-pkgbuild                1.2.0             r40hc72bb7e_0    conda-forge
r-pkgload                 1.1.0             r40h0357c0b_0    conda-forge
r-praise                  1.0.0           r40hc72bb7e_1004    conda-forge
r-prettyunits             1.1.1             r40hc72bb7e_1    conda-forge
r-processx                3.4.4             r40hcdcec82_0    conda-forge
r-promises                1.1.1             r40h0357c0b_0    conda-forge
r-ps                      1.4.0             r40h0eb13af_0    conda-forge
r-purrr                   0.3.4             r40hcdcec82_1    conda-forge
r-r6                      2.5.0             r40hc72bb7e_0    conda-forge
r-rappdirs                0.3.1           r40hcdcec82_1004    conda-forge
r-rcmdcheck               1.3.3             r40hc72bb7e_3    conda-forge
r-rcpp                    1.0.5             r40he524a50_0    conda-forge
r-recommended             4.0             r40hd8ed1ab_1004    conda-forge
r-remotes                 2.4.0             r40hc72bb7e_0    conda-forge
r-rex                     1.2.0             r40hc72bb7e_1    conda-forge
r-rlang                   0.4.8             r40h9e2df91_0    conda-forge
r-roxygen2                7.1.1             r40h0357c0b_0    conda-forge
r-rpart                   4.1_15            r40hcdcec82_2    conda-forge
r-rprojroot               2.0.2             r40hc72bb7e_0    conda-forge
r-rstudioapi              0.13              r40hc72bb7e_0    conda-forge
r-rversions               2.1.1             r40hc72bb7e_0    conda-forge
r-sessioninfo             1.1.1           r40hc72bb7e_1002    conda-forge
r-spatial                 7.3_12            r40hcdcec82_1    conda-forge
r-stringi                 1.5.3             r40h604b29c_0    conda-forge
r-stringr                 1.4.0             r40hc72bb7e_2    conda-forge
r-survival                3.2_7             r40hcdcec82_0    conda-forge
r-sys                     3.4               r40hcdcec82_0    conda-forge
r-testthat                2.3.2             r40h0357c0b_1    conda-forge
r-usethis                 2.0.1             r40hc72bb7e_0    conda-forge
r-whisker                 0.4               r40hc72bb7e_1    conda-forge
r-withr                   2.4.2             r40hc72bb7e_0    conda-forge
r-xfun                    0.19              r40h9e2df91_0    conda-forge
r-xml2                    1.3.2             r40h0357c0b_1    conda-forge
r-xopen                   1.0.0           r40hc72bb7e_1003    conda-forge
r-yaml                    2.2.1             r40hcdcec82_1    conda-forge
r-zip                     2.1.1             r40hcdcec82_0    conda-forge
readline                  8.0                  h7b6447c_0  
requests                  2.24.0                     py_0  
ruamel_yaml               0.15.87          py38h7b6447c_1  
sed                       4.8                  he412f7d_0    conda-forge
setuptools                50.3.1           py38h06a4308_1  
six                       1.15.0           py38h06a4308_0  
sqlite                    3.33.0               h62c20be_0  
tk                        8.6.10               hbc83047_0  
tktable                   2.10                 hb7b940f_3    conda-forge
tqdm                      4.51.0             pyhd3eb1b0_0  
urllib3                   1.25.11                    py_0  
wheel                     0.35.1             pyhd3eb1b0_0  
xorg-kbproto              1.0.7             h14c3975_1002    conda-forge
xorg-libice               1.0.10               h516909a_0    conda-forge
xorg-libsm                1.2.3             h84519dc_1000    conda-forge
xorg-libx11               1.6.12               h36c2ea0_0    conda-forge
xorg-libxau               1.0.9                h14c3975_0    conda-forge
xorg-libxdmcp             1.1.3                h516909a_0    conda-forge
xorg-libxext              1.3.4                h516909a_0    conda-forge
xorg-libxrender           0.9.10            h516909a_1002    conda-forge
xorg-renderproto          0.11.1            h14c3975_1002    conda-forge
xorg-xextproto            7.3.0             h14c3975_1002    conda-forge
xorg-xproto               7.0.31            h14c3975_1007    conda-forge
xz                        5.2.5                h7b6447c_0  
yaml                      0.2.5                h7b6447c_0  
zlib                      1.2.11               h7b6447c_3  
zstd                      1.4.5                h6597ccf_2    conda-forge
root@3f49d12504a3:/# R



Details about conda and system ( conda info ):
root@3f49d12504a3:/# conda info

     active environment : None
       user config file : /root/.condarc
 populated config files : 
          conda version : 4.10.3
    conda-build version : not installed
         python version : 3.8.5.final.0
       virtual packages : __linux=4.15.0=0
                          __glibc=2.31=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /opt/miniconda  (writable)
      conda av data dir : /opt/miniconda/etc/conda
  conda av metadata url : None
           channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
          package cache : /opt/miniconda/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/miniconda/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/4.10.3 requests/2.24.0 CPython/3.8.5 Linux/4.15.0-142-generic ubuntu/20.04.2 glibc/2.31
                UID:GID : 0:0
             netrc file : None
           offline mode : False


@jdblischak
Copy link
Member

@bainadeashish What is the value of of GIT_URL? I suspect the issue is that the URL is incorrect.

# setup
docker run -it --rm condaforge/mambaforge bash
mamba create -n issue-23 r-base=4.0.2 r-devtools
conda activate issue-23

# This works fine
Rscript -e 'devtools::install_git("https://github.com/Rdatatable/data.table.git")'

# An incorrect URL leads to an error
Rscript -e 'devtools::install_git("https//github.com/")'
## Error: Failed to install 'unknown package' from Git:
##   Error in 'git2r_remote_ls': unsupported URL protocol
## Execution halted

Environment (conda list):

$ conda list
# packages in environment at /opt/conda/envs/issue-23:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       1_gnu    conda-forge
_r-mutex                  1.0.1               anacondar_1    conda-forge
binutils_impl_linux-64    2.36.1               h193b22a_1    conda-forge
binutils_linux-64         2.36                hf3e587d_32    conda-forge
bwidget                   1.9.14               ha770c72_0    conda-forge
bzip2                     1.0.8                h7f98852_4    conda-forge
c-ares                    1.17.1               h7f98852_1    conda-forge
ca-certificates           2021.5.30            ha878542_0    conda-forge
cairo                     1.16.0            h9f066cc_1006    conda-forge
certifi                   2021.5.30        py39hf3d152e_0    conda-forge
curl                      7.76.1               h979ede3_1    conda-forge
fontconfig                2.13.1            hba837de_1005    conda-forge
freetype                  2.10.4               h0708190_1    conda-forge
fribidi                   1.0.10               h36c2ea0_0    conda-forge
gcc_impl_linux-64         7.5.0               habd7529_19    conda-forge
gcc_linux-64              7.5.0               h47867f9_32    conda-forge
gettext                   0.19.8.1          h0b5b191_1005    conda-forge
gfortran_impl_linux-64    7.5.0               h56cb351_19    conda-forge
gfortran_linux-64         7.5.0               h78c8a43_32    conda-forge
glib                      2.68.3               h9c3ff4c_0    conda-forge
glib-tools                2.68.3               h9c3ff4c_0    conda-forge
graphite2                 1.3.13            h58526e2_1001    conda-forge
gsl                       2.6                  he838d99_2    conda-forge
gxx_impl_linux-64         7.5.0               hd0bb8aa_19    conda-forge
gxx_linux-64              7.5.0               h555fc39_32    conda-forge
harfbuzz                  2.7.2                ha5b49bf_1    conda-forge
icu                       67.1                 he1b5a44_0    conda-forge
jbig                      2.1               h7f98852_2003    conda-forge
jpeg                      9d                   h36c2ea0_0    conda-forge
kernel-headers_linux-64   2.6.32              he073ed8_14    conda-forge
krb5                      1.17.2               h926e7f8_0    conda-forge
ld_impl_linux-64          2.36.1               hea4e1c9_1    conda-forge
lerc                      2.2.1                h9c3ff4c_0    conda-forge
libblas                   3.9.0                8_openblas    conda-forge
libcblas                  3.9.0                8_openblas    conda-forge
libcurl                   7.76.1               hc4aaa36_1    conda-forge
libdeflate                1.7                  h7f98852_5    conda-forge
libedit                   3.1.20191231         he28a2e2_2    conda-forge
libev                     4.33                 h516909a_1    conda-forge
libffi                    3.3                  h58526e2_2    conda-forge
libgcc-devel_linux-64     7.5.0               hda03d7c_19    conda-forge
libgcc-ng                 11.1.0               hc902ee8_0    conda-forge
libgfortran-ng            7.5.0               h14aa051_19    conda-forge
libgfortran4              7.5.0               h14aa051_19    conda-forge
libgit2                   1.1.0                h0b03e73_0    conda-forge
libglib                   2.68.3               h3e27bee_0    conda-forge
libgomp                   11.1.0               hc902ee8_0    conda-forge
libiconv                  1.16                 h516909a_0    conda-forge
liblapack                 3.9.0                8_openblas    conda-forge
libnghttp2                1.43.0               h812cca2_0    conda-forge
libopenblas               0.3.12          pthreads_hb3c22a3_1    conda-forge
libpng                    1.6.37               h21135ba_2    conda-forge
libssh2                   1.9.0                ha56f1ee_6    conda-forge
libstdcxx-devel_linux-64  7.5.0               hb016644_19    conda-forge
libstdcxx-ng              11.1.0               h56837e0_0    conda-forge
libtiff                   4.3.0                hf544144_1    conda-forge
libuuid                   2.32.1            h7f98852_1000    conda-forge
libwebp-base              1.2.0                h7f98852_2    conda-forge
libxcb                    1.13              h7f98852_1003    conda-forge
libxml2                   2.9.10               h68273f3_2    conda-forge
lz4-c                     1.9.3                h9c3ff4c_0    conda-forge
make                      4.3                  hd18ef5c_1    conda-forge
ncurses                   6.2                  h58526e2_4    conda-forge
openssl                   1.1.1k               h7f98852_0    conda-forge
pango                     1.42.4               h69149e4_5    conda-forge
pcre                      8.45                 h9c3ff4c_0    conda-forge
pcre2                     10.35                h032f7d1_2    conda-forge
pip                       21.1.3             pyhd8ed1ab_0    conda-forge
pixman                    0.40.0               h36c2ea0_0    conda-forge
pthread-stubs             0.4               h36c2ea0_1001    conda-forge
python                    3.9.6           h49503c6_1_cpython    conda-forge
python_abi                3.9                      2_cp39    conda-forge
r-askpass                 1.1               r40hcfec24a_2    conda-forge
r-assertthat              0.2.1             r40hc72bb7e_2    conda-forge
r-backports               1.2.1             r40hcfec24a_0    conda-forge
r-base                    4.0.2                he766273_1    conda-forge
r-base64enc               0.1_3           r40hcfec24a_1004    conda-forge
r-brew                    1.0_6           r40hc72bb7e_1003    conda-forge
r-brio                    1.1.2             r40hcfec24a_0    conda-forge
r-cachem                  1.0.5             r40hcfec24a_0    conda-forge
r-callr                   3.7.0             r40hc72bb7e_0    conda-forge
r-cli                     3.0.1             r40hc72bb7e_0    conda-forge
r-clipr                   0.7.1             r40hc72bb7e_0    conda-forge
r-commonmark              1.7             r40hcfec24a_1002    conda-forge
r-covr                    3.5.1             r40h03ef668_0    conda-forge
r-crayon                  1.4.1             r40hc72bb7e_0    conda-forge
r-credentials             1.3.0             r40hc72bb7e_0    conda-forge
r-crosstalk               1.1.1             r40hc72bb7e_0    conda-forge
r-curl                    4.3.2             r40hcfec24a_0    conda-forge
r-desc                    1.3.0             r40hc72bb7e_0    conda-forge
r-devtools                2.4.2             r40hc72bb7e_0    conda-forge
r-diffobj                 0.3.4             r40hcfec24a_0    conda-forge
r-digest                  0.6.27            r40h03ef668_0    conda-forge
r-dt                      0.18              r40hc72bb7e_0    conda-forge
r-ellipsis                0.3.2             r40hcfec24a_0    conda-forge
r-evaluate                0.14              r40hc72bb7e_2    conda-forge
r-fansi                   0.5.0             r40hcfec24a_0    conda-forge
r-fastmap                 1.1.0             r40h03ef668_0    conda-forge
r-fs                      1.5.0             r40h03ef668_0    conda-forge
r-gert                    1.3.1             r40hbd84cd2_0    conda-forge
r-gh                      1.3.0             r40hc72bb7e_0    conda-forge
r-git2r                   0.28.0            r40hf628c3e_0    conda-forge
r-gitcreds                0.1.1             r40hc72bb7e_0    conda-forge
r-glue                    1.4.2             r40hcfec24a_0    conda-forge
r-highr                   0.9               r40hc72bb7e_0    conda-forge
r-htmltools               0.5.1.1           r40h03ef668_0    conda-forge
r-htmlwidgets             1.5.3             r40hc72bb7e_0    conda-forge
r-httr                    1.4.2             r40hc72bb7e_0    conda-forge
r-ini                     0.3.1           r40hc72bb7e_1003    conda-forge
r-jsonlite                1.7.2             r40hcfec24a_0    conda-forge
r-knitr                   1.33              r40hc72bb7e_0    conda-forge
r-later                   1.2.0             r40h03ef668_0    conda-forge
r-lazyeval                0.2.2             r40hcfec24a_2    conda-forge
r-lifecycle               1.0.0             r40hc72bb7e_0    conda-forge
r-magrittr                2.0.1             r40hcfec24a_1    conda-forge
r-markdown                1.1               r40hcfec24a_1    conda-forge
r-memoise                 2.0.0             r40hc72bb7e_0    conda-forge
r-mime                    0.11              r40hcfec24a_0    conda-forge
r-openssl                 1.4.4             r40he36bf35_0    conda-forge
r-pillar                  1.6.1             r40hc72bb7e_0    conda-forge
r-pkgbuild                1.2.0             r40hc72bb7e_0    conda-forge
r-pkgconfig               2.0.3             r40hc72bb7e_1    conda-forge
r-pkgload                 1.2.1             r40h03ef668_0    conda-forge
r-praise                  1.0.0           r40hc72bb7e_1004    conda-forge
r-prettyunits             1.1.1             r40hc72bb7e_1    conda-forge
r-processx                3.5.2             r40hcfec24a_0    conda-forge
r-promises                1.2.0.1           r40h03ef668_0    conda-forge
r-ps                      1.6.0             r40hcfec24a_0    conda-forge
r-purrr                   0.3.4             r40hcfec24a_1    conda-forge
r-r6                      2.5.0             r40hc72bb7e_0    conda-forge
r-rappdirs                0.3.3             r40hcfec24a_0    conda-forge
r-rcmdcheck               1.3.3             r40hc72bb7e_3    conda-forge
r-rcpp                    1.0.7             r40h03ef668_0    conda-forge
r-rematch2                2.1.2             r40hc72bb7e_1    conda-forge
r-remotes                 2.4.0             r40hc72bb7e_0    conda-forge
r-rex                     1.2.0             r40hc72bb7e_1    conda-forge
r-rlang                   0.4.11            r40hcfec24a_0    conda-forge
r-roxygen2                7.1.1             r40h03ef668_0    conda-forge
r-rprojroot               2.0.2             r40hc72bb7e_0    conda-forge
r-rstudioapi              0.13              r40hc72bb7e_0    conda-forge
r-rversions               2.1.1             r40hc72bb7e_0    conda-forge
r-sessioninfo             1.1.1           r40hc72bb7e_1002    conda-forge
r-stringi                 1.5.3             r40hca8494e_0    conda-forge
r-stringr                 1.4.0             r40hc72bb7e_2    conda-forge
r-sys                     3.4               r40hcfec24a_0    conda-forge
r-testthat                3.0.4             r40h03ef668_0    conda-forge
r-tibble                  3.1.3             r40hcfec24a_0    conda-forge
r-usethis                 2.0.1             r40hc72bb7e_0    conda-forge
r-utf8                    1.2.1             r40hcfec24a_0    conda-forge
r-vctrs                   0.3.8             r40hcfec24a_1    conda-forge
r-waldo                   0.2.5             r40hc72bb7e_0    conda-forge
r-whisker                 0.4               r40hc72bb7e_1    conda-forge
r-withr                   2.4.2             r40hc72bb7e_0    conda-forge
r-xfun                    0.24              r40h03ef668_0    conda-forge
r-xml2                    1.3.2             r40h03ef668_1    conda-forge
r-xopen                   1.0.0           r40hc72bb7e_1003    conda-forge
r-yaml                    2.2.1             r40hcfec24a_1    conda-forge
r-zip                     2.2.0             r40hcfec24a_0    conda-forge
readline                  8.1                  h46c0cb4_0    conda-forge
sed                       4.8                  he412f7d_0    conda-forge
setuptools                49.6.0           py39hf3d152e_3    conda-forge
sqlite                    3.36.0               h9cd32fc_0    conda-forge
sysroot_linux-64          2.12                he073ed8_14    conda-forge
tk                        8.6.10               h21135ba_1    conda-forge
tktable                   2.10                 hb7b940f_3    conda-forge
tzdata                    2021a                he74cb21_1    conda-forge
wheel                     0.36.2             pyhd3deb0d_0    conda-forge
xorg-kbproto              1.0.7             h7f98852_1002    conda-forge
xorg-libice               1.0.10               h7f98852_0    conda-forge
xorg-libsm                1.2.3             hd9c2040_1000    conda-forge
xorg-libx11               1.7.2                h7f98852_0    conda-forge
xorg-libxau               1.0.9                h7f98852_0    conda-forge
xorg-libxdmcp             1.1.3                h7f98852_0    conda-forge
xorg-libxext              1.3.4                h7f98852_1    conda-forge
xorg-libxrender           0.9.10            h7f98852_1003    conda-forge
xorg-renderproto          0.11.1            h7f98852_1002    conda-forge
xorg-xextproto            7.3.0             h7f98852_1002    conda-forge
xorg-xproto               7.0.31            h7f98852_1007    conda-forge
xz                        5.2.5                h516909a_1    conda-forge
zlib                      1.2.11            h516909a_1010    conda-forge
zstd                      1.5.0                ha95c52a_0    conda-forge

Details about conda and system ( conda info ):
$ conda info

     active environment : issue-23
    active env location : /opt/conda/envs/issue-23
            shell level : 2
       user config file : /root/.condarc
 populated config files : /opt/conda/.condarc
          conda version : 4.10.3
    conda-build version : not installed
         python version : 3.9.6.final.0
       virtual packages : __linux=5.10.25=0
                          __glibc=2.31=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /opt/conda  (writable)
      conda av data dir : /opt/conda/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
          package cache : /opt/conda/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/conda/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/4.10.3 requests/2.26.0 CPython/3.9.6 Linux/5.10.25-linuxkit ubuntu/20.04.2 glibc/2.31
                UID:GID : 0:0
             netrc file : None
           offline mode : False

@bainadeashish
Copy link
Author

bainadeashish commented Jul 24, 2021

no value of GIT_URL is correct, same is working fine with cran devtools but fails in r-devtools conda.
@jdblischak

@jdblischak
Copy link
Member

no value of GIT_URL is correct, same is working fine with cran devtools but fails in r-devtools conda.

We need a minimal reproducible example to be able to troubleshoot the issue you are having. Could you please run the code below and report back whether or not it successfully runs for you?

conda create --yes -n test-install-git --override-channels -c conda-forge r-base=4.0.2 r-devtools
conda activate test-install-git
Rscript -e 'devtools::install_git("https://github.com/HenrikBengtsson/R.utils")'
conda deactivate

@bainadeashish
Copy link
Author

@jdblischak let me try & will update accordingly.
Thanks alot

@bainadeashish
Copy link
Author

bainadeashish commented Jul 28, 2021

Its working fine for URL you mentioned but somehow its failing for below URL
Step 24/40 : RUN Rscript -e 'devtools::install_git("https://gitlab+deploy-token-49:MVJMoJQbGThZbdzEb@GIT_REPO.git")'
---> Running in 8b5f6302861e
WARNING: ignoring environment value of R_HOME
Error: Failed to install 'unknown package' from Git:
Error in 'git2r_remote_ls': malformed URL 'https://gitlab+deploy-token-49:MVJMoJQbGThZbdzEb'

Replaced actual repo name with GIT_REPO due to security issues.

@jdblischak
Copy link
Member

Its working fine for URL you mentioned but somehow its failing for below URL

OK, great. Thanks for confirming. This is a good sign. It will work for the most standard use case of installing from a public repo.

Error in 'git2r_remote_ls': malformed URL 'https://gitlab+deploy-token-49:MVJMoJQbGThZbdzEb'

I don't have any experience with authenticating with a GitLab deploy token. This URL works with devtools installed from CRAN? If yes, my only guess is that there is some difference in the authentication features when installing libgit2. Can you try running git2r::libgit2_features() with both your CRAN setup and in your conda environment? Are there are any differences in the enabled features?

Some other ideas to consider:

  1. What happens if you try setting git = "external"? This should use your system Git instead of git2r (which is where the error is coming from). If you don't have Git installed, you can run conda install git.

  2. If you need to use private repos on GitLab, I'd recommend generating a GitLab PAT, saving it in the environment variable GITHUB_PAT, and then installing with install_gitlab()

  3. There's nothing particularly special about install_git(). If you're having trouble getting it to authenticate with your URL, you can clone it and then install it

    git clone https://gitlab+deploy-token-49:MVJMoJQbGThZbdzEb@GIT_REPO.git
    Rscript -e 'devtools::install("GIT_REPO")'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants