Malthe Borch wrote:
2009/7/11 Wichert Akkerman <wich...@wiggy.net>:
This looks like a bug. Genshi syntax is pretty explicit about this
having to work; it is an integral part of dynamic XIncludes for example.


Definitely.
Attached is a patch with a doctest showing the error.

Thanks,
Alberto


Index: src/chameleon/genshi/template.txt
===================================================================
--- src/chameleon/genshi/template.txt	(revision 5914)
+++ src/chameleon/genshi/template.txt	(working copy)
@@ -82,4 +82,18 @@
   </div>
   
 
+XML template
+------------
 
+XML can be generated too and non-XHTML attributes can contain expressions
+
+
+  >>> print GenshiTemplate("""\
+  ... <WMS_MS_Capabilities xmlns:py="http://genshi.edgewall.org/";
+  ...      xmlns:xlink="http://www.w3.org/1999/xlink";>
+  ...   <OnlineResource xlink:href="${service_url}" />
+  ... </WMS_MS_Capabilities>
+  ... """)(service_url='http://example.com/wms?')
+  <WMS_MS_Capabilities xmlns:xlink="http://www.w3.org/1999/xlink";>
+    <OnlineResource xlink:href="http://example.com/wms?"; />
+  </WMS_MS_Capabilities>
Index: setup.py
===================================================================
--- setup.py	(revision 5914)
+++ setup.py	(working copy)
@@ -1,6 +1,6 @@
 from setuptools import setup, find_packages
 
-version = '1.0b4'
+version = '1.0b5-dev'
 
 install_requires = [
     'setuptools',
_______________________________________________
Repoze-dev mailing list
Repoze-dev@lists.repoze.org
http://lists.repoze.org/listinfo/repoze-dev

Reply via email to