[tahoe-dev] Bug in SFTP frontend

Jody Harris imhavoc at gmail.com
Sun Feb 7 05:00:47 UTC 2010


On Sat, Feb 6, 2010 at 9:48 PM, David-Sarah Hopwood <
david-sarah at jacaranda.org> wrote:

> Jody Harris wrote:
> > On Sat, Feb 6, 2010 at 8:34 PM, David-Sarah Hopwood <
> > david-sarah at jacaranda.org> wrote:
> >
> >> Jody Harris wrote:
> >>> 2010-02-06 19:09:37-0700 [SSHChannel session (0) on SSHService
> >>> ssh-connection on SSHServerTransport,11,127.0.0.1] Unhandled Error
> >> [...]
> >>>           File
> >>> "/usr/lib/python2.6/dist-packages/twisted/conch/ssh/filetransfer.py",
> >> line
> >>> 95, in _packAttributes
> >>>             data += struct.pack('!Q', attrs['size'])
> >>>         struct.error: cannot convert argument to long
> >> OK, try applying
> >> <
> >>
> http://allmydata.org/trac/tahoe/raw-attachment/ticket/645/size-assertions-darcspatch.txt
> >> on top of the previous patch.
> >> (It should fail an assertion and tell me what attrs['size']
> >
> > I'm not getting an attrs['size'] in the log... here is what I am getting:
> [...]
> >           File
> >
> "/usr/local/lib/python2.6/dist-packages/allmydata_tahoe-1.6.0_r4229-py2.6.egg/allmydata/frontends/sftpd.py",
> > line 269, in _render
> >             assert isinstance(s.st_size, (int, long)), s.st_size
> >         exceptions.AssertionError:
>
> That means that attrs['size'] is probably "" or None. I should have used
>
>  assert isinstance(s.st_size, (int, long)), repr(s.st_size)
>
> instead to distinguish them.
>
> Are there any mutable files under the alias directory, or only directories
> and immutable files? Does the above error occur when the alias directory
> is empty?
>

I created a fresh, new empty alias.

If the directory is empty: No errors. Only SSHService reports.

If I put a single immutable file in the directory ({{{tahoe cp file
alias}}}), I get no errors, but I also get no response.

... {{{tahoe ls alias:}}} seems to be broken, now.

jody
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tahoe-lafs.org/pipermail/tahoe-dev/attachments/20100206/a8ec1356/attachment.html>


More information about the tahoe-dev mailing list