test_pack_optimizes_pack_order fails with default set to 2a

Bug #413957 reported by Martin Pool
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bazaar
Fix Released
High
Robert Collins

Bug Description

ERROR: test_repository.TestPacker.test_pack_optimizes_pack_order
    Overlapping range not allowed: last range ended at 42, new one starts at 6

======================================================================
ERROR: test_pack_optimizes_pack_order (bzrlib.tests.test_repository.TestPacker)

vvvv[log from bzrlib.tests.test_repository.TestPacker.test_pack_optimizes_pack_order]
2776.667 creating repository in file:///tmp/testbzr-v0FF4X.tmp/bzrlib.tests.test_repository.TestPacker.test_pack_optimizes_pack_order/work/.bzr/.
2776.677 creating branch <bzrlib.branch.BzrBranchFormat7 object at 0xee7996c> in file:///tmp/testbzr-v0FF4X.tmp/bzrlib.tests.test_repository.TestPacker.test_pack_optimizes_pack_order/work/.bzr/
2776.696 preparing to commit
2776.702 Selecting files for commit with filter []
2776.732 preparing to commit
2776.737 Selecting files for commit with filter []
2776.770 preparing to commit
2776.775 Selecting files for commit with filter []
2776.807 preparing to commit
2776.812 Selecting files for commit with filter []
2776.900 opening working tree '/tmp/testbzr-v0FF4X.tmp'

^^^^[log from bzrlib.tests.test_repository.TestPacker.test_pack_optimizes_pack_order]
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/mbp/bzr/398668-2a-default/bzrlib/tests/test_repository.py", line 1387, in test_pack_optimizes_pack_order
    new_pack = packer.pack()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/repofmt/pack_repo.py", line 749, in pack
    return self._create_pack_from_packs()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/repofmt/pack_repo.py", line 910, in _create_pack_from_packs
    self._copy_revision_texts()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/repofmt/pack_repo.py", line 818, in _copy_revision_texts
    self.new_pack.revision_index, readv_group_iter, total_items))
  File "/home/mbp/bzr/398668-2a-default/bzrlib/repofmt/pack_repo.py", line 1044, in _copy_nodes_graph
    write_index, output_lines, pb, readv_group_iter, total_items):
  File "/home/mbp/bzr/398668-2a-default/bzrlib/repofmt/pack_repo.py", line 1073, in _do_copy_nodes_graph
    izip(reader.iter_records(), node_vector):
  File "/home/mbp/bzr/398668-2a-default/bzrlib/pack.py", line 271, in iter_records
    self._read_format()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/pack.py", line 312, in _read_format
    format = self._read_line()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/pack.py", line 239, in _read_line
    line = self._source.readline()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/pack.py", line 202, in readline
    self._next()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/pack.py", line 187, in _next
    offset, data = self.readv_result.next()
  File "/home/mbp/bzr/398668-2a-default/bzrlib/transport/__init__.py", line 689, in _seek_and_read
    fudge_factor=self._bytes_to_read_before_seek)
  File "/home/mbp/bzr/398668-2a-default/bzrlib/transport/__init__.py", line 832, in _coalesce_offsets
    % (last_end, start))
ValueError: Overlapping range not allowed: last range ended at 42, new one starts at 6

Related branches

Revision history for this message
John A Meinel (jameinel) wrote : Re: [Bug 413957] [NEW] test_pack_optimizes_pack_order fails with default set to 2a

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Martin Pool wrote:
> Public bug reported:
>
>
> ERROR: test_repository.TestPacker.test_pack_optimizes_pack_order
> Overlapping range not allowed: last range ended at 42, new one starts at 6

I'm pretty sure I fixed that one recently. Basically the code assumes it
knows what the 'value' field in the index means, but it is different
between chk and regular indexes.

The old code used:

 isinstance(repo, RepositoryCHK1) to check, and now it needs
 isinstance(repo, Repository2a)

or something along those lines.

John
=:->

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkqGvukACgkQJdeBCYSNAANYEQCdGIHCL+Nqe8W8TsErP32YBl3k
36gAnRusckIhz0Za4aNwWBXu6aqOzaWw
=kkCA
-----END PGP SIGNATURE-----

Revision history for this message
Robert Collins (lifeless) wrote :

This was occuring in bzr.dev on my Friday - how recently were you
thinking of?

-Rob

Changed in bzr:
status: Confirmed → Fix Released
assignee: nobody → Robert Collins (lifeless)
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.