TypeError: 'NoneType' object is not callable
"Rex Madden" <[email protected]>
| Newsgroups | gmane.comp.web.wiki.moin.devel |
|---|---|
| Message-ID | <008401c3de3c$0dd89e50$6501a8c0@rexlaptop> |
Hi,
I installed MoinMoin as a personal wiki. It works great, except that it
errors out when I try to run some of the optional macros from
MacroMarket, such as SearchInPagesAndSort and IncludeCalendarPage.
MonthCalendar works fine. The stack trace is below.
TypeError: 'NoneType' object is not callable Please include this
information in your bug reports!:
Python 2.3.3 (#51, Dec 18 2003, 20:22:39) [MSC v.1200 32 bit (Intel)] -
C:\Program Files\python\python.exe
Platform: win32 (nt)
MoinMoin Release 1.1 [Revision 1.178]
A problem occurred while running a Python script. Here is the sequence
of function calls leading up to the error, with the most recent
(innermost) call first. The exception attributes are:
__doc__ = 'Inappropriate argument type.'
__getitem__ = <bound method TypeError.__getitem__ of
<exceptions.TypeError instance at 0x0082D5A8>>
__init__ = <bound method TypeError.__init__ of
<exceptions.TypeError instance at 0x0082D5A8>>
__module__ = 'exceptions'
__str__ = <bound method TypeError.__str__ of <exceptions.TypeError
instance at 0x0082D5A8>>
args = ("'NoneType' object is not callable",)
c:\Program Files\python\Lib\site-packages\MoinMoin\wikimacro.py in
execute_external_macro(macro_name='SearchInPagesAndSort',
function='execute', args=(<MoinMoin.wikimacro.Macro instance at
0x00857F08>, '"Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]*\\]"'))
76 if macro_name in plugin_macros:
77 execute = pysupport.importPlugin(_plugins,
"MoinMoin.plugin.macro", macro_name, function)
78 return execute(*args)
execute = None, args = (<MoinMoin.wikimacro.Macro instance at
0x00857F08>, '"Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]*\\]"')
79
80 raise ImportError("Cannot load macro %s" % macro_name)
c:\Program Files\python\Lib\site-packages\MoinMoin\wikimacro.py in
execute(self=<MoinMoin.wikimacro.Macro instance at 0x00857F08>,
macro_name='SearchInPagesAndSort',
args='"Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]*\\]"')
109 return ''
110
111 return execute_external_macro(macro_name, "execute",
(self, args))
global execute_external_macro = <function execute_external_macro
at 0x00856370>, macro_name = 'SearchInPagesAndSort', self =
<MoinMoin.wikimacro.Macro instance at 0x00857F08>, args =
'"Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]*\\]"'
112
113 def _macro_TitleSearch(self, args):
c:\Program Files\python\Lib\site-packages\MoinMoin\parser\wiki.py in
_macro_repl(self=<MoinMoin.parser.wiki.Parser instance at 0x008465D0>,
word='[[SearchInPagesAndSort("Nom.*2003w11|ProjectStatus","{[123]}","\\[
[A-Z]*\\]")]]')
702
703 # call the macro
704 return self.macro.execute(macro_name, args)
self = <MoinMoin.parser.wiki.Parser instance at 0x008465D0>,
global macro = undefined, global execute = undefined, macro_name =
'SearchInPagesAndSort', args =
'"Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]*\\]"'
705
706
c:\Program Files\python\Lib\site-packages\MoinMoin\parser\wiki.py in
replace(self=<MoinMoin.parser.wiki.Parser instance at 0x008465D0>,
match=<_sre.SRE_Match object at 0x007C1988>)
813 return self.highlight_text(hit)
814 else:
815 return getattr(self, '_' + type +
'_repl')(hit)
global getattr = undefined, self = <MoinMoin.parser.wiki.Parser
instance at 0x008465D0>, type = 'macro', hit =
'[[SearchInPagesAndSort("Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]
*\\]")]]'
816 else:
817 import pprint
C:\PROGRA~1\python\Lib\sre.py in subn(pattern=<_sre.SRE_Pattern object
at 0x006BF008>, repl=<bound method Parser.replace of
<MoinMoin.parser.wiki.Parser instance at 0x008465D0>>,
string='[[SearchInPagesAndSort("Nom.*2003w11|ProjectStatus","{[123]}","\
\[[A-Z]*\\]")]] ', count=0)
149 string by the replacement repl. number is the number of
150 substitutions that were made."""
151 return _compile(pattern, 0).subn(repl, string, count)
global _compile = <function _compile at 0x00729830>, pattern =
<_sre.SRE_Pattern object at 0x006BF008>, global subn = <function subn at
0x00723E30>, repl = <bound method Parser.replace of
<MoinMoin.parser.wiki.Parser instance at 0x008465D0>>, string =
'[[SearchInPagesAndSort("Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]
*\\]")]] ', count = 0
152
153 def split(pattern, string, maxsplit=0):
c:\Program Files\python\Lib\site-packages\MoinMoin\parser\wiki.py in
format(self=<MoinMoin.parser.wiki.Parser instance at 0x008465D0>,
formatter=<MoinMoin.formatter.text_html.Formatter instance at
0x0082DD00>)
937 self.request.write(self.highlight_scan(scan_re,
line))
938 else:
939 line, count = re.subn(scan_re, self.replace, line)
line =
'[[SearchInPagesAndSort("Nom.*2003w11|ProjectStatus","{[123]}","\\[[A-Z]
*\\]")]] ', count = 1, global re = <module 're' from 'C:\Program
Files\python\lib\re.pyc'>, global subn = undefined, scan_re =
<_sre.SRE_Pattern object at 0x006BF008>, self =
<MoinMoin.parser.wiki.Parser instance at 0x008465D0>, global replace =
undefined
940 ##if not count: self._check_p()
941 self._check_p()
c:\Program Files\python\Lib\site-packages\MoinMoin\Page.py in
send_page(self=<MoinMoin.PageEditor.PageEditor instance at 0x00808F30>,
request=<MoinMoin.request.Request instance at 0x00706FA8>, msg='',
**keywords={'content_only': 1, 'hilite_re': None})
477 else:
478 # parse the text and send the page content
479 Parser(body, request).format(self.formatter)
Parser = <class MoinMoin.parser.wiki.Parser at 0x008547E0>, body
= 'Please feel free to experiment here, after the
...1|ProjectStatus","{[123]}","\\[[A-Z]*\\]")]]\n\n', request =
<MoinMoin.request.Request instance at 0x00706FA8>, global format =
undefined, self = <MoinMoin.PageEditor.PageEditor instance at
0x00808F30>, global formatter = undefined
480
481 # check for pending footnotes
c:\Program Files\python\Lib\site-packages\MoinMoin\PageEditor.py in
sendEditor(self=<MoinMoin.PageEditor.PageEditor instance at 0x00808F30>,
**kw={'comment': '', 'preview': '##language:en\r\nPlease feel free to
experiment...ojectStatus","{[123]}","\\[[A-Z]*\\]")]]\r\n\r\n'})
349 '
style="background-image:url(%s/img/draft.png);
background-color:#F4F4F4;">'
350 '<tr><td>' % config.url_prefix)
351 self.send_page(self.request, content_only=1,
hilite_re=badwords_re)
self = <MoinMoin.PageEditor.PageEditor instance at 0x00808F30>,
global send_page = undefined, global request = undefined, global
content_only = undefined, global hilite_re = undefined, badwords_re =
None
352 self.request.write('</td></tr></table>')
353
c:\Program Files\python\Lib\site-packages\MoinMoin\wikiaction.py in
do_savepage(pagename='WikiSandBox', request=<MoinMoin.request.Request
instance at 0x00706FA8>)
586 if request.form.has_key('button_preview') or
request.form.has_key('button_spellcheck') \
587 or request.form.has_key('button_newwords'):
588 pg.sendEditor(preview=savetext, comment=comment)
pg = <MoinMoin.PageEditor.PageEditor instance at 0x00808F30>,
global sendEditor = undefined, global preview = undefined, savetext =
'##language:en\r\nPlease feel free to
experiment...ojectStatus","{[123]}","\\[[A-Z]*\\]")]]\r\n\r\n', comment
= ''
589 elif request.form.has_key('button_cancel'):
590 pg.sendCancel(savetext, datestamp)
c:\Program Files\python\Lib\site-packages\MoinMoin\cgimain.py in
run(properties={})
210 else:
211 try:
212 cgitb.handler()
cgitb = <module 'MoinMoin.support.cgitb' from
'C:\PROGRA...on\lib\site-packages\MoinMoin\support\cgitb.pyc'>, handler
= <function do_savepage at 0x00807830>
213 except:
214 cgi.print_exception(*saved_exc)
-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn