Discussion:
Aghh
Mitar
2011-05-28 22:07:04 UTC
Permalink
Hi!

0.6 version of Genshi really broke things. For example, <py:match
path="fieldset//p[1]"> still selects all paragraphs and not just the
first one in the fieldset. Are there any plans for 0.6.1 bugfix
version? Currently it is really hard to theme Trac. Am I the only one
doing that? ;-)


Mitar
--
You received this message because you are subscribed to the Google Groups "Genshi" group.
To post to this group, send email to ***@googlegroups.com.
To unsubscribe from this group, send email to genshi+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/genshi?hl=en.
Dalton Barreto
2011-05-29 15:09:55 UTC
Permalink
Post by Mitar
Hi!
0.6 version of Genshi really broke things. For example, <py:match
path="fieldset//p[1]"> still selects all paragraphs and not just the
first one in the fieldset. Are there any plans for 0.6.1 bugfix
version? Currently it is really hard to theme Trac. Am I the only one
doing that? ;-)
Hello Mitar,

I have a themed Trac instance (0.12.2) [1]. Didn't have any major
problem with genshi 0.6, but perhaps I just didn't hit this bug. The
site.html used to build this custom Trac is on my github [2]

Thanks.

[1] http://dev.wsgid.com/
[2] https://github.com/daltonmatos/wsgid.com/tree/master/trac-custom
--
Dalton Barreto
http://daltonmatos.wordpress.com
http://wsgid.com
--
You received this message because you are subscribed to the Google Groups "Genshi" group.
To post to this group, send email to ***@googlegroups.com.
To unsubscribe from this group, send email to genshi+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/genshi?hl=en.
Simon Cross
2011-05-29 20:13:39 UTC
Permalink
Post by Mitar
0.6 version of Genshi really broke things. For example, <py:match
path="fieldset//p[1]"> still selects all paragraphs and not just the
first one in the fieldset. Are there any plans for 0.6.1 bugfix
version? Currently it is really hard to theme Trac. Am I the only one
doing that? ;-)
Could you post an actual test case? This appears to work for me on
Post by Mitar
from genshi.input import XML
doc = XML('''<doc><fieldset><p>Foo</p><p>Bar</p><p>Baz</p></fieldset></doc>''')
list(doc.select("fieldset//p[1]"))
[('START', (QName('p'), Attrs()), (None, 1, 15)), ('TEXT', u'Foo',
(None, 1, 18)), ('END', QName('p'), (None, 1, 21))]

Schiavo
Simon
--
You received this message because you are subscribed to the Google Groups "Genshi" group.
To post to this group, send email to ***@googlegroups.com.
To unsubscribe from this group, send email to genshi+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/genshi?hl=en.
Mitar
2011-05-30 09:47:42 UTC
Permalink
Hi!
Post by Simon Cross
Could you post an actual test case? This appears to work for me on
I use it in Trac's site.html:

<py:if test="req.environ['PATH_INFO'] == '/register'">
<py:match path="fieldset//p[1]">
<p class="hint">
${select('*|text()')} This information is also used for email
notifications, for example.
</p>
</py:match>
</py:if>

And it is applied to this template:

http://trac-hacks.org/browser/accountmanagerplugin/trunk/acct_mgr/templates/register.html

More specific, it changes both paragraphs:

<p>The email address is required for Trac to send you a verification token.</p>
<p py:if="reset_password_enabled">Entering your email address will
also enable you to reset your password if you ever forget it.</p>

Hm. OK. Now I am not sure anymore if this particular instance worked
in 0.5 version. I am all the time having problems with this one:

http://genshi.edgewall.org/ticket/370

and then am not sure if somebody else is also broken. ;-)


Mitar
--
You received this message because you are subscribed to the Google Groups "Genshi" group.
To post to this group, send email to ***@googlegroups.com.
To unsubscribe from this group, send email to genshi+***@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/genshi?hl=en.
Loading...