On Jun 19, 5:02 pm, "Hr. Johannes Loose" <[EMAIL PROTECTED]>
wrote:
> Am 18 Jun 2008 um 14:23 hat Erik Bray geschrieben:
>
> > I took a quick scan through the latest version of it, but no obvious
> > problems jumped out at me.  How is it broken?
>
> I have the WikiTicketCalendarMacro currently running under 0.11rc2, it's 
> running fine under
> the current  0.12 trunk, too. But I had to do some code changes to get it to 
> run, which should
> be regarded rather 'quick and dirty' than real bugfixes.
>
> a) Usingmod_wsgithere is a problem with writing to sys.stdout. As a 
> workaround I added the
> line 'sys.stdout = sys.stderr'.

Please try and get the WikiTicketCalendarMacro fixed rather than use
the hack. The code shouldn't use 'print' to try and output debugging
as it will not work under CGI-WSGI bridge, or other WSGI adapters that
use stdin/stdout for communicating with web server. Although mod_wsgi
doesn't use stdin/stdout in this way, for that reason mod_wsgi
specifically denies it as well to promote portability. If people keep
working around it, the problems in original code will never be fixed
and keep tripping people up.

If original code wants to output debugging, at worst they should use:

  print >> sys.stderr, ......... original arguments ......

Ie., direct output of 'print' to sys.stderr explicitly.

At best, they should use whatever mechanism Trac may use to get a
handle on appropriate log file for output.

Graham

> b) If there are accents (special chars like german umlauts) in the 
> description of tilestones or
> tickets, the calendar will fail to load. Alex gave the hint that this 
> behaviour could be changed
> '...by changing the line "from cStringIO import StringIO" to "from StringIO 
> import StringIO"'.
>
> b) Finally search for 'celpadding' and correct the typo.
>
> Note, that there is a ticket (#3159) on track hacks, describing that 
> shortcomings. With that
> points patched, the plugin is running really fine.
>
> Johannes
--~--~---------~--~----~------------~-------~--~----~
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