[BUG] sftp push usage
John Arbash Meinel
john at arbash-meinel.com
Thu May 25 15:50:37 BST 2006
Alexander Belchenko wrote:
> I think it's a bug.
>
> Today I'm testing how paramiko works on win32.
> I try to push paramiko's own branch to linux machine.
> I specify wrong path but bzr behaviour is buggy.
Well, there are 2 bugs here, but I can confirm both of them.
1: using 'bzr push sftp://localhost/test' tries to create 'test' rather
than '/test'. because it is able to split the url down to
'sftp://localhost' which it thinks is a directory.
My encodings branch had a lot of work to switch the url handling, which
may fix this bug.
2: LockableFiles doesn't create _lock_count early enough. So a failure
during creation causes the bogus error. I could have sworn I've
committed a fix for this (maybe also in my encodings branch).
The issue is that _find_modes() can raise an exception, and the
deconstructor expects _lock_count to exist.
Putting 'self._lock_count = 0' before 'self._find_modes' in
LockableFiles.__init__ should fix this.
Alternatively, we could add '_lock_count = 0' to the Class declaration,
though my understanding is we were avoiding class declared variables.
...
>
> Good news: because paramiko know how to request password from command
> prompt, sftp works OK even without putty, pageant and other helpers
> utility. So, basic bzr.exe distribution is ready for sftp on win32.
> But selftest for sftp transport should be rewritten for make it passed
> on win32.
>
> --
> Alexander
good to hear. I've always used openssh on Windows. My encoding branch
*may* end up fixing the sftp tests, but it isn't a direct focus right
now. (In my testing the problem is just translating c:\local\directory
=>sftp://localhost/c:/local/directory and back again).
The sftp server needs a little bit of updating to translate the paths,
and it is Robert's suggestion that it should be given a Transport
object, since then it could be given a MemoryTransport.
John
=:->
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 254 bytes
Desc: OpenPGP digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060525/c0da1f1b/attachment.pgp
More information about the bazaar
mailing list