Attachment 'WikiSandBox.htm'

Download

--> -->

UnboundLocalError

local variable 'indent' referenced before assignment

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. /srv/moin/code/1.8/MoinMoin/request/__init__.py in run (self=<MoinMoin.request.request_wsgi.Request object>)

    1. 1308 self.page.send_page()
    2. 1309 else:
    3. 1310 handler(self.page.page_name, self)
    4. 1311
    5. 1312 # every action that didn't use to raise MoinMoinFinish must call this now:
    • handler = <function execute>
    • self = <MoinMoin.request.request_wsgi.Request object>
    • self.page = <MoinMoin.Page.Page object>
    • self.page.page_name = u'WikiSandBox'
  2. /srv/moin/code/1.8/MoinMoin/action/edit.py in execute (pagename=u'WikiSandBox', request=<MoinMoin.request.request_wsgi.Request object>)

    1. 95 converter_name = 'undefined' # XXX we don't have other converters yet
    2. 96 convert = wikiutil.importPlugin(request.cfg, "converter", converter_name, 'convert')
    3. 97 savetext = convert(request, pagename, savetext)
    4. 98
    5. 99 # IMPORTANT: normalize text from the form. This should be done in
    • savetext = u'<pre class="comment">\r\n## Please edit system and.../CategoryMoinMoinBug">CategoryMoinMoinBug</a></p>'
    • convert = <function convert>
    • request = <MoinMoin.request.request_wsgi.Request object>
    • pagename = u'WikiSandBox'
  3. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in convert (request=<MoinMoin.request.request_wsgi.Request object>, pagename=u'WikiSandBox', text=u'<page xmlns:o="urn:schemas-microsoft-com:office:...ryMoinMoinBug">CategoryMoinMoinBug</a></p></page>')

    1. 1433 tree = parse(request, text)
    2. 1434 strip_whitespace().do(tree)
    3. 1435 text = convert_tree(request, pagename).do(tree)
    4. 1436 text = '\n'.join([s.rstrip() for s in text.splitlines()] + ['']) # remove trailing blanks
    5. 1437 return text
    • text = u'<page xmlns:o="urn:schemas-microsoft-com:office:...ryMoinMoinBug">CategoryMoinMoinBug</a></p></page>'
    • global convert_tree = <class 'MoinMoin.converter.text_html_text_moin_wiki.convert_tree'>
    • request = <MoinMoin.request.request_wsgi.Request object>
    • pagename = u'WikiSandBox'
    • ).do undefined
    • tree = <xml.dom.minidom.Document instance>
  4. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in do (self=<MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>, tree=<xml.dom.minidom.Document instance>)

    1. 463 self.depth = 0
    2. 464 self.text = []
    3. 465 self.visit(tree.documentElement)
    4. 466 self.check_whitespace()
    5. 467 return ''.join(self.text)
    • self = <MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>
    • self.visit = <bound method convert_tree.visit of <MoinMoin.co...er.text_html_text_moin_wiki.convert_tree object>>
    • tree = <xml.dom.minidom.Document instance>
    • tree.documentElement = <DOM Element: page at -0x4f80d6f4>
  5. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in visit (self=<MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>, node=<DOM Element: page at -0x4f80d6f4>)

    1. 409 nodeType = node.nodeType
    2. 410 if node.nodeType == Node.ELEMENT_NODE:
    3. 411 return self.visit_element(node)
    4. 412 elif node.nodeType == Node.ATTRIBUTE_NODE:
    5. 413 return self.visit_attribute(node)
    • self = <MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>
    • self.visit_element = <bound method convert_tree.visit_element of <Moi...er.text_html_text_moin_wiki.convert_tree object>>
    • node = <DOM Element: page at -0x4f80d6f4>
  6. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in visit_element (self=<MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>, node=<DOM Element: page at -0x4f80d6f4>)

    1. 515 func = getattr(self, "process_%s" % name, None)
    2. 516 if func:
    3. 517 func(node)
    4. 518 else:
    5. 519 self.process_inline(node)
    • func = <bound method convert_tree.process_page of <Moin...er.text_html_text_moin_wiki.convert_tree object>>
    • node = <DOM Element: page at -0x4f80d6f4>
  7. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in process_page (self=<MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>, node=<DOM Element: page at -0x4f80d6f4>)

    1. 558 for i in node.childNodes:
    2. 559 if i.nodeType == Node.ELEMENT_NODE:
    3. 560 self.visit_element(i)
    4. 561 elif i.nodeType == Node.TEXT_NODE: # if this is missing, all std text under a headline is dropped!
    5. 562 txt = i.data.strip() # IMPORTANT: don't leave this unstripped or there will be wrong blanks
    • self = <MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>
    • self.visit_element = <bound method convert_tree.visit_element of <Moi...er.text_html_text_moin_wiki.convert_tree object>>
    • i = <DOM Element: dl at -0x4f968af4>
  8. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in visit_element (self=<MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>, node=<DOM Element: dl at -0x4f968af4>)

    1. 515 func = getattr(self, "process_%s" % name, None)
    2. 516 if func:
    3. 517 func(node)
    4. 518 else:
    5. 519 self.process_inline(node)
    • func = <bound method convert_tree.process_dl of <MoinMo...er.text_html_text_moin_wiki.convert_tree object>>
    • node = <DOM Element: dl at -0x4f968af4>
  9. /srv/moin/code/1.8/MoinMoin/converter/text_html_text_moin_wiki.py in process_dl (self=<MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>, node=<DOM Element: dl at -0x4f968af4>)

    1. 636 elif name == 'dd':
    2. 637 self.text.append(markup)
    3. 638 self.process_list_item(i, indent) # XXX no dt -> indent is undefined!!!
    4. 639 else:
    5. 640 raise ConvertError("Illegal list element %s" % i.localName)
    • self = <MoinMoin.converter.text_html_text_moin_wiki.convert_tree object>
    • self.process_list_item = <bound method convert_tree.process_list_item of ...er.text_html_text_moin_wiki.convert_tree object>>
    • i = <DOM Element: dd at -0x4f968314>
    • indent undefined

UnboundLocalError

local variable 'indent' referenced before assignment

  • args = ("local variable 'indent' referenced before assignment",)

System Details

  • Date: Tue, 30 Sep 2008 15:24:45 +0000
  • Platform: Linux www.moinmo.in 2.6.18-6-xen-686 #1 SMP Sat May 24 14:16:03 UTC 2008 i686
  • Python: Python 2.4.4 (/usr/bin/python)
  • MoinMoin: Release 1.8.0beta3 (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-09-30 15:31:39, 13.9 KB) [[attachment:WikiSandBox.htm]]
 All files | Selected Files: delete move to page copy to page

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