bzr crashing when trying to commit to the APT repository

Bug #182477 reported by Christian Perrier
4
Affects Status Importance Assigned to Milestone
Bazaar
Invalid
Undecided
Unassigned

Bug Description

I have a local copy of the APT development tree where I maintain APT translations for Debian/Ubuntu:

This copy is synced with http://bzr.debian.org/apt/debian-sid/

Today, I changed some PO files locally before running "bzr update". So I finally ran it, then tried to "bzr commit". That gave this interesting result:

bubulle@mykerinos:~/src/debian/apt/bzr/debian-sid> bzr commit
Committing to: bzr+ssh://bzr.debian.org/bzr/apt/debian-sid/
modified po/ChangeLog
modified po/apt-all.pot
bzr: ERROR: bzrlib.errors.ShortReadvError: readv() read 21852 bytes rather than 22019 bytes at 45403 for "6a/ar.po-20061128205858-10pdyt0tb0x25d15-1.knit"

Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/bzrlib/commands.py", line 806, in run_bzr_catch_errors
    return run_bzr(argv)
  File "/usr/lib/python2.4/site-packages/bzrlib/commands.py", line 762, in run_bzr
    ret = run(*run_argv)
  File "/usr/lib/python2.4/site-packages/bzrlib/commands.py", line 492, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/usr/lib/python2.4/site-packages/bzrlib/builtins.py", line 2328, in run
    author=author)
  File "/usr/lib/python2.4/site-packages/bzrlib/decorators.py", line 165, in write_locked
    return unbound(self, *args, **kwargs)
  File "/usr/lib/python2.4/site-packages/bzrlib/workingtree_4.py", line 246, in commit
    result = WorkingTree3.commit(self, message, revprops, *args, **kwargs)
  File "/usr/lib/python2.4/site-packages/bzrlib/decorators.py", line 165, in write_locked
    return unbound(self, *args, **kwargs)
  File "/usr/lib/python2.4/site-packages/bzrlib/mutabletree.py", line 187, in commit
    revprops=revprops, *args, **kwargs)
  File "/usr/lib/python2.4/site-packages/bzrlib/commit.py", line 355, in commit
    self._update_builder_with_changes()
  File "/usr/lib/python2.4/site-packages/bzrlib/commit.py", line 656, in _update_builder_with_changes
    self._populate_from_inventory(specific_files)
  File "/usr/lib/python2.4/site-packages/bzrlib/commit.py", line 784, in _populate_from_inventory
    content_summary)
  File "/usr/lib/python2.4/site-packages/bzrlib/commit.py", line 826, in _record_entry
    self.parent_invs, path, self.work_tree, content_summary)
  File "/usr/lib/python2.4/site-packages/bzrlib/repository.py", line 361, in record_entry_contents
    ie.text_sha1, ie.text_size = self._add_text_to_weave(
  File "/usr/lib/python2.4/site-packages/bzrlib/repository.py", line 427, in _add_text_to_weave
    check_content=False)[0:2]
  File "/usr/lib/python2.4/site-packages/bzrlib/versionedfile.py", line 138, in add_lines_with_ghosts
    parent_texts, nostore_sha, random_id, check_content)
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 918, in _add_lines_with_ghosts
    parent_texts, None, nostore_sha, random_id)
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 994, in _add
    left_matching_blocks)
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 839, in _merge_annotations
    merge_content = self._get_content(parent_id, parent_texts)
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 906, in _get_content
    text_map, contents_map = self._get_content_maps([version_id])
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 1086, in _get_content_maps
    record_map = self._get_record_map(version_ids)
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 1050, in _get_record_map
    for component_id, content, digest in \
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 2425, in read_records_iter
    for (version_id, index_memo), data in \
  File "/usr/lib/python2.4/site-packages/bzrlib/knit.py", line 1957, in get_raw_records
    for pos, data in self._transport.readv(self._filename, read_vector):
  File "/usr/lib/python2.4/site-packages/bzrlib/transport/__init__.py", line 724, in _seek_and_read
    c_offset.length, actual=len(data))
ShortReadvError: readv() read 21852 bytes rather than 22019 bytes at 45403 for "6a/ar.po-20061128205858-10pdyt0tb0x25d15-1.knit"

bzr 1.1.0.candidate.1 on python 2.4.4.final.0 (linux2)
arguments: ['/usr/bin/bzr', 'commit']
encoding: 'ANSI_X3.4-1968', fsenc: 'ANSI_X3.4-1968', lang: 'fr_FR.UTF-8'
plugins:
  bzrtools /usr/lib/python2.4/site-packages/bzrlib/plugins/bzrtools [1.1.0]
  launchpad /usr/lib/python2.4/site-packages/bzrlib/plugins/launchpad [unknown]
  multiparent /usr/lib/python2.4/site-packages/bzrlib/plugins/multiparent.pyc [unknown]
*** 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.

This is an an up-to-date Debian unstable system:

bubulle@mykerinos:~/src/debian/apt/bzr/debian-sid> dpkg -s bzr
Package: bzr
Status: install ok installed
Priority: optional
Section: devel
Installed-Size: 13726
Maintainer: Debian Bazaar Maintainers <email address hidden>
Architecture: i386
Version: 1.1~rc1-1

Revision history for this message
Martin Albisetti (beuno) wrote :

The only time I saw an error like this was when I ran out of space.
Is it possible you ran our of space at some point?

Revision history for this message
Robert Collins (lifeless) wrote : Re: [Bug 182477] Re: bzr crarshing when trying to commit to the APT repository

On Sun, 2008-01-13 at 23:17 +0000, Martin Albisetti wrote:
> The only time I saw an error like this was when I ran out of space.
> Is it possible you ran our of space at some point?

Also possible is a bad SFTP append() in the past leading to a corrupt
knit file. Thats more likely I think; I bet the knit in question is too
small.

I suggest you upgrade to packs, which are much more robust against this
(by not performing appends once the first upload is complete).

-Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.

Revision history for this message
Christian Perrier (bubulle-kheops) wrote :

Quoting Robert Collins (<email address hidden>):
>
> On Sun, 2008-01-13 at 23:17 +0000, Martin Albisetti wrote:
> > The only time I saw an error like this was when I ran out of space.
> > Is it possible you ran our of space at some point?

The answer to this is no.

>
> Also possible is a bad SFTP append() in the past leading to a corrupt
> knit file. Thats more likely I think; I bet the knit in question is too
> small.
>
> I suggest you upgrade to packs, which are much more robust against this
> (by not performing appends once the first upload is complete).

What is "packs". Please don't tell me this is "Yet Another DVCS"....

Revision history for this message
Alexander Belchenko (bialix) wrote :

Christian Perrier пишет:
> Quoting Robert Collins (<email address hidden>):
>> I suggest you upgrade to packs, which are much more robust against this
>> (by not performing appends once the first upload is complete).
>
>
> What is "packs". Please don't tell me this is "Yet Another DVCS"....

"packs" is latest default repo format in bzr 1.0 and later.
Just do:

bzr reconcile
bzr upgrade

and you should have repo with packs.

Revision history for this message
Martin Albisetti (beuno) wrote : Re: bzr crarshing when trying to commit to the APT repository

Did the upgrade to packs fix this?

Revision history for this message
Christian Perrier (bubulle) wrote : Re: [Bug 182477] Re: bzr crarshing when trying to commit to the APT repository

Martin Albisetti a écrit :
> Did the upgrade to packs fix this?
>

It probably did, yes, as I can now again commit to APT bzr repo.

I think you can safely close this bug report.

Revision history for this message
Martin Albisetti (beuno) wrote : Re: bzr crarshing when trying to commit to the APT repository

Thanks, closed.

Changed in bzr:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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