You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
context
For my company, I need to automate some git workflows where we need to manage git submodules. This has to be done from within a wider R project and using HTTP only (SSH is not implemented and the IT department is not ready to make it work due to reverse proxy complications...).
objective
Create a git repo, add a submodule with the content of its nested submodules (see reprex here below)
problem
My problem is that I encounter en error while using gert::git_submodule_update if interacting with my company's gitlab instance :
Error in libgit2::git_submodule_update :
request failed with status code: 401
This error does not arrise if executing git submodule update --init from git bash
I don't encounter any error while using other gert functions that require auth like gert::git_clone or gert::git_pull for example. The error is only relative to gert::git_submodule_update
If trying to do the same operation with a github hosted dummy example, everything works fine with HTTP (see reprex here below).
Please also note that calling a system or sys::exec_wait or system2 function and passing it the args to build git submodule update --init command is not considered as a solution as the R script might be called by some user from within KNIME (an opensource ETL tool) with which, I had no success to make a system call to execute a git submodule update --init command working (which might be a clue for some credentials problems?).
reprex
The script here below should :
create an empty git repo,
add the repo https://github.com/pokyah/test_gert_submodule_l1 that contains a submodule test_gert_submodule_l2 as a subrepo
and pull the content of the nested submodule test_gert_submodule_l2
If everything works fine there should be a goodbye.R file into the nested test_gert_submodule_l2 folder
Do you have any idea of what could explain why gert:::git_submodule_update does not work with a specific gitlab instance?
In https://github.com/r-lib/gert/blob/main/R/submodules.R you mention in the function comment :
# I find this confusing, also doesn't support auth.
# Better use git_submodule_fetch()
What does it really mean ?
If we could get more information about this problem, this could help us automate our git workflows within our R project and maybe help us understand my git submodule update --init command called from a system call within KNIME does not work neither.
Hi,
context
For my company, I need to automate some git workflows where we need to manage git submodules. This has to be done from within a wider R project and using HTTP only (SSH is not implemented and the IT department is not ready to make it work due to reverse proxy complications...).
objective
Create a git repo, add a submodule with the content of its nested submodules (see reprex here below)
problem
My problem is that I encounter en error while using
gert::git_submodule_update
if interacting with my company's gitlab instance :This error does not arrise if executing
git submodule update --init
from git bashI don't encounter any error while using other gert functions that require auth like
gert::git_clone
orgert::git_pull
for example. The error is only relative togert::git_submodule_update
If trying to do the same operation with a github hosted dummy example, everything works fine with HTTP (see reprex here below).
Please also note that calling a
system
orsys::exec_wait
orsystem2
function and passing it the args to buildgit submodule update --init
command is not considered as a solution as the R script might be called by some user from within KNIME (an opensource ETL tool) with which, I had no success to make a system call to execute agit submodule update --init
command working (which might be a clue for some credentials problems?).reprex
The script here below should :
https://github.com/pokyah/test_gert_submodule_l1
that contains a submoduletest_gert_submodule_l2
as a subrepotest_gert_submodule_l2
If everything works fine there should be a
goodbye.R
file into the nestedtest_gert_submodule_l2
folderquestion
Do you have any idea of what could explain why
gert:::git_submodule_update
does not work with a specific gitlab instance?In https://github.com/r-lib/gert/blob/main/R/submodules.R you mention in the function comment :
What does it really mean ?
If we could get more information about this problem, this could help us automate our git workflows within our R project and maybe help us understand my
git submodule update --init
command called from a system call within KNIME does not work neither.session info
Many thanks for your support.
Best regards
The text was updated successfully, but these errors were encountered: