From: brian m. carlson Date: Sat, 15 Nov 2025 20:14:17 GMT Subject: Re: git fails to checkout SHA1 submodule in SHA256 repo with --depth=1 Message-ID: In-Reply-To: On 2025-11-14 at 22:55:07, Marc Branchaud wrote: > Set up SHA256 mirrors of the SHA1 repos you want to track in submodules? > > I'm assuming that it would be easy to keep such mirrors up to date. I'm not > familiar enough with Brian's work to know if a SHA256 repo can have > a SHA1 remote (which would mean that updates would just be a simple "git > fetch origin"), but even if that's not possible I'm guessing that scripting > some kind of regularly-run translation of new commits wouldn't be too hard. You can set up a repository which supports both algorithms (for instance, a SHA-256 main algorithm and SHA-1 compatibility) and then interoperate with both algorithms, so yes, this is possible and it really is as easy as `git fetch origin` once set up. The current constraint is that the cloned repository must be a full clone (not shallow or partial) and it must not have any submodules itself. Of course, that's what the interoperability work does and it's not finished or even mostly upstreamed. As I said, it's mostly functional, but it's not production ready. It also fails many tests because we have many tests in our testsuite that require partial or shallow clones, whose support is in progress. -- brian m. carlson (they/them) Toronto, Ontario, CA