commit with record_iter_changes should support exclude

Bug #403811 reported by Jelmer Vernooij on 2009-07-24
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bazaar
Medium
Unassigned
Breezy
High
Jelmer Vernooij
bzr (Debian)
Confirmed
Unknown

Bug Description

Debian Bug report logs - #531128
bzr-git: Using bzr ci -x results in backtrace (without -x works)
version graph

Package: bzr-git; Maintainer for bzr-git is Debian Bazaar Maintainers <email address hidden>; Source for bzr-git is bzr-git.

Reported by: Karl Goetz <email address hidden>

Date: Sat, 30 May 2009 07:12:02 UTC

Severity: normal

Tags: confirmed

Found in version 0.3.2

Reply or subscribe to this bug.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox
Report forwarded to <email address hidden>, Debian Bazaar Maintainers <email address hidden>:
Bug#531128; Package bzr-git. (Sat, 30 May 2009 07:12:04 GMT) Full text and rfc822 format available.
Acknowledgement sent to Karl Goetz <email address hidden>:
New Bug report received and forwarded. Copy sent to Debian Bazaar Maintainers <email address hidden>. (Sat, 30 May 2009 07:12:04 GMT) Full text and rfc822 format available.

Message #5 received at <email address hidden> (full text, mbox):

From: Karl Goetz <email address hidden>
To: Debian Bug Tracking System <email address hidden>
Subject: bzr-git: Using bzr ci -x results in backtrace (without -x works)
Date: Sat, 30 May 2009 16:36:51 +0930

Package: bzr-git
Version: 0.3.2
Severity: normal

I'm attempting to work on the Debian freeciv maintainance git repo. I'm doing the work in a vserver running sid, but reporting this bug from the host running lenny.

