Peter Herndon | 1 Apr 2006 01:38
Picon
Gravatar

Re: XML from scratch and transformation with XSLT

On Mar 31, 2006, at 2:46 PM, Marc Garcia wrote:

> I want to make a simple program in python that get data from a  
> database
> (or other source), create a new xml document with it and then parse it
> with an existing xslt sheet.
>

Why would you do this?  That is, you are pulling data from a database  
into Python, then transforming it into XML, then running that XML  
through an XSLT transformation.  Why not pull the data into Python,  
manipulate them in Python, then output as the end-result XML?  That  
is, transcribe from Python directly to the desired final XML format?

I can think of a couple of reasons to do it your way -- the XSLT  
engine might well be faster than the Python transformation, it might  
be easier to output simple XML and then expand it via XSLT, etc. --  
but I'm wondering if you've considered the above simpler path?  It  
might make your life easier.

> Do somebody know what is the simplest way to achieve it? I'm having  
> some
> problems with all of it (encoding problems, installation bugs, more  
> than
> one library required...) and I need some expert tips to know what  
> way I
> have to work on.
>

I'm hardly an expert, and your email doesn't present enough data to  
(Continue reading)

Marc Garcia | 2 Apr 2006 01:11

Re: XML from scratch and transformation with XSLT

Thanks for your opinion Peter, it have been useful to me.

I'm used to do transformations directly when I get data from database, 
but I think that this new way make applications easier to maintain, the 
code is logically divided, and the this is more clear.

The ElementTree is good, and for me the best would be use the lxml 
implementation so it have xslt support, but it isn't a rpm package and 
is difficult for me install it in my fedora server without development 
environment.

Finally I did it with libxml2/libxslt, after solving some encoding 
problems. Probably I'll develop my own class, to abstract it, and to 
make it easy if in the future I want to change this library.

Thanks,
  Marc

Peter Herndon wrote:

> On Mar 31, 2006, at 2:46 PM, Marc Garcia wrote:
>
>> I want to make a simple program in python that get data from a  database
>> (or other source), create a new xml document with it and then parse it
>> with an existing xslt sheet.
>>
>
> Why would you do this?  That is, you are pulling data from a database  
> into Python, then transforming it into XML, then running that XML  
> through an XSLT transformation.  Why not pull the data into Python,  
(Continue reading)

Todd O'Bryan | 4 Apr 2006 18:28
Picon

PyXML install problems on Mac OS X

I hope this is the right place to ask about this...

I have Mac OS X, 10.4.6 (updated this morning) with the new Python  
2.4.3 Universal Binary just released at python.org.

I'm trying to install PyXML, but having problems. It appears that,  
for some reason, gcc is not looking in /usr/include for header files.  
I've tried looking through setup.py to see what was going on, but I'm  
a Python newbie and just got lost in the code.

For reference, /usr/include/limits.h does exist, and which gcc  
produces /usr/bin/gcc which is a link to /usr/bin/gcc-4.0 which seems  
to be the binary.

Any ideas? Output of python setup.py build is given below.

Thanks,
Todd

running build
running build_py
running build_ext
building '_xmlplus.parsers.pyexpat' extension
gcc -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk - 
fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd - 
fno-common -dynamic -DNDEBUG -g -DXML_NS=1 -DXML_DTD=1 - 
DBYTEORDER=4321 -DXML_CONTEXT_BYTES=1024 -DHAVE_MEMMOVE=1 - 
Iextensions/expat/lib -I/Library/Frameworks/Python.framework/Versions/ 
2.4/include/python2.4 -c extensions/pyexpat.c -o build/ 
temp.macosx-10.4-fat-2.4/extensions/pyexpat.o
(Continue reading)

Tom Kacvinsky | 5 Apr 2006 19:53
Favicon

Question about licenses of various pieces of PyXML

All,

I have a question about the licenses associated with various bits and
pieces of PyXML.

In particular, I would like to know which files in the PyXML package are
associated with the various subpackages of PyXML (for instance, most of
the stuff in xpath is associated with the 4DOM subpackage).  From that, I
figure out the license associated with the file (by mapping that file to
the subpackage and from there to the license for that subpackage).

For the most part, I've been able to figure this out, but there are some
files in PyXML that have defied any such mapping.

Any ideas on how I should proceed?

Thanks,

Tom
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

Martin v. Löwis | 10 Apr 2006 11:13
Picon
Gravatar

Re: PyXML install problems on Mac OS X

Todd O'Bryan wrote:
> I'm trying to install PyXML, but having problems. It appears that,  
> for some reason, gcc is not looking in /usr/include for header files.  
> I've tried looking through setup.py to see what was going on, but I'm  
> a Python newbie and just got lost in the code.

> gcc -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk - 
> fno-strict-aliasing -Wno-long-double -no-cpp-precomp -mno-fused-madd - 
> fno-common -dynamic -DNDEBUG -g -DXML_NS=1 -DXML_DTD=1 - 
> DBYTEORDER=4321 -DXML_CONTEXT_BYTES=1024 -DHAVE_MEMMOVE=1 - 
> Iextensions/expat/lib -I/Library/Frameworks/Python.framework/Versions/ 
> 2.4/include/python2.4 -c extensions/pyexpat.c -o build/ 
> temp.macosx-10.4-fat-2.4/extensions/pyexpat.o

My guess is that this comes form the -isysroot option.

This option does not come from PyXML, nor does it come from stock
Python 2.4, so I guess it is something that the Universal Binary
added. You should ask on the python-mac list for advice.

Regards,
Martin
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

Martin v. Löwis | 10 Apr 2006 11:17
Picon
Gravatar

Re: Question about licenses of various pieces of PyXML

Tom Kacvinsky wrote:
> Any ideas on how I should proceed?

You should ask on this list which specific files you are interested
in.

Regards,
Martin
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

shhpa | 11 Apr 2006 07:35

SPAM-ALERT! Mail System Error - Returned Mail

?^by&~HA?O?b?|??&?!?d'????>j?\C??wY?~)J#I/].??)AXo?y>M?2
&J???r?;?MU?"?Hn|?!N] u[?0??]H?th??g?a?l???0?????f`?,?.?a>e?q?&??M??ae%???n?^?$??sOg??7d?</s??D????Th?cxq?o$?^?!
?<?F.?q??P?n?%mE#OC(,?Yb??ThY??X<#?NoLc??l?-6bK???C?a&CQ???K??Pe??<rTh?l???O??0dI?DLy?1??E???????c?XD
?{?b????dA&??C_?W????2??\?N
$ae???????oqq-cao:???g?`???CQ<?o??$??6c?E?{1?O?u"??OAe??2w??C?>?o????e??;?q??gaI?f?[`???(7g?Ae$|(mZ?A?b?h1?vO$a?}??(fA??AeN)f?V??~?[&?e??c
 9?v?u?S?}o?Eaa???.I?a%??C?U8?q?c?gre?
??`J/Aqd2"ct????D?hv??uV??uE??'_O#A?iI??,oV"?9?,a]?
?^'?V??lev\?#y?G?ae????aC??S????hI?d;?,?#~>
???,?s?0S^*?^Th??Va?M?O?N?j?7?(a}O??z?op?X????L[?,JAeuI<
???jmZ6??O?BYK??Nd???d)??AerO????"????VzU
|DR?EcLR?Ab????UA?x9?????<??Nt??GN?1*0??E?y{Aa%?????oF????y??O!
?Q?/???o???h?ya??c???6??|????EN(?Th?ae?[:??bm?0?th?th??i???&Wi?$c?*c??>?n?A?q|/ae?NDoLA?Mi?D?Kc???wN??>??JUW0
y???UO?2D???R??kC?_1z????7daeEW;?Zo?Y??u???9?
????J?c??v??x?wi???OJ?^Y??Y<xg?xdiEZ?c??O??T?g?Ae??C??Qd?3??{Fi/?R?t?z*???????l??P???_ATh?_ReR}??
E??|?b7???*0?)?>[Ae??{w???g?yU????AeC?*???0z???`O~S?`c>%z?
J??oT??a?0#u?fn??s'???7?t%U?/QG?????cr;ib?NoX.?IEa?
Th?E*?n?OOY)az?g8O?????0.??cFC(?
iaAoo?{???PMR?thYo?Z???"n???C?#h??i;Ep??\!?
D?e/tG?
?|??e#??n?k??x*?`??l?\D?O*O??h?e?ll????rCf?????BMdDL?|tfYh?IZpNT$4-?'Zu?.???U?AE<r|?0?.Q#,?{?{en??4M??? ,G?Ra`?ThBe?
?aGc?_\?
 [ ??9E?to
eZD?LS?F`???/?Oa"?th????j|???N?-j]?C?a)?;Ac?E?D)oB?????wg???Q2l?C??8??J?$???#oJ??N?.)w AKh?x??th?.?zd(?I&?L<?Lb??jV
(UPO?
:DLGh?Waq?uCp_??D???C??)\
?B???(?0kNh'C0?S
S???$?b/p??OzE-?????bEX??Uhg???Di????

(Continue reading)

Andy-Kim Möller | 11 Apr 2006 13:18

.NET webservice ws 2004 digital signature and soap

Hello,

I try to connect to .NET soap webservice. The messages must have a 
signature confirm to ws - security 2004 with
enveloping mode.
I tried to build it with ZSI, but i hang at the signature. After this i 
tried to us pyxmlsec which build a signature, but not confirm to the ws 
2004 standard.
Right now i try to do it by hand but i am still not able to get the 
right digest.

As a short explanation using following template:

<?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope 
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"

xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"

xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"

xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><soapenv:Header><wsse:Security><wsse:BinarySecurityToken 
Id="binarytoken"

ValueType="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3"

elementEncoding="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0#Base64Binary">{HERE 
IS THE CERTIFICATE IN DER FORMAT AND BASE64 
ENCODED}</wsse:BinarySecurityToken><ds:Signature 
xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
(Continue reading)

Tom Kacvinsky | 12 Apr 2006 19:17
Favicon

Re: Question about licenses of various pieces of PyXML

Hi Martin,

Here is what I am interested in:

_xmlplus/dom/ext/Dom2Sax.py
_xmlplus/dom/ext/XHtml2HtmlPrinter.py
_xmlplus/dom/ext/XHtmlPrinter.py
_xmlplus/dom/html/GenerateHtml.py
_xmlplus/dom/javadom.py
_xmlplus/dom/minicompat.py
_xmlplus/dom/minidom.py
_xmlplus/dom/pulldom.py
_xmlplus/dom/xmlbuilder.py
_xmlplus/dom/expatbuilder.py
_xmlplus/utils/characters.py

Thanks,

Tom

Martin v. Löwis wrote:
> Tom Kacvinsky wrote:
>> Any ideas on how I should proceed?
> 
> You should ask on this list which specific files you are interested
> in.
> 
> Regards,
> Martin
> 
(Continue reading)

Martin v. Löwis | 14 Apr 2006 21:27
Picon
Gravatar

Re: Question about licenses of various pieces of PyXML

Tom Kacvinsky wrote:
> _xmlplus/dom/ext/Dom2Sax.py
> _xmlplus/dom/ext/XHtml2HtmlPrinter.py
> _xmlplus/dom/ext/XHtmlPrinter.py
> _xmlplus/dom/html/GenerateHtml.py

These are all from 4DOM.

> _xmlplus/dom/javadom.py

This was originally written by Lars Marius Garshol.
He did not state a specific license.

> _xmlplus/dom/minicompat.py
> _xmlplus/dom/minidom.py
> _xmlplus/dom/pulldom.py
> _xmlplus/dom/xmlbuilder.py
> _xmlplus/dom/expatbuilder.py

They are all licensed under the PSF license.

> _xmlplus/utils/characters.py

This is my work; I hereby license it under the Academic Free License,
version 2.1.

Regards,
Martin
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
(Continue reading)


Gmane