Source: dgit
Version: 8.4
Severity: normal

I tried to upload the current state of
https://salsa.debian.org/pkg-debconf/debconf using dgit (commit
48c5ce38cfd5d4679ddb2d7c60d7f85833b4a501 with an extra "dch -r &&
debcommit -r" on the end).  I got the following output:

  $ dgit -L push-source
  DAMP RUN - WILL MAKE LOCAL (UNSIGNED) CHANGES
  canonical suite name for unstable is sid
  dpkg-source: info: using source format '3.0 (native)'
  dpkg-source: info: building debconf in debconf_1.5.72.tar.xz
  dpkg-source: info: building debconf in debconf_1.5.72.dsc
  changelog will contain changes since 1.5.71
  dpkg-genchanges: info: including full source code in upload
  downloading 
http://ftp.debian.org/debian//pool/main/d/debconf/debconf_1.5.71.dsc...
  last upload to archive: NO git hash
  using existing debconf_1.5.71.tar.xz
  dpkg-source: info: extracting debconf in debconf-1.5.71
  dpkg-source: info: unpacking debconf_1.5.71.tar.xz
  synthesised git commit from .dsc 1.5.71
  
  dgit: error: dgit push: HEAD is not a descendant of the archive's version.
  dgit: To overwrite the archive's contents, pass --overwrite[=VERSION].
  dgit: To rewind history, if permitted by the archive, use 
--deliberately-not-fast-forward.
  ! Push failed, while preparing your push.
  ! You can retry the push, after fixing the problem, if you like.

debconf had previously been uploaded using dgit, back at version 1.5.53.
The current HEAD of https://browse.dgit.debian.org/debconf.git/ is
c5cd2f6ae316f9f928ad094a9dcdd8a7f020d8b2, which is a direct ancestor of
my current master branch tip.

I therefore went and read the documentation for these options to try to
understand what I should do.

--overwrite looks sort of right, but it gives the example of having
incorporated NMU changes which isn't my situation, nor is it true that
this is the first time the package has been pushed using "dgit push" to
the suite in question.  And it tells me that it's going to make a
pseudo-merge, which doesn't seem like what I want because the version in
the archive already has an exact representation in my branch: I have a
dgit/dgit/sid ref here whose tree is identical to my 1.5.71 tag,
although the history is synthetic.

--deliberately-not-fast-forward seems only dubiously appropriate,
because I'm not rewinding history.  The version in the archive is
1.5.71, which is a direct ancestor of what I'm trying to upload and has
an exact representation in my branch's history.  HEAD of
https://browse.dgit.debian.org/debconf.git/ is also a direct ancestor of
what I'm trying to upload.  Does it actually mean that my branch isn't
fast-forwarding from the synthetic representation of 1.5.71 that dgit
constructed, because 1.5.71 wasn't uploaded using dgit?

Ideally I'd like dgit to notice that the history of my branch in fact
has everything it needs (as in, there's a commit there that has a tree
identical to what's currently in the archive) even though the uploads
between 1.5.53 and now weren't made using dgit.  But maybe I
misunderstand something?  Is it OK for me to use
--deliberately-not-fast-forward in this situation, which seems ideal
from my point of view?  If so it would perhaps be helpful for the
documentation to say a bit more about this situation, because it seems
that it must be somewhat common for some maintainers of a package to use
dgit and some not, and this is exactly the kind of situation that arises
from that.

Thanks,

-- 
Colin Watson                                       [cjwat...@debian.org]

Reply via email to