Very sorry for two emails.

I deleted the contents of the project's plugins  directory and placed only
the helloworld.py file.  It worked. There was another plugin with an error
that was causing the helloworld to fail.

My real goal was to create a macro that used the wiki formatter.  I tried
using the code at the bottom of the page:
http://trac.edgewall.org/wiki/TracWikiMacros

This is the code that was causing the problem.  The code on the WIKI reads:
        Formatter(formatter.context).format(text, out)

I was able to get it working by using the following code:
        Formatter(formatter.env,formatter.context).format(text, out)

Should the page be updated?

-Ken


-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of Ken Richard
Sent: Friday, January 18, 2008 8:40 AM
To: [email protected]
Subject: [Trac] Macro Help


Hello!

I am having some trouble getting custom macros to run on 0.11.  There is a
page on the trac wiki with a sample macro:
http://trac.edgewall.org/wiki/TracWikiMacros#Macrowitharguments

The macro file is in my projects/plugins directory and I know it is
compiling because I can see the .pyc file.  When I add the macro to a wiki
page and view the page, I get the following error:

Error: Macro HelloWorld(test) failed
__init__() takes exactly 3 arguments (2 given)

Is there something wrong with my setup?  Or am I looking in the wrong place
for a sample wiki macro?

Thanks,
Ken






--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/trac-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to