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
My submodule was added for a non-default branch. The "in" script calls:
git submodule update --init --no-fetch--depth=1 $submodule_parameters "$submodule_path"
Without --no-fetch git additionally fetches the necessary commit and because the repo is already shallow this commit is also fetched in a shallow manner. By the time deepen_shallow_clone_until_ref_is_found_then_check_out is called there are two shallow heads: the default branch head and the recorded submodule. Perhaps the authors wanted to have a connected history between the remote branch head and the recorded commit. If you remove "--no-fetch" the two shallow commits will be disconnected from each other even if they belong to the same remote branch, but I think it's an acceptable tradeoff. Also, the custom deepen command won't be necessary after that.
I have this problem on a Concourse server and it's reproducible with the latest in script when I just type commands in terminal.
Describe the bug
My submodule was added for a non-default branch. The "in" script calls:
git submodule update --init --no-fetch --depth=1 $submodule_parameters "$submodule_path"
With git version 2.45.1 this effectively, creates a shallow clone of the default branch and then calls deepen_shallow_clone_until_ref_is_found_then_check_out 1 ref which is of no help here because it doesn't pass
$ref
when it callsget fetch
.Without --no-fetch git additionally fetches the necessary commit and because the repo is already shallow this commit is also fetched in a shallow manner. By the time
deepen_shallow_clone_until_ref_is_found_then_check_out
is called there are two shallow heads: the default branch head and the recorded submodule. Perhaps the authors wanted to have a connected history between the remote branch head and the recorded commit. If you remove "--no-fetch" the two shallow commits will be disconnected from each other even if they belong to the same remote branch, but I think it's an acceptable tradeoff. Also, the custom deepen command won't be necessary after that.I have this problem on a Concourse server and it's reproducible with the latest
in
script when I just type commands in terminal.Reproduction steps
Output:
Expected behavior
no error
Additional context
No response
The text was updated successfully, but these errors were encountered: