Attachment 'attach_file_error.html'

Download

--> -->

ValueError

I/O operation on closed file

If you want to report a bug, please save this page and attach it to your bug report.

Traceback

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.

  1. /usr/local/lib/python2.5/site-packages/MoinMoin/request/__init__.py in run (self=<MoinMoin.request.request_modpython.Request object at 0x96343cc>)

    1. 1304 self.page.send_page()
    2. 1305 else:
    3. 1306 handler(self.page.page_name, self)
    4. 1307
    5. 1308 # every action that didn't use to raise MoinMoinFinish must call this now:
    • handler = <function execute at 0x977ce2c>
    • self = <MoinMoin.request.request_modpython.Request object at 0x96343cc>
    • self.page = <MoinMoin.Page.Page object at 0x9354a2c>
    • self.page.page_name = u'TusharWagle'
  2. /usr/local/lib/python2.5/site-packages/MoinMoin/action/AttachFile.py in execute (pagename=u'TusharWagle', request=<MoinMoin.request.request_modpython.Request object at 0x96343cc>)

    1. 511 handler = globals().get('_do_%s' % do[0])
    2. 512 if handler:
    3. 513 msg = handler(pagename, request)
    4. 514 else:
    5. 515 msg = _('Unsupported AttachFile sub-action: %s') % (wikiutil.escape(do[0]), )
    • msg undefined
    • handler = <function _do_upload at 0x977cf0c>
    • pagename = u'TusharWagle'
    • request = <MoinMoin.request.request_modpython.Request object at 0x96343cc>
  3. /usr/local/lib/python2.5/site-packages/MoinMoin/action/AttachFile.py in _do_upload (pagename=u'TusharWagle', request=<MoinMoin.request.request_modpython.Request object at 0x96343cc>)

    1. 590 # add the attachment
    2. 591 try:
    3. 592 target, bytes = add_attachment(request, pagename, target, filecontent, overwrite=overwrite)
    4. 593 msg = _("Attachment '%(target)s' (remote name '%(filename)s')"
    5. 594 " with %(bytes)d bytes saved.") % {
    • target = u'cq2svn_overview_3.png'
    • bytes undefined
    • global add_attachment = <function add_attachment at 0x977cbfc>
    • request = <MoinMoin.request.request_modpython.Request object at 0x96343cc>
    • pagename = u'TusharWagle'
    • filecontent = <closed file '<fdopen>', mode 'w+b' at 0x989ff08>
    • overwrite = 0
  4. /usr/local/lib/python2.5/site-packages/MoinMoin/action/AttachFile.py in add_attachment (request=<MoinMoin.request.request_modpython.Request object at 0x96343cc>, pagename=u'TusharWagle', target=u'cq2svn_overview_3.png', filecontent=<closed file '<fdopen>', mode 'w+b' at 0x989ff08>, overwrite=0)

    1. 208 stream = open(fpath, 'wb')
    2. 209 try:
    3. 210 _write_stream(filecontent, stream)
    4. 211 finally:
    5. 212 stream.close()
    • global _write_stream = <function _write_stream at 0x977cbc4>
    • filecontent = <closed file '<fdopen>', mode 'w+b' at 0x989ff08>
    • stream = <closed file '/usr/share/moin/insight/data/pages...s/cq2svn_overview_3.png', mode 'wb' at 0x98aa068>
  5. /usr/local/lib/python2.5/site-packages/MoinMoin/action/AttachFile.py in _write_stream (content=<closed file '<fdopen>', mode 'w+b' at 0x989ff08>, stream=<closed file '/usr/share/moin/insight/data/pages...s/cq2svn_overview_3.png', mode 'wb' at 0x98aa068>, bufsize=8192)

    1. 175 if hasattr(content, 'read'): # looks file-like
    2. 176 import shutil
    3. 177 shutil.copyfileobj(content, stream, bufsize)
    4. 178 elif isinstance(content, str):
    5. 179 stream.write(content)
    • shutil = <module 'shutil' from '/usr/local/lib/python2.5/shutil.pyc'>
    • shutil.copyfileobj = <function copyfileobj at 0x964025c>
    • content = <closed file '<fdopen>', mode 'w+b' at 0x989ff08>
    • stream = <closed file '/usr/share/moin/insight/data/pages...s/cq2svn_overview_3.png', mode 'wb' at 0x98aa068>
    • bufsize = 8192
  6. /usr/local/lib/python2.5/shutil.py in copyfileobj (fsrc=<closed file '<fdopen>', mode 'w+b' at 0x989ff08>, fdst=<closed file '/usr/share/moin/insight/data/pages...s/cq2svn_overview_3.png', mode 'wb' at 0x98aa068>, length=8192)

    1. 19 """copy data from file-like object fsrc to file-like object fdst"""
    2. 20 while 1:
    3. 21 buf = fsrc.read(length)
    4. 22 if not buf:
    5. 23 break
    • buf undefined
    • fsrc = <closed file '<fdopen>', mode 'w+b' at 0x989ff08>
    • fsrc.read = <built-in method read of file object at 0x989ff08>
    • length = 8192

ValueError

I/O operation on closed file

  • args = ('I/O operation on closed file',)
  • message = 'I/O operation on closed file'

System Details

  • Date: Mon, 21 Jul 2008 13:43:39 +0000
  • Platform: Linux caretaker.inside 2.6.18-53.1.13.el5 #1 SMP Tue Feb 12 13:01:45 EST 2008 i686
  • Python: Python 2.5.2 (/usr/bin/python)
  • MoinMoin: Release 1.7.0 (release)

Attached Files

To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.
  • [get | view] (2008-07-21 14:01:51, 10.7 KB) [[attachment:attach_file_error.html]]
 All files | Selected Files: delete move to page copy to page

You are not allowed to attach a file to this page.