Package: git-buildpackage
Version: 0.9.25
Severity: normal

Hi,

I just uploaded a stable update for ruby-httpclient. Since the bullseye
branch was created, a new upstream release has been uploaded to sid,
thus upstream and pristine-tar had moved on. `gbp push` then fails like
this:

----------------8<----------------8<----------------8<-----------------
gbp:info: Tagging Debian package 2.8.3-3+deb11u1 as debian/2.8.3-3+deb11u1 in 
git
gbp:info: Pushing debian/2.8.3-3+deb11u1 to origin
gbp:info: Pushing upstream/2.8.3 to origin
gbp:info: Pushing refs/heads/debian/bullseye to 
origin:refs/heads/debian/bullseye
gbp:info: Pushing 0d9e030d58de2a5c9b64adc5ca1571f1aa1b81bc to 
origin:refs/heads/upstream
gbp:error: Error running git push: To 
salsa.debian.org:ruby-team/ruby-httpclient.git
 ! [rejected]        0d9e030d58de2a5c9b64adc5ca1571f1aa1b81bc -> upstream 
(non-fast-forward)
error: failed to push some refs to 
'salsa.debian.org:ruby-team/ruby-httpclient.git'
hint: Updates were rejected because a pushed branch tip is behind its remote
hint: counterpart. Check out this branch and integrate the remote changes
hint: (e.g. 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
gbp:info: Pushing 6a9377d36b2e2247621033196efc88c36004e940 to 
origin:refs/heads/pristine-tar
gbp:error: Error running git push: To 
salsa.debian.org:ruby-team/ruby-httpclient.git
 ! [rejected]        6a9377d36b2e2247621033196efc88c36004e940 -> pristine-tar 
(non-fast-forward)
error: failed to push some refs to 
'salsa.debian.org:ruby-team/ruby-httpclient.git'
hint: Updates were rejected because a pushed branch tip is behind its remote
hint: counterpart. Check out this branch and integrate the remote changes
hint: (e.g. 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
gbp:error: Failed to push some refs.
----------------8<----------------8<----------------8<-----------------

Looking at the case for the upstream branch, it's trying to push commit
0d9e030d58de2a5c9b64adc5ca1571f1aa1b81bc. That commit was already
present in the corresponding remote branch, but there was a newer
commit on top of that. The same situation happends with the pristine-tar
branch.

Maybe gbp push could detect that the corresponding upstream/pristine-tar
commits is are already present at the remote branch, and skip the push.


-- System Information:
Debian Release: bookworm/sid
  APT prefers testing-debug
  APT policy: (900, 'testing-debug'), (900, 'testing'), (500, 
'unstable-debug'), (500, 'unstable'), (1, 'experimental-debug'), (1, 
'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 5.15.0-2-amd64 (SMP w/4 CPU threads)
Locale: LANG=pt_BR.UTF-8, LC_CTYPE=pt_BR.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages git-buildpackage depends on:
ii  devscripts             2.21.6
ii  git                    1:2.33.0-1
ii  man-db                 2.9.4-2
ii  python3                3.9.7-1
ii  python3-dateutil       2.8.1-6
ii  python3-pkg-resources  58.2.0-1
ii  sensible-utils         0.0.17

Versions of packages git-buildpackage recommends:
ii  cowbuilder        0.89
ii  pbuilder          0.231
ii  pristine-tar      1.49
ii  python3-requests  2.25.1+dfsg-2
ii  sbuild            0.81.2

Versions of packages git-buildpackage suggests:
pn  python3-notify2  <none>
ii  sudo             1.9.5p2-3
ii  unzip            6.0-26

-- no debconf information

Attachment: signature.asc
Description: PGP signature

Reply via email to