I've copied a heap of modified files into the repository from before I did a checkout, and I'd like to /not/ commit the debian/* directory with all the other files.

This succeeds:
 sidvs:~/freeciv-dco# bzr ci --show-diff

This crashes:
 sidvs:~/freeciv-dco# bzr ci --show-diff -x debian/

Here is the backtrace (I have trimmed all the 'modified's)

modified utility/Makefile.am
modified utility/Makefile.in
modified utility/hash.c
modified utility/hash.h
modified utility/timing.c
aborting commit write group: BzrCommandError(empty commit message specified)
bzr: ERROR: empty commit message specified
sidvs:~/freeciv-dco# bzr ci --show-diff -x debian/
Committing to: /root/freeciv-dco/.git/
aborting commit write group: NotImplementedError(<bound method GitCommitBuilder.record_entry_contents of <bzrlib.plugins.git.commit.GitCommitBuilder object at 0x9f4b18c>>,)
bzr: ERROR: exceptions.NotImplementedError: <bound method GitCommitBuilder.record_entry_contents of <bzrlib.plugins.git.commit.GitCommitBuilder object at 0x9f4b18c>>

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 729, in exception_to_return_code
    return the_callable(*args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 924, in run_bzr
    ret = run(*run_argv)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 560, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/usr/lib/python2.5/site-packages/bzrlib/builtins.py", line 2932, in run
    exclude=safe_relpath_files(tree, exclude))
  File "/usr/lib/python2.5/site-packages/bzrlib/decorators.py", line 192, in write_locked
    result = unbound(self, *args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/mutabletree.py", line 228, in commit
    *args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 363, in commit
    self._update_builder_with_changes()
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 648, in _update_builder_with_changes
    self._populate_from_inventory()
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 860, in _populate_from_inventory
    content_summary)
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 904, in _record_entry
    ie, self.parent_invs, path, self.work_tree, content_summary)
  File "/usr/lib/python2.5/site-packages/bzrlib/plugins/git/commit.py", line 52, in record_entry_contents
    raise NotImplementedError(self.record_entry_contents)
NotImplementedError: <bound method GitCommitBuilder.record_entry_contents of <bzrlib.plugins.git.commit.GitCommitBuilder object at 0x9f4b18c>>

bzr 1.15rc1 on python 2.5.4 (linux2)
arguments: ['/usr/bin/bzr', 'ci', '--show-diff', '-x', 'debian/']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'en_AU.UTF-8'
plugins:
  bzrtools /usr/lib/python2.5/site-packages/bzrlib/plugins/bzrtools [1.15]
  git /usr/lib/python2.5/site-packages/bzrlib/plugins/git [0.3.2]
  launchpad /usr/lib/python2.5/site-packages/bzrlib/plugins/launchpad [1.15rc1]
  netrc_credential_store /usr/lib/python2.5/site-packages/bzrlib/plugins/netrc_credential_store [1.15rc1]
*** Bazaar has encountered an internal error.
    Please report a bug at https://bugs.launchpad.net/bzr/+filebug
    including this traceback, and a description of what you
    were doing when the error occurred.
sidvs:~/freeciv-dco#

-- System Information:
Debian Release: squeeze/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.26-2-vserver-686 (SMP w/1 CPU core)
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Information forwarded to <email address hidden>, Debian Bazaar Maintainers <email address hidden>:
Bug#531128; Package bzr-git. (Sat, 30 May 2009 07:36:06 GMT) Full text and rfc822 format available.
Acknowledgement sent to Karl Goetz <email address hidden>:
Extra info received and forwarded to list. Copy sent to Debian Bazaar Maintainers <email address hidden>. (Sat, 30 May 2009 07:36:06 GMT) Full text and rfc822 format available.

Message #10 received at <email address hidden> (full text, mbox):

From: Karl Goetz <email address hidden>
To: <email address hidden>
Subject: Re: bzr-git: Using bzr ci -x results in backtrace (without -x
 works)
Date: Sat, 30 May 2009 16:53:01 +0930

[Message part 1 (text/plain, inline)]

On Sat, 30 May 2009 16:36:51 +0930
Karl Goetz <email address hidden> wrote:

> Package: bzr-git
> Version: 0.3.2
> Severity: normal
>
>
> I'm attempting to work on the Debian freeciv maintainance git repo.
> I'm doing the work in a vserver running sid, but reporting this bug
> from the host running lenny.
>
> I've copied a heap of modified files into the repository from before
> I did a checkout, and I'd like to /not/ commit the debian/* directory
> with all the other files.
>
> This succeeds:
> sidvs:~/freeciv-dco# bzr ci --show-diff
>
> This crashes:
> sidvs:~/freeciv-dco# bzr ci --show-diff -x debian/
>

I'm sorry, I seem to have not debugged correctly. Dont know if this is
good or bad news, but this will also cause a crash:
 sidvs:~/freeciv-dco# bzr ci --show-diff debian/

sidvs:~/freeciv-dco# bzr ci --show-diff debian/
Committing
to: /root/freeciv-dco/.git/ aborting commit write group:
NotImplementedError(<bound method
GitCommitBuilder.record_entry_contents of
<bzrlib.plugins.git.commit.GitCommitBuilder object at 0x9c7d18c>>,)
bzr: ERROR: exceptions.NotImplementedError: <bound method
GitCommitBuilder.record_entry_contents of
<bzrlib.plugins.git.commit.GitCommitBuilder object at 0x9c7d18c>>

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 729,
in exception_to_return_code return the_callable(*args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 924,
in run_bzr ret = run(*run_argv)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 560,
in run_argv_aliases return self.run(**all_cmd_args)
  File "/usr/lib/python2.5/site-packages/bzrlib/builtins.py", line
2932, in run exclude=safe_relpath_files(tree, exclude))
  File "/usr/lib/python2.5/site-packages/bzrlib/decorators.py", line
192, in write_locked result = unbound(self, *args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/mutabletree.py", line
228, in commit *args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 363,
in commit self._update_builder_with_changes()
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 648,
in _update_builder_with_changes self._populate_from_inventory()
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 860,
in _populate_from_inventory content_summary)
  File "/usr/lib/python2.5/site-packages/bzrlib/commit.py", line 904,
in _record_entry ie, self.parent_invs, path, self.work_tree,
content_summary) File
"/usr/lib/python2.5/site-packages/bzrlib/plugins/git/commit.py", line
52, in record_entry_contents raise
NotImplementedError(self.record_entry_contents) NotImplementedError:
<bound method GitCommitBuilder.record_entry_contents of
<bzrlib.plugins.git.commit.GitCommitBuilder object at 0x9c7d18c>>

bzr 1.15rc1 on python 2.5.4 (linux2)
arguments: ['/usr/bin/bzr', 'ci', '--show-diff', 'debian/']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'en_AU.UTF-8'
plugins:
  bzrtools /usr/lib/python2.5/site-packages/bzrlib/plugins/bzrtools
[1.15]
git /usr/lib/python2.5/site-packages/bzrlib/plugins/git
[0.3.2]
launchpad /usr/lib/python2.5/site-packages/bzrlib/plugins/launchpad
[1.15rc1]
netrc_credential_store /usr/lib/python2.5/site-packages/bzrlib/plugins/netrc_credential_store
[1.15rc1] *** Bazaar has encountered an internal error. Please report a
bug at https://bugs.launchpad.net/bzr/+filebug including this
traceback, and a description of what you were doing when the error
occurred.

--
Karl Goetz, (Kamping_Kaiser / VK5FOSS)

[signature.asc (application/pgp-signature, attachment)]

Information forwarded to <email address hidden>, Debian Bazaar Maintainers <email address hidden>:
Bug#531128; Package bzr-git. (Sun, 31 May 2009 23:15:03 GMT) Full text and rfc822 format available.
Acknowledgement sent to Jelmer Vernooij <email address hidden>:
Extra info received and forwarded to list. Copy sent to Debian Bazaar Maintainers <email address hidden>. (Sun, 31 May 2009 23:15:03 GMT) Full text and rfc822 format available.

Message #15 received at <email address hidden> (full text, mbox):

From: Jelmer Vernooij <email address hidden>
To: <email address hidden>
Cc: <email address hidden>
Subject: Confirmed
Date: Mon, 1 Jun 2009 01:03:12 +0200

tags 531128 +confirmed
thanks

This is a known bug in bzr-git. Bazaar currently requires commit
builders to provide two code paths, one based around
``record_iter_changes'' and one around ``record_entry_contents''. The
first is already used in simple cases and the latter will be removed
at some point in the future in favor of the first.

bzr-git only implements ``record_iter_changes'' and at the moment the
plan is to just wait for Bazaar to switch to using that for all
commits, rather than spending time implementing
``record_entry_contents''.

Tags added: confirmed Request was from Jelmer Vernooij <email address hidden> to <email address hidden>. (Sun, 31 May 2009 23:15:04 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.
Debian bug tracking system administrator <email address hidden>. Last modified: Sun Jul 19 22:41:19 2009; Machine Name: rietz.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.

Related branches

Jelmer Vernooij (jelmer) on 2009-07-24
Changed in bzr-git:
status: New → Triaged
importance: Undecided → Low
Jelmer Vernooij (jelmer) on 2010-08-14
tags: added: git-workingtree
Jelmer Vernooij (jelmer) on 2011-03-23
affects: bzr-git → bzr
Changed in bzr:
importance: Low → Medium
status: Triaged → Confirmed
summary: - bzr-git: Using bzr ci -x results in backtrace (without -x works)
+ commit with record_iter_changes should support exclude
tags: added: commit exclude foreign
removed: git-workingtree
Changed in bzr (Debian):
status: Unknown → Confirmed
Jelmer Vernooij (jelmer) on 2017-06-16
Changed in brz:
status: New → Triaged
importance: Undecided → High
Jelmer Vernooij (jelmer) on 2017-06-16
Changed in brz:
assignee: nobody → Jelmer Vernooij (jelmer)
Jelmer Vernooij (jelmer) on 2017-06-20
Changed in brz:
milestone: none → 3.0.0
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.