Unable to clone vg recursively
1. What were you trying to do?
git clone --recursive https://github.com/vgteam/vg.git
2. What did you want to happen? Have a clone of the repository and its submodules
3. What actually happened? Got the following errors:
Unable to checkout '26a940cdf3eb25974be7c49f598c2dd99e6ecf95' in submodule path 'deps/gbwtgraph'
Unable to checkout '0b01ccf90905bb664e4242967c01adcb24299111' in submodule path 'deps/vcflib'
Following the gbwtgraph or vcflib links in the deps directory of the master branch using Github results in an error message like this: This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. (Apparently this is the reason.)
Doing git submodule update --init --recursive after checking out v1.62.0 results in the same error. Only vcflib fails to update after checking out v1.61.0, v1.60.0 or v1.59.0. I did not test with any other versions.
Checking out the tip of the master branch of vcflib/vcflib causes the build process to fail since in the version in question, vcflib::Variant lacks some data members and member functions utilised by vg::Constructor (namely canonical, canonicalizable() and canonicalize()).
I don't have permission to fix those repos, and I think both @adamnovak and @jltsiren are on vacation now. In the meantime, you can try checking out the forks with those commits on them. I think I found the right ones
For gbwtgraph: https://github.com/adamnovak/gbwtgraph/tree/haplotype-subrange-gbwt For vcflib: https://github.com/vgteam/vcflib/tree/fix-mac
Here's a PR to bring the commits we need into gbwtgraph: https://github.com/jltsiren/gbwtgraph/pull/43
For vcflib we probably should see if their current mainline has fixed the problems we were having, and break out anything we have that they don't into specific PRs.
But we've been pointing at that Git commit for vcflib for years and I've never noticed a problem with fresh recursive clones. I just ran git clone --recursive https://github.com/vgteam/vg.git on git version 2.39.5 (Apple Git-154) and I wasn't able to reproduce the problem. Maybe it is Git version specific? Or something to do with Git's config? Or maybe Github is inconsistent on what commits it wants to serve to who from what endpoints?
Here's a PR to put just about the only thing we have that upstream vcflib doesn't have into upstream vcflib: https://github.com/vcflib/vcflib/pull/410
Maybe it is Git version specific?
Apparently this was the case. I was trying to compile vg for an old version of Ubuntu (due to reasons) and ended up using an old version of git. Obviously I should have tested with a newer version. Thank you for checking this.