STATUS changed from assigned to closed RESOLUTION set to fixed Thanks for the patch! Applied to trunk in r1255 and to 0.7.x in r1256 .
I made a simple patch for trunk (0.8dev) to be able to handle CRLF line break. I confirmed all tests are passed on py26, py27, py32, py33. Could you review it? attachment:suppress-linebreaks-...
ATTACHMENT set to suppress-linebreaks-with-crlf.patch
Then, I finally understood. This issue happens when the template has rn line break. I can accept to avoid extra character using only n for the template. However, in case the email-template, RFC ...
Is this difficult to fix? or is there any workaround?
It turns out this is caused by a combination of Genshi changing from loading templates with file mode "U" to opening them with file mode "rb" in 0.7, and of this particular Trac template having ...
Replying to jomae : > The multiline strings don't have -escape at end of line. Oops. You are correct. I will fix the tests. Adding t = r""" doesn't change the result though, so ...
Replying to hodgestar : >>>> t = """$ticket_body_hdr...""" The multiline strings don't have -escape at end of line. >>> t = """aaaaa ... bbbbbb ... ccccc""" >>> print t aaaaa b...
OWNER changed from cmlenz to hodgestar STATUS changed from new to assigned
My example is missing a >>> from genshi.template.text import NewTextTemplate at the top.
This bit of Python code works fine for me on 0.7: >>> t = """$ticket_body_hdr ... $ticket_props ... {% choose ticket.new %} ... {% when True %} ... $ticket.description ... {%...
This is what Trac uses: $ticket_body_hdr $ticket_props {% choose ticket.new %} {% when True %} $ticket.description {% end %} {% otherwise %} {% if changes_body�...
There are tests for this in 0.7 and they appear to pass. Could you provide a short example showing the problem?
This sounds like a regression in 0.7.