On Sat, Sep 05, 2026 at 07:55:27PM +0200, Agustin Martin wrote: > On Wed, Aug 26, 2026 at 12:25:01AM +0900, Simon Richter wrote: > > Package: devscripts > > Version: 2.26.11~bpo13+1 > > Severity: normal > > X-Debbugs-Cc: [email protected] > > > > I have upstream's git repository configured as a remote in my work tree. > > Upstream uses submodules, which get squashed into a single archive by > > uscan, and that archive is imported into the git repo for the packages. > > > > As a result, when uscan is run, the checked out branch (with the > > debian/watch file) does not have submodules. uscan detects that a remote > > for the upstream git exists in the current repository, and tries to reuse > > that, which is commendable, but fails to do so: > > > > $ git clone https://salsa.debian.org/electronics-team/nextpnr.git > > $ cd nextpnr > > $ git remote add yosys https://github.com/YosysHQ/nextpnr.git
Hi, Cc'ing Hugh McMaster, who did a lot of work in this section in case he can add something. > I tried to manually run what uscan is actually doing in this case (seen > using uscan -vv) after above three commands are issued, only with commands > needed to get result (no tags searching, I already know the result). > > $ git fetch --recurse-submodules yosys > $ git archive --format=tar --prefix=nextpnr-0.11.1/ > --output=/home/myuser/src/nextpnr-0.11.1.tar refs/tags/nextpnr-0.11.1 > $ git submodule --quiet foreach 'echo $name' > > git archive creates the base tarball, without modules, but "git submodule > --quiet foreach ..." above gives no result. "git submodule" also gives no > result. submodules are defined in .gitmodules, but repo seems to not know > about them. > > $ git submodule --quiet deinit -- > > fatal: Use '--all' if you really want to deinitialize all submodules > > Above error seems caused when deinit command is called on empty > @sm_deinit. While that can be easily hidden, may be that would hide an > actual problem. > > After this, git submodule foreach --recursive 'git archive ...' on > submodules does nothing, so nothing is added to tarball. > > When no upstream remote is configured, upstream repo is cloned and all the > work is done in that cloned repo, apparently working as expected. I kept trying to understand when this happens, and noticed that submodules are not initialized when cloning from salsa Debian repo, but they are when cloning from upstream repo. # Does not work with salsa repo. Submodules not initialized $ git clone https://salsa.debian.org/electronics-team/nextpnr.git $ cd nextpnr $ git submodule update --init --recursive -- 3rdparty/corrosion himbaechel/uarch/xilinx/meta tests # Works with upstream repo. Submodules are initialized. $ git clone https://github.com/YosysHQ/nextpnr.git $ cd nextpnr $ git submodule update --init --recursive -- 3rdparty/corrosion himbaechel/uarch/xilinx/meta tests This seems to be the origin of the problem. When a remote is defined, local repo is used and submodules are not used since they are not initialized. When no remote is defined, upstream repo is used and submodules are initialized and used. Do not understand why this is happening. Hope this helps in some way. Regards, --- Agustin

