Qt frontend for Bazaar

qcommit crashes on cancel

Reported by Craig Hewetson on 2009-05-30
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QBzr
Medium
Gary van der Merwe

Bug Description

Did a light weight checkout of lp:bzr.
Made changes and ran qcommit.
Pressed cancel and the following error message shows:

bzr: ERROR: exceptions.AttributeError: 'RemoteRepository' object has no attribute 'control_files'

Traceback (most recent call last):
  File "/home/craig/.bazaar/plugins/qbzr/lib/commit.py", line 605, in closeEvent
    self.save_message()
  File "/home/craig/.bazaar/plugins/qbzr/lib/commit.py", line 477, in save_message
    self.tree.branch.repository.control_files.get_physical_lock_status() or\
AttributeError: 'RemoteRepository' object has no attribute 'control_files'

=========================
Output of bzr info to give more info of the checkout:
Lightweight checkout (format: 1.6 or 1.6.1-rich-root or 1.9 or 1.9-rich-root or dirstate or dirstate-tags or pack-0.92 or rich-root or rich-root-pack)
Location:
   checkout of branch: bzr+ssh://bazaar.launchpad.net/%7Ebzr/bzr/trunk/
    shared repository: bzr+ssh://bazaar.launchpad.net/%7Ebzr/bzr/trunk/

Related branches:
  parent branch: http://bazaar-ng.org/bzr/bzr.dev/

Changed in qbzr:
assignee: nobody → Gary van der Merwe (garyvdm)
importance: Undecided → Medium
milestone: none → 0.11.0
status: New → Fix Committed
Alexander Belchenko (bialix) wrote :

Craig, I guess you don't have write permissions to commit directly into lp:bzr.

On Thu, Jun 11, 2009 at 4:32 PM, Alexander Belchenko<email address hidden> wrote:
> Craig, I guess you don't have write permissions to commit directly into
> lp:bzr.

Alex - The old code was trying to access the attribute 'control_files'
which exists only for a local Repository objects, and not for
RemoteRepository.

I did some testing, and we only need to check that the branch is not
locked, and not the repository. I'm not sure why I was checking if the
Repository was locked before, but I'm sure this was incorrect.

Alexander Belchenko (bialix) wrote :

Gary van der Merwe пишет:
> On Thu, Jun 11, 2009 at 4:32 PM, Alexander Belchenko<email address hidden> wrote:
>> Craig, I guess you don't have write permissions to commit directly into
>> lp:bzr.
>
> Alex - The old code was trying to access the attribute 'control_files'
> which exists only for a local Repository objects, and not for
> RemoteRepository.
>
> I did some testing, and we only need to check that the branch is not
> locked, and not the repository. I'm not sure why I was checking if the
> Repository was locked before, but I'm sure this was incorrect.

I agree. Anyway this bug plunging the thoughts about another error
masked by the Traceback in this bug report. I.e. I'm sure Craig unable
to commit directly to lp:bzr. So his commit never succeed. Therefore on
exit qcommit will try to save commit message in branch.conf of lp:bzr.
But this operation should fail as well, because Craig has no permissions
to modify lp:bzr, and... we should get another error here actually,
I'm just can't predict which one. Real test needed!

Gary van der Merwe (garyvdm) wrote :

On Thu, Jun 11, 2009 at 5:07 PM, Alexander Belchenko<email address hidden> wrote:
> I agree. Anyway this bug plunging the thoughts about another error
> masked by the Traceback in this bug report. I.e. I'm sure Craig unable
> to commit directly to lp:bzr. So his commit never succeed. Therefore on
> exit qcommit will try to save commit message in branch.conf of lp:bzr.
> But this operation should fail as well, because Craig has no permissions
> to modify lp:bzr, and... we should get another error here actually,
> I'm just can't predict which one. Real test needed!

No - It will save to the branch.conf of the lightweight checkout.

Alexander Belchenko (bialix) wrote :

Gary van der Merwe пишет:
> On Thu, Jun 11, 2009 at 5:07 PM, Alexander Belchenko<email address hidden> wrote:
>> I agree. Anyway this bug plunging the thoughts about another error
>> masked by the Traceback in this bug report. I.e. I'm sure Craig unable
>> to commit directly to lp:bzr. So his commit never succeed. Therefore on
>> exit qcommit will try to save commit message in branch.conf of lp:bzr.
>> But this operation should fail as well, because Craig has no permissions
>> to modify lp:bzr, and... we should get another error here actually,
>> I'm just can't predict which one. Real test needed!
>
> No - It will save to the branch.conf of the lightweight checkout.

Gary, lightweight checkout does not have local branch.conf.

I think lightweight checkouts should have local tree.conf though.
But there is not tree.conf at all in bzr today.

Changed in qbzr:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers