V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX Workspace
https://workspace.v2ex.com/
mactive
V2EX  ›  Project Stormwind

上传下载文件不成功, 仅能显示文件名

  •  
  •   mactive · 2011-10-25 10:28:41 +08:00 · 5729 次点击
    这是一个创建于 4770 天前的主题,其中的信息可能已经有所发展或是发生改变。
    在 Files 中新建了一个 bucket,上传文件成功了但是有报错
    而且也不让下载,传的PDF
    而且 Bucket 下统计也不对。还是 0 files at 0 bytes
    点击进去倒是可以显示文件名,但是下载也是报错。
    PS: 在News Feed中也没有提示
    @livid 项目你应该能看到。 https://workspace.v2ex.com/project/zigbeeplanet/files

    /* 上传报错 */
    POST /project/zigbeeplanet/files/upload/ZigBee%E5%89%8D%E6%9C%9F%E8%B0%83%E7%A0%94 (119.57.31.99)
    Traceback (most recent call last):
    File "/usr/lib/python2.6/site-packages/tornado-2.1.1-py2.6.egg/tornado/web.py", line 954, in _execute
    getattr(self, self.request.method.lower())(*args, **kwargs)
    File "/www/workspace/workspace/security.py", line 44, in wrapper
    return method(self, *args, **kwargs)
    File "/www/workspace/workspace/handlers/desktop/project/files/__init__.py", line 183, in post
    db.put_attachment(doc, upload['body'], upload_filename, upload_content_type)
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/client.py", line 638, in put_attachment
    }, rev=doc['_rev'])
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/http.py", line 405, in put_json
    status, headers, data = self.put(*a, **k)
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/http.py", line 384, in put
    return self._request('PUT', path, body=body, headers=headers, **params)
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/http.py", line 419, in _request
    credentials=self.credentials)
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/http.py", line 239, in request
    resp = _try_request_with_retries(iter(self.retry_delays))
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/http.py", line 205, in _try_request_with_retries
    raise e
    error: [Errno 104] Connection reset by peer

    /* 下载报错 */

    GET /file/da1fe94e-feb0-11e0-879c-f23c91df499e/%E6%95%B0%E5%AD%97%E5%8C%96%E4%BA%95%E5%8F%A3%E6%97%A0%E7%BA%BF(ZigBee)%E9%80%9A%E4%BF%A1%E5%89%8D%E6%9C%9F%E8%B0%83%E7%A0%94.pdf (119.57.31.99)
    Traceback (most recent call last):
    File "/usr/lib/python2.6/site-packages/tornado-2.1.1-py2.6.egg/tornado/web.py", line 954, in _execute
    getattr(self, self.request.method.lower())(*args, **kwargs)
    File "/www/workspace/workspace/handlers/desktop/project/files/__init__.py", line 298, in get
    a = db.get_attachment(doc, file_name)
    File "/usr/lib/python2.6/site-packages/CouchDB-0.8-py2.6.egg/couchdb/client.py", line 599, in get_attachment
    id = id_or_doc['_id']
    KeyError: '_id'
    3 条回复    1970-01-01 08:00:00 +08:00
    Livid
        1
    Livid  
    MOD
       2011-10-25 10:30:40 +08:00
    这是一个目前的已知问题,文件名中不能包含中文:

    https://workspace.v2ex.com/faq#known

    这个问题会尽快修复,但是目前,你需要把文件名中的中文去掉……
    mactive
        2
    mactive  
    OP
       2011-10-25 10:35:21 +08:00
    明白了 多谢
    Livid
        3
    Livid  
    MOD
       2011-10-29 14:18:49 +08:00
    这个问题目前已经修复了。

    向之前所有上传中文文件名时受到影响的用户致歉。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   4056 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 22ms · UTC 05:23 · PVG 13:23 · LAX 21:23 · JFK 00:23
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.