bzr revert with lightweight http checkout fails
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
Confirmed
|
High
|
Unassigned | ||
Bug Description
"bzr revert" fails with a lightweight http checkout:
bzr revert
bzr: ERROR: Cannot lock LockDir(http://
This happens with 1.11 and with the current bzr.dev tip.
The checkout was created with
bzr checkout --lightweight http://
and I've then applied a patch locally that I wanted to undo now.
The docs say that "revert" is to "Reverse all changes since the last commit". The "update" doc says:
" If you want to discard your local changes, you can just do a
'bzr revert' instead of 'bzr commit' after the update."
so I don't see why this shouldn't work.
Changed in bzr: | |
milestone: | 1.12rc1 → none |
I can reproduce this. Here's the traceback from the log file:
4.160 Traceback (most recent call last): andrew/ code/bzr/ bzrlib/ commands. py", line 893, in run_bzr_ catch_errors andrew/ code/bzr/ bzrlib/ commands. py", line 839, in run_bzr andrew/ code/bzr/ bzrlib/ commands. py", line 539, in run_argv_aliases **all_cmd_ args) andrew/ code/bzr/ bzrlib/ builtins. py", line 3444, in run lock_write( ) andrew/ code/bzr/ bzrlib/ workingtree_ 4.py", line 628, in lock_write branch. lock_write( ) andrew/ code/bzr/ bzrlib/ branch. py", line 1667, in lock_write files.lock_ write(token= token) andrew/ code/bzr/ bzrlib/ lockable_ files.py" , line 259, in lock_write lock_write( token=token) andrew/ code/bzr/ bzrlib/ lockdir. py", line 576, in lock_write andrew/ code/bzr/ bzrlib/ lockdir. py", line 500, in wait_lock andrew/ code/bzr/ bzrlib/ lockdir. py", line 461, in attempt_lock lock() andrew/ code/bzr/ bzrlib/ lockdir. py", line 226, in _attempt_lock bazaar- vcs.org/ bzr/bzr. dev/.bzr/ branch/ lock): Transport operation not possible: http does not support mkdir()
File "/home/
return run_bzr(argv)
File "/home/
ret = run(*run_argv)
File "/home/
return self.run(
File "/home/
tree.
File "/home/
self.
File "/home/
token = self.control_
File "/home/
token_from_lock = self._lock.
File "/home/
return self.wait_lock()
File "/home/
return self.attempt_lock()
File "/home/
result = self._attempt_
File "/home/
raise LockFailed(self, e)
LockFailed: Cannot lock LockDir(http://
I think bzr revert shouldn't be write-locking the branch, just the tree.