Opened at 2007-08-24T15:44:36Z
Last modified at 2007-08-27T12:32:43Z
#124 closed defect
exceptions when trying to use dirnode URIs — at Version 2
Reported by: | zooko | Owned by: | somebody |
---|---|---|---|
Priority: | major | Milestone: | 0.6.0 |
Component: | code | Version: | 0.5.1 |
Keywords: | Cc: | ||
Launchpad Bug: |
Description (last modified by zooko)
poor handling of user error: pasting a dirnode uri into the "get file" field of the wui
If you paste a dirnode uri into the "URI of file to download" field, you'll get:
An error occurred rendering the requested page. Additionally, an error occured rendering the error page.
The twistd.log contains:
File "/Users/wonwinmcbrootles/playground/allmydata/tahoe/instdir/lib/allmydata/vdrive.py", line 128, in get_node node_uri = IURI(node_uri) # node_uri = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85cazf aa8uyd8mb1u8esw'" # IURI = '<InterfaceClass allmydata.interfaces.IURI>' File "/lib/python2.5/site-packages/zope/interface/interface.py", line 697, in __call__ File "/lib/python2.5/site-packages/zope/interface/interface.py", line 765, in __adapt__ File "/usr/local/stow/Twisted-2.5.0/lib/python2.5/site-packages/twisted/python/components.py", line 113, in _hook return factory(ob) # ob = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85cazfaa8uyd 8mb1u8esw'" File "/Users/wonwinmcbrootles/playground/allmydata/tahoe/instdir/lib/allmydata/uri.py", line 205, in from_string raise RuntimeError("unknown URI type: %s.." % s[:10]) # RuntimeError = "<type 'exceptions.RuntimeError'>" # s = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85cazfaa8uyd8 mb1u8esw'" exceptions.RuntimeError: unknown URI type: URI:DIR:p..
and
File "/usr/local/lib/python2.5/site-packages/nevow/appserver.py", line 82, in processingFailed handler.renderHTTP_exception(ctx, reason) File "/usr/local/lib/python2.5/site-packages/nevow/appserver.py", line 57, in renderHTTP_exception result = failure.formatFailure(reason) # reason = <twisted.python.failure.Failure <type 'exceptions.RuntimeError'>> File "/usr/local/stow/Nevow-0.9.18/lib/python2.5/site-packages/nevow/failure.py", line 248, in formatFailure for method, filename, lineno, localVars, globalVars in myFailure.frames: # myFailure = <twisted.python.failure.Failure <type 'exceptions.RuntimeError'>>
Ah, the same thing happens when I paste the dirnode uri into the "URI of new child" field!
Here is the twistd.log from that:
File "/Users/wonwinmcbrootles/playground/allmydata/tahoe/instdir/lib/allmydata/dirnode.py", line 282, in set_uri write, read = self._split_uri(child_uri) # self = '<allmydata.dirnode.MutableDirectoryNode instance at 0x20e3170>' # child_uri = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85caz faa8uyd8mb1u8esw'" File "/Users/wonwinmcbrootles/playground/allmydata/tahoe/instdir/lib/allmydata/dirnode.py", line 306, in _split_uri u = IURI(child_uri) # IURI = '<InterfaceClass allmydata.interfaces.IURI>' # child_uri = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85caz faa8uyd8mb1u8esw'" File "/lib/python2.5/site-packages/zope/interface/interface.py", line 697, in __call__ File "/lib/python2.5/site-packages/zope/interface/interface.py", line 765, in __adapt__ File "/usr/local/stow/Twisted-2.5.0/lib/python2.5/site-packages/twisted/python/components.py", line 113, in _hook return factory(ob) # ob = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85cazfaa8uyd 8mb1u8esw'" File "/Users/wonwinmcbrootles/playground/allmydata/tahoe/instdir/lib/allmydata/uri.py", line 205, in from_string raise RuntimeError("unknown URI type: %s.." % s[:10]) # RuntimeError = "<type 'exceptions.RuntimeError'>" # s = "' URI:DIR:pb://xextf3eap44o3wi27mf7ehiur6wvhzr6@207.7.153.180:56677,127.0.0.1:56677/vdrive:y1obs85cazfaa8uyd8 mb1u8esw'" exceptions.RuntimeError: unknown URI type: URI:DIR:p..
Change History (2)
comment:1 Changed at 2007-08-24T15:44:54Z by zooko
- Component changed from unknown to code-frontend-web
- Owner nobody deleted
comment:2 Changed at 2007-08-24T15:47:31Z by zooko
- Component changed from code-frontend-web to code
- Description modified (diff)
- Owner set to somebody
- Summary changed from poor handling of user error: pasting a dirnode uri into the "get file" field of the wui to exceptions when trying to use dirnode URIs
Note: See
TracTickets for help on using
tickets.