From martin@v.loewis.de Wed May 1 09:37:06 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 01 May 2002 10:37:06 +0200 Subject: [XML-SIG] Fwd: Re: bug in c14n.py In-Reply-To: <200204262128.RAA01887@tux.w3.org> References: <200204262128.RAA01887@tux.w3.org> Message-ID: Joseph Reagle writes: > I've fixed the bug I reported below. I've also attached the test files and > expected results in a zip file (in the tests subdirectory) from Gregor that > led me to find these recent bugs. Thanks for the patches. Since I'm not really qualified to judge their correctness, can you please put them onto SourceForge (sf.net/projects/pyxml). Please create context diffs (-c) if you can, that way, it is easier to see what version you started from. Regards, Martin From rsalz@datapower.com Wed May 1 12:10:58 2002 From: rsalz@datapower.com (Rich Salz) Date: Wed, 1 May 2002 07:10:58 -0400 Subject: [XML-SIG] Fwd: Re: bug in c14n.py Message-ID: <200205011110.g41BAwX19433@eagle.datapower.com> I've been busy changing jobs, but the pathes are okay to check in. From rfjackson@attbi.com Thu May 2 03:14:24 2002 From: rfjackson@attbi.com (R.Jackson) Date: Wed, 01 May 2002 19:14:24 -0700 Subject: [XML-SIG] xml Message-ID: <3CD0A0FF.AB658716@attbi.com> --------------BA17648705760DC46C3272E5 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit OEM’s, Systems Integrators, and IT Professionals The easiest way to create, validate, share and store XML documents is here: 4vision, Inc. has developed an innovative Web services based product called the Visual XML Schema Designer, which is a collaborative application for building, and managing XML Schemas and XML documents. The tool kit consists of an easy to use visual schema editor that is used to visually create and automatically validate XML Schemas, which are used to define your digital assets. The schema editor supports a project folder based metaphor in which any number of project folders can be created to contain any number of different domain based schemas. In addition the product is comprised of a peer-to-peer Web Server that provides services for: - Managing native-XML data stores for fast database access. - Storage and retrieval of XML data via HTTP, TCP/IP, SOAP. - Distributed administrative management. - Instant messaging. - XML messaging. - Secure XML transactions and trusted Web Services. - In the next release built-in UDDI, WSDL support, and GUI Builder toolkit which builds HTML, Java based GUI's from schemas. The Visual XML Schema Designer takes all the technical complexity out of understanding, using and collaborating across multiple XML Schemas projects. In fact it is so easy to use that it is being used by non-technical personnel in a law firm to create repositories of validated legal schemas of all documents used by the firm. The product runs on all Windows, and Unix platforms. For more information visit our Web site at: http://4vision.linksysnet.com:8081/ 4vision, Inc. is interested in strategic partnerships and alliances and can provide in-depth technical descriptions of our core technologies and products. Please contact our CTO Wilbert Jackson at wjackson@attbi.com --------------BA17648705760DC46C3272E5 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: 8bit OEM’s, Systems Integrators, and IT Professionals

The easiest way to create, validate, share and store XML documents is here:

4vision, Inc. has developed an innovative Web services based product called the Visual XML Schema Designer, which is a collaborative application for building,
and managing XML Schemas and XML documents. The tool kit consists of an easy to use visual schema editor that is used to visually create and automatically
validate XML Schemas, which are used to define your digital assets. The schema editor supports a project folder based metaphor in which any number of project
folders can be created to contain any number of different domain based schemas. In addition the product is comprised of a peer-to-peer Web Server that provides
services for:

- Managing native-XML data stores for fast database access.
- Storage and retrieval of XML data via HTTP,  TCP/IP, SOAP.
- Distributed administrative management.
- Instant messaging.
- XML messaging.
- Secure XML transactions and trusted Web Services.
- In the next release built-in UDDI, WSDL support, and GUI Builder toolkit which builds HTML, Java based GUI's from schemas.

The Visual XML Schema Designer takes all the technical complexity out of understanding, using and collaborating across multiple XML Schemas projects. In fact it is so easy to use that it is being used by non-technical personnel in a law firm to create repositories of validated legal schemas of all documents used by the firm.

The product runs on all Windows, and Unix platforms.

For more information visit our Web site at: http://4vision.linksysnet.com:8081/

4vision, Inc. is interested in strategic partnerships and alliances and can provide in-depth technical descriptions of our core technologies and products. Please contact
our CTO Wilbert Jackson at wjackson@attbi.com
 
 
 
 
  --------------BA17648705760DC46C3272E5-- From loewis@informatik.hu-berlin.de Thu May 2 13:04:34 2002 From: loewis@informatik.hu-berlin.de (Martin v. =?iso-8859-1?q?L=F6wis?=) Date: 02 May 2002 14:04:34 +0200 Subject: [XML-SIG] PyXML 0.7.1 release Message-ID: Version 0.7.1 of the Python/XML distribution is now available. It should be considered a beta release, and can be downloaded from the following URLs: http://prdownloads.sourceforge.net/pyxml/PyXML-0.7.1.tar.gz http://prdownloads.sourceforge.net/pyxml/PyXML-0.7.1.win32-py1.5.exe http://prdownloads.sourceforge.net/pyxml/PyXML-0.7.1.win32-py2.1.exe http://prdownloads.sourceforge.net/pyxml/PyXML-0.7.1.win32-py2.2.exe http://prdownloads.sourceforge.net/pyxml/PyXML-0.7.1-1.5.2.i386.rpm http://prdownloads.sourceforge.net/pyxml/PyXML-0.7.1-2.2.i386.rpm Changes in this version, compared to 0.7: * sgmlop offers the XMLUnicodeParser (contributed by Walter D=F6rwald). * setup.py now supports the option --with(out)-pyexpat. * On Mac OS X, -flat_namespace is used to build extensions. * XBEL support for parsing Opera, MSIE, and Netscape bookmarks was improved. * c14n is now documented in the reference manual. * Support for older expat versions is dropped from pyexpat. * pyexpat can intern strings found during parsing in a dictionary. * xml.ns now provides XLINK and RNG namespaces. * 4DOM supports now arbitrary Unicode element and attribute names. * pulldom supports the iterator protocol. * Spanish xmlproc messages have been added. * xml.sax.expatreader has a feature to intern strings, and a property to access the interning dictionary. * Construction of Unicode regular expressions in xml.utils.characters happens lazily through accessor functions. * Various bugs have been fixed (4DOM, minidom, c14n, marshal.generic, xmlproc, sax.expatreader, sax.writer, xml.utils.iso8601) The Python/XML distribution contains the basic tools required for processing XML data using the Python programming language, assembled into one easy-to-install package. The distribution includes parsers and standard interfaces such as SAX and DOM, along with various other useful modules.=20=20 The package currently contains: * XML parsers: Pyexpat (Jack Jansen), xmlproc (Lars Marius Garshol), sgmlop (Fredrik Lundh). * SAX interface (Lars Marius Garshol) * minidom DOM implementation (Paul Prescod) * 4DOM and 4XPath from Fourthought (Uche Ogbuji, Mike Olson) * Schema implementations: TREX (James Tauber) * Various utility modules and functions (various people) * Documentation and example programs (various people) The code is being developed bazaar-style by contributors from the Python XML Special Interest Group, so please send comments, questions, or bug reports to . For more information about Python and XML, see: http://www.python.org/topics/xml/ --=20 Martin v. L=F6wis http://www.informatik.hu-berlin.de/~loewis From phthenry@earthlink.net Fri May 3 05:03:18 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Fri, 3 May 2002 00:03:18 -0400 Subject: [XML-SIG] help getting started Message-ID: <20020503000317.A27628@localhost.localdomain> Hello! I have switched from perl to python because I thought python would be better to parse xml. However, I am having a hard time getting started. I have a specific question below, but perhaps I should ask where I can find documentation for parsing xml with python. I had considered buying the O'Reilly book on xml and python until I looked at it at a local bookstore. The chapter on sax seems rather short and bare of examples. I am still considering buying it. Have other people found this book helpful? I have also found very few tutorials on line. The two I did find, linked to python.org, were incomplete. That brings me to my specific quetion: I have copied exactly the script from: http://pyxml.sourceforge.net/topics/howto/SAX.html I am getting this error: Traceback (most recent call last): File "/home/paul/paultemp/parser.test.py", line 15, in ? class FindIssue(saxutils.DefaultHandler): AttributeError: 'xml.sax.saxutils' module has no attribute 'DefaultHandler' I am guessing this means that saxutils has no DefaultHandler class, though I'm really not sure. I've included a complete copy of the script below Thanks in advance! Paul *************************************** #!/usr/bin/python from xml.sax import saxutils from xml.sax import make_parser from xml.sax.handler import feature_namespaces #from xml.sax import Contenthandler #class docHandler(ContentHandler): class FindIssue(saxutils.DefaultHandler): def __init__(self, title, number): self.search_title, self.search_number = title, number def startElement(self, name, attrs): # If it's not a comic element, ignore it if name != 'comic': return # Look for the title and number attributes (see text) title = attrs.get('title', None) number = attrs.get('number', None) if title == self.search_title and number == self.search_number: print title, '#'+str(number), 'found' if __name__ == '__main__': file = "/home/paul/paultemp/test.xml" # Create a parser parser = make_parser() # Tell the parser we are not interested in XML namespaces parser.setFeature(feature_namespaces, 0) # Create the handler dh = FindIssue('Sandman', '62') # Tell the parser to use our handler parser.setContentHandler(dh) # Parse the input parser.parse(file) -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From uche.ogbuji@fourthought.com Fri May 3 04:57:23 2002 From: uche.ogbuji@fourthought.com (Uche Ogbuji) Date: Thu, 02 May 2002 21:57:23 -0600 Subject: [XML-SIG] 'Strange' behaviour of TreeWalker In-Reply-To: Message from jpoenninghaus@canopus.lili.uni-bielefeld.de of "Wed, 17 Apr 2002 10:02:53 +0200." <20020417100253.A1424@canopus.uni-bielefeld.de> Message-ID: <200205030357.g433vNR20384@localhost.localdomain> > Hi, > > I'm quite new to Python (and pyxml / 4Suite ) and was quite confused by a > 'strange' difference between NodeIterator and TreeWalker. > > While instances of NodeIterator are "printable" and give reasonable > error messages, eg. accessing undefined attributes, instances of TreeWalker > give hard times to novice users as __getattr__() effectively prevents any such > access without reasonable message. > > Is that the intended behaviour or just an unwanted side-effect? > At least, a note in the docs might be valuable to others. It comes down to unfortunate implementation needs. I think TreeWalker can be refactored to need less magic once 2.0 is the requirement for PyXML and thus there is no need to worry about reference cycles. -- Uche Ogbuji Fourthought, Inc. uche.ogbuji@fourthought.com http://fourthought.com http://4Suite.org http://uche.ogbuji.net Track chair, XML/Web Services One (San Jose, Boston): http://www.xmlconference.com/ RDF Query using Versa - http://www-106.ibm.com/developerworks/xml/library/x-thi nk10/index.html WSDL and the Wild, Wild West - http://adtmag.com/article.asp?id=6004 XML, The Model Driven Architecture, and RDF @ XML Europe - http://www.xmleurope.com/2002/kttrack.asp#themodel From uche.ogbuji@fourthought.com Fri May 3 05:03:06 2002 From: uche.ogbuji@fourthought.com (Uche Ogbuji) Date: Thu, 02 May 2002 22:03:06 -0600 Subject: [XML-SIG] xml In-Reply-To: Message from "R.Jackson" of "Wed, 01 May 2002 19:14:24 PDT." <3CD0A0FF.AB658716@attbi.com> Message-ID: <200205030403.g43436h20419@localhost.localdomain> > 4vision, Inc. is interested in strategic partnerships and alliances and= > can provide in-depth technical descriptions of our core technologies an= d > products. Please contact > our CTO Wilbert Jackson at wjackson@attbi.com Cool name. Why didn't I think of something like that? :-) What the blazes does this have to do with Python/XML, anyway? -- = Uche Ogbuji Fourthought, Inc. uche.ogbuji@fourthought.com http://fourthought.com http://4Suite.org http://uche.ogbuji.net Track chair, XML/Web Services One (San Jose, Boston): = http://www.xmlconference.com/ RDF Query using Versa - http://www-106.ibm.com/developerworks/xml/library= /x-thi nk10/index.html WSDL and the Wild, Wild West - http://adtmag.com/article.asp?id=3D6004 XML, The Model Driven Architecture, and RDF @ XML Europe - = http://www.xmleurope.com/2002/kttrack.asp#themodel From tpassin@comcast.net Fri May 3 06:06:06 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Fri, 03 May 2002 01:06:06 -0400 Subject: [XML-SIG] help getting started References: <20020503000317.A27628@localhost.localdomain> Message-ID: <009901c1f260$3b179cf0$0bf13044@tbp> [Paul Tremblay] > > That brings me to my specific quetion: > > I have copied exactly the script from: > > http://pyxml.sourceforge.net/topics/howto/SAX.html > > I am getting this error: > > Traceback (most recent call last): > File "/home/paul/paultemp/parser.test.py", line 15, in ? > class FindIssue(saxutils.DefaultHandler): > AttributeError: 'xml.sax.saxutils' module has no attribute 'DefaultHandler' > > I am guessing this means that saxutils has no DefaultHandler > class, though I'm really not sure. I've included a complete copy > of the script below > Hmm, I copied your program from your posting. I had to correct some indentation problems in startElement, which I don't know if you had in the original. I copied the example xml file in the how-to. It ran perfectly. I used both Python 1.5.2 and Python 2.1.3 on Windows 2000, pyxml 0.70. I can't be sure what your problem is. It might be indentation, although that wouldn't produce that particular error message, I wouldn't think. Otherwise there might have been a problem with the installation - one of the other people on this list who uses Linux should be able to help on that. But the code is right, at least if you fix the indenting. I guess the most recent version, which I haven't gotten yet, could have changed something that caused the trouble. Martin should know about that. Cheers, Tom P From kevin.mcnamee@datavis.se Fri May 3 08:12:01 2002 From: kevin.mcnamee@datavis.se (Kevin McNamee) Date: Fri, 3 May 2002 09:12:01 +0200 Subject: [XML-SIG] help getting started References: <20020503000317.A27628@localhost.localdomain> Message-ID: <003901c1f271$d25a15f0$e207acac@datavis.se> > > I had considered buying the O'Reilly book on xml and python until > I looked at it at a local bookstore. The chapter on sax seems > rather short and bare of examples. I am still considering buying > it. Have other people found this book helpful? > > I have also found very few tutorials on line. The two I did find, > linked to python.org, were incomplete. > You could also look at http://www.ibiblio.org/xml/books/xmljava/chapters/ch06.html http://www.oreilly.de/catalog/sax2/chapter/ch03.html /Kevin From dkuhlman@cutter.rexx.com Fri May 3 23:47:09 2002 From: dkuhlman@cutter.rexx.com (Dave Kuhlman) Date: Fri, 3 May 2002 15:47:09 -0700 Subject: [XML-SIG] SAX2 driver built on RXP Message-ID: <20020503154709.A11851@cutter.rexx.com> I've packaged the RXP parser for use as a SAX2 driver within PyXML. It's not complete, but seems usable to me. Pro's: Since it is built on RXP which is implemented in C, it is both fast and validating. Con's: (1) Requires building RXP. (2) RXP is covered by the GPL, which probably means that we will never want to include it as part of the PyXML distribution. If it interests you, you can find it at: http://www.rexx.com/~dkuhlman Comments and suggestions and guidance are welcome. - Dave -- Dave Kuhlman dkuhlman@rexx.com http://www.rexx.com/~dkuhlman From allison@sumeru.stanford.EDU Sun May 5 04:35:30 2002 From: allison@sumeru.stanford.EDU (Dennis Allison) Date: Sat, 4 May 2002 20:35:30 -0700 (PDT) Subject: [XML-SIG] Entity managment question -- Message-ID: I'm using the minidom for part of a project and the Zope ParsedXML for the rest. This relates to my experience with the minidom. PyXML 0.7.1, I think. So, I have a bunch of XML some of which uses HTML entities in its text, both in the DATA sections and in the attributes. The minidom parser conversts these entities to Unicode as it's supposed to. Processing ensues. And then the XML or portions of the information it contains needs to be written out. The problem is recapturing the HTML-ish entities that have been converted to unicode. Does such a beast exist? And where can it be found? Alternatively, I could try to subvert the conversions in the first place. I looked at the minidom code in some detail, but I've been unable to grok where to apply pixie dust to have it not convert HTML-ish entities to unicode in the firstplace. So, help. I don't normally read this list so a direct response would be appreciated. BTW, one nice approach would be to extend the current unicode codec translation mechanisms to have a HTML-encoding built-in. Were I not on a deadline with little time to play, I'd give that one a try. Thanks for any help. -dra From phthenry@earthlink.net Sun May 5 05:20:42 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Sun, 5 May 2002 00:20:42 -0400 Subject: [XML-SIG] help getting started [success!] In-Reply-To: <009901c1f260$3b179cf0$0bf13044@tbp> References: <20020503000317.A27628@localhost.localdomain> <009901c1f260$3b179cf0$0bf13044@tbp> Message-ID: <20020505002041.C29706@localhost.localdomain> On Fri, May 03, 2002 at 01:06:06AM -0400, Thomas B. Passin wrote: > > Hmm, I copied your program from your posting. I had to correct some > indentation problems in startElement, which I don't know if you had in the > original. > Yes, I did have some indentation problems I didn't notice. I pasted and copied the file from the web. On top of that, I use Nedit, which continually screws up indentation. Matt Gushee wrote: >It probably means you haven't installed the PyXML package. Yes, I didn't have it installed. I tried to install it, and I got errors. So I went ahead and installed python 2.2. After that, I could install the PyXML package, and the script ran. Thanks! Paul -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From martin@v.loewis.de Sun May 5 08:57:32 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 05 May 2002 09:57:32 +0200 Subject: [XML-SIG] Entity managment question -- In-Reply-To: References: Message-ID: Dennis Allison writes: > The problem is recapturing the HTML-ish entities that have been converted > to unicode. Does such a beast exist? And where can it be found? Why is it desirable to restore those entities? I can offer a number of alternatives: - generate UTF-8 on output, then you will never ever need to create references - generate character reference instead of entity references Either approach will create well-formed HTML. If you think you must have entity references, you can use the htmlentitydefs module to generate *all* entity references. Regards, Martin From tpassin@comcast.net Sun May 5 15:30:14 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Sun, 05 May 2002 10:30:14 -0400 Subject: [XML-SIG] help getting started [success!] References: <20020503000317.A27628@localhost.localdomain> <009901c1f260$3b179cf0$0bf13044@tbp> <20020505002041.C29706@localhost.localdomain> Message-ID: <000601c1f441$608f9a40$0bf13044@tbp> [Paul Tremblay] > On Fri, May 03, 2002 at 01:06:06AM -0400, Thomas B. Passin wrote: > > > > Hmm, I copied your program from your posting. I had to correct some > > indentation problems in startElement, which I don't know if you had in the > > original. > > > > Yes, I did have some indentation problems I didn't notice. I > pasted and copied the file from the web. On top of that, I use > Nedit, which continually screws up indentation. > I either use IDLE, or an editor like Edit+ which I can set to replace tabs with 4 spaces automatically. No more indentation problems! Lots of editors can do that these days. Cheers, Tom P From allison@sumeru.stanford.EDU Sun May 5 18:00:05 2002 From: allison@sumeru.stanford.EDU (Dennis Allison) Date: Sun, 5 May 2002 10:00:05 -0700 (PDT) Subject: [XML-SIG] Entity managment question -- In-Reply-To: Message-ID: Thanks for the response. The problem is that the unicode representation is not a transparent one. My post was the result of a preprocessor program failing. The preprocessor takes a collection of XML documents, traverses them, modifies and edits them, writes out revised XML, and then constructs table presets for a database that works in conjunction with the XML--the tools are mostly in Python and use the latest PyXML release. The XML representation and stuff derived provide unicode strings. Unfortunatly, many of the other tools fail and die one something as simple as writestream(). I solved my immediate problem by writing a conversion from unicode string to ASCII with embedded HTML-entities and using it where needed. On 5 May 2002, Martin v. Loewis wrote: > Dennis Allison writes: > > > The problem is recapturing the HTML-ish entities that have been converted > > to unicode. Does such a beast exist? And where can it be found? > > Why is it desirable to restore those entities? I can offer a number of > alternatives: > > - generate UTF-8 on output, then you will never ever need to create > references > - generate character reference instead of entity references > > Either approach will create well-formed HTML. If you think you must > have entity references, you can use the htmlentitydefs module to > generate *all* entity references. > > Regards, > Martin > From mail@netmail.de Mon May 6 16:26:00 2002 From: mail@netmail.de (Immer frischer Kaffee) Date: Mon, 6 May 2002 15:26:00 Subject: [XML-SIG] Betreff Message-ID: This is a multipart MIME message. --= Multipart Boundary 0506021526 Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit --= Multipart Boundary 0506021526 Content-Type: application/octet-stream; name="index.htm" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="index.htm" PGh0bWw+DQo8aGVhZD4NCjx0aXRsZT5ORVRNQGlsLUtVUklFUi0gSW1tZXIg ZnJpc2NoZXIgS2FmZmVlITwvdGl0bGU+DQo8bWV0YSBodHRwLWVxdWl2PSJD b250ZW50LVR5cGUiIGNvbnRlbnQ9InRleHQvaHRtbDsgY2hhcnNldD1pc28t ODg1OS0xIj4NCjxzY3JpcHQgb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yaWVyLmRlL2VtYWlsbG9l c2NoZW4uaHRtIiB0YXJnZXQ9Il9ibGFuayI+aGllcjwvYT48L2ZvbnQ+PC9i PiANCiAgICAgIGF1cyB1bnNlcmVyIE1haWxpbmdsaXN0ZSBhdXMuIDwvZm9u dD48L3RkPg0KICA8L3RyPg0KPC90YWJsZT4NCjxicj4NCjxwPiZuYnNwOzwv cD4NCjwvYm9keT4NCjwvaHRtbD4NCg== --= Multipart Boundary 0506021526 Content-Type: application/octet-stream; name="tassegross.jpg" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="tassegross.jpg" /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAHQAA/+4ADkFk b2JlAGTAAAAAAf/bAIQAEAsLCwwLEAwMEBgPDQ8YHBUQEBUcIBcXFxcXIB8Y GxoaGxgfHyQmKSYkHzExNTUxMUFBQUFBQUFBQUFBQUFBQQERDw8SFBIWExMW FREUERUaFRcXFRomGhodGhomMiMfHx8fIzIsLykpKS8sNjYyMjY2QUFBQUFB QUFBQUFBQUFB/8AAEQgASABhAwEiAAIRAQMRAf/EAIUAAAEFAQEAAAAAAAAA AAAAAAABAwQFBgIHAQADAQEAAAAAAAAAAAAAAAAAAgMBBBAAAgEDAgMFBgQF BQAAAAAAAQIAEQMEITFBEgVRYSIyE3GBoUJSBpGxIxTB0XKCQ2KiwjMkEQAC AgIDAQADAQAAAAAAAAAAARECIQMxQRJRYXEiBP/aAAwDAQACEQMRAD8A38Qk CIWrWmgG5jILk81PDwEW10jUh+pMTWcq4I01Mrup9VXGRhzBAPM5/hEdvyCT ZNv5WPYFbrhe7j8JDfruGpoAze7+cxmd9wO7/wDnStfnfUn3Subqee51ucvc FB/KYm3nhfR3SOefiyz0NOvYTmnOyf1LUSZazEuDmQi4vahqfes8tXqWZWhY N3ECTcPrF21cB5jacbEHSbNl2Z4ng9MS4jiqms6lD0vrFvMpbyP08j5bg+aX KXGBCXN+DDYx62TFagehEixjAhCEAOKClOEatMV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2+xjkafVlXtP5Sj6MHYRPfCaA2xrqNpFvCEJB jopOpWEuqQ4rKQ4tyyf0jVfpMIQQ6HLVy4pG6ydbu3D80IQwD9Dy3Aoq7Rf3 bsPTs1VTuYQmqCZZ4CUAUa9ss/UHMEGp/KEIy5FHSaCcJ4nL8BoIQj95AchC E3AH/9k= --= Multipart Boundary 0506021526 Content-Type: application/octet-stream; name="foto2.jpg" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="foto2.jpg" /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAASAAA/+4ADkFk b2JlAGTAAAAAAf/bAIQABAMDAwMDBAMDBAUDAwMFBgUEBAUGBwYGBgYGBwkH CAgICAcJCQsLDAsLCQwMDAwMDBAQEBAQEhISEhISEhISEgEEBAQHBwcOCQkO FA4NDhQUEhISEhQSEhISEhISEhISEhISEhISEhISEhISEhISEhISEhISEhIS EhISEhISEhIS/8AAEQgAUQByAwERAAIRAQMRAf/EAJwAAAICAwEBAAAAAAAA AAAAAAAFBAYCAwcIAQEBAQEBAQEBAAAAAAAAAAAAAAIDAQQFBhAAAQMCAgYE CQgGCwAAAAAAAgADBAEFEgYRIjJSEwchQoIUMUFRYnIjM9MVYXGBocKDkwjR kkOjs8ORsfJTY3PjNFSkFxEBAQABAwQBBQEBAAAAAAAAAAIDARITESIEBTFB UTJCFFIV/9oADAMBAAIRAxEAPwD38gEAgxMwbpiOuGi5VaaCtXTPtgthE3V7 vLoeEGulea/KnRW1VZnN1sSwxYej/MJeevMpfGg/+tzSr7FkPpqp/rpXEmR+ aMsttlk/pqn9lHEeQ+YsR3/cMVb9GulaT5v3Txn0PM9pm1wtvUbPdc1K/Wt4 8mdUbTcTEtmuleia01SyXQIBAIBAIBBy3mrmGZbnI9vbKrMV5o3DPe0dC+X5 mfa3w49zz7euY1ohmTTDjlykbjGx+uvkV5c/Gj7GD1uSvlU3uYVzePE1BbBr znNdeb+m3un1sS2N8wJg4cUET++P3azryba/8+ExnmM+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irUUalTx1QPGmWmRwtBRsfJSmhBmgEAgEAgEAgEAgE AgEAgEAgEAgEH//Z --= Multipart Boundary 0506021526 Content-Type: application/octet-stream; name="automat.jpg" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="automat.jpg" /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAIwAA/+4ADkFk b2JlAGTAAAAAAf/bAIQADgoKCgsKDgsLDhQNCw0UGBIODhIYGxYWFxYWGxoU FxcXFxQaGh8gIyAfGikpLS0pKT07Ozs9QEBAQEBAQEBAQAEPDQ0PEQ8SEBAS FA4RDhQXEhQUEhchFxcZFxchKh4aGhoaHiomKSMjIykmLy8qKi8vOjo4OjpA QEBAQEBAQEBA/8AAEQgAwgBkAwEiAAIRAQMRAf/EAJgAAAEFAQEBAAAAAAAA AAAAAAADBAUGBwIBCAEBAQEBAQAAAAAAAAAAAAAAAAECAwQQAAEDAgMCCQgG CAYDAAAAAAEAAgMRBCESBTEGQVFxsSITcxQ1YYGRMnKy0jShwUJSM0PRYiNT g3QVFoKSosIkB/DhkxEBAQACAQMEAgMAAAAAAAAAAAERAjEhEgNBUZETYVKB IjL/2gAMAwEAAhEDEQA/ANJVPP8A2Po4kdH3a5qxxaTSOmBp+8VwWBz16+4I ND1hxHtOQapHv3pkgqLeccoZ8aV/vTTv3E/oZ8az/TdLurm0Zcm7MbZK5WAV PRNMaUonf9FmO28f/q+JMxMrp/eum/uZ/Q340f3tpv7mb0N+JUgaG6Rzm96d VvG4ivpeFBXzTa3MluayZKdISHGorwFydDq1F2/Wlt2wT+hnxrgb/aUTQQXH oZ8ayN9zj6pH+Ny8bdZT6p/zuV6HVsbN9dOfsgn9DPjS7d6rJ2yGb0N+JZho wdeNe7M6Pq3sZTM5wOfZ9pqu+m7rR3lo2fvcja1BAaaYfxE6HVLS73WEQq6G Y8gb8SktK1OHVLQXcDXMYXFtH0Bq3kJWfa1Yf03UBatldKBiXOJFQ6NzqZS4 7CrfuZ4K3tZOd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QhCAWC3NtE+6mqD+I7YfKVvSzm9/671MSyS2tzDM1znODX5o3UOP6w+lB Sm6bC7Y97fQf0J02ItaAXhxH2i3Hz0cpt+5+8UJA7mZMK1Y+M/7gmz9C1pta 2FxhtpG4j6AlkvJrvvr/AJuEU5jhskYOVhP+9cEyD85g/hH4k+k07UW+taTj ljf8KRdpmpbe5z0PD1T6enKnbr7Nfb5P2psJJmnCdv8A8v0lddbO/bOD/Cb8 SVGl6i40FpOT2T/hTiHQ9ZeehYXDv4T/ANCduvtF+3yftt8kYYHP9aX0RgfW nB0q1mIMzpJMuwAtYP8AS1SNpu5rrsRYygD7wDPfLVKQbq628AugEdcOm9uH LlJVxrOJGL5PJel2titO06wi9S3FeNxLveK0XchoboTQAGjrZMAKDaFGR7j3 cn49zHHtqGNL+TbkVm0jS49KsxaRyOlaHF2ZwANXciWsyXJ+hCFGghCEAhCE AhCEAhCEAhCEAhCEAhCEH//Z --= Multipart Boundary 0506021526-- From LISTSERV@JAVA.SUN.COM Mon May 6 20:04:01 2002 From: LISTSERV@JAVA.SUN.COM (L-Soft list server at Sun Microsystems Inc. (1.8d)) Date: Mon, 6 May 2002 13:04:01 -0600 Subject: [XML-SIG] Message ("Your message dated Mon, 6 May 2002 12:07:02 -0700...") Message-ID: <20020506190520.713DF211CC@swjscmail2.java.sun.com> Your message dated Mon, 6 May 2002 12:07:02 -0700 with subject "A WinXP patch" has been submitted to the moderator of the RMI-USERS list. From brian@sweetapp.com Mon May 6 21:24:05 2002 From: brian@sweetapp.com (Brian Quinlan) Date: Mon, 6 May 2002 13:24:05 -0700 Subject: [XML-SIG] ANN: Pyana 0.4.5 Message-ID: <002a01c1f53b$f82626d0$445d4540@Dell2> Pyana is a XSLT transformation system for Python, based on the Apache Group's Xalan processor. It combines the speed and compliance of the Xalan XSLT processor with convenient access from Python. Key features include: 1. The ability to transform documents from a variety of sources, including URIs, "reader" objects (e.g. Python file objects, StringIO objects) and strings. 2. The ability to extend the XPath language with functions written in Python. 3. Operation completely within the Python process for low overhead. This release adds the following features and fixes: 1. Stylesheets can be precompiled for better performance 2. Source documents can be pre-parsed for better performance 3. Custom entity resolvers can be installed. An entity resolver is a class that can map a URI into a stream. For example, you could use this feature to read your documents from a compressed archive (I've written an example along these lines). 4. Fixed a small memory leak in transformToString 5. More efficient reading of XSL documents from reader objects The Pyana website is at: http://pyana.sourceforge.net You might want to start by looking at the examples: http://pyana.sourceforge.net/examples/ Cheers, Brian From bbirkinbine@earthlink.net Mon May 6 21:32:34 2002 From: bbirkinbine@earthlink.net (Brian Birkinbine) Date: Mon, 6 May 2002 15:32:34 -0500 Subject: [XML-SIG] Python stdlib, pyxml, 4suite? Message-ID: <20020506153234.A9480@core-qe1.charter-stl.com> Could someone explain how the python standard library, pyxml and 4suite all fit together (or refer me to a url to read about an overview of the different package integration) I've been using xml.sax from the Python 2.2 base install, but I'm not sure how the pyxml and 4suite packages fit in the "big" picture of XML parsing and which package is used in the base Python install. Thanks, -- Brian Birkinbine From martin@v.loewis.de Tue May 7 06:13:42 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 07 May 2002 07:13:42 +0200 Subject: [XML-SIG] Python stdlib, pyxml, 4suite? In-Reply-To: <20020506153234.A9480@core-qe1.charter-stl.com> References: <20020506153234.A9480@core-qe1.charter-stl.com> Message-ID: Brian Birkinbine writes: > Could someone explain how the python standard library, pyxml and > 4suite all fit together (or refer me to a url to read about an > overview of the different package integration) A part of PyXML was incorporated into Python 2.0 (mainly sax/minidom), thus PyXML is an extension of the xml package of Python 2.x. A part of 4Suite was incorporated into PyXML (originally only 4DOM, now also 4XPath and 4XSLT); those parts where then removed/renamed in 4Suite (not yet done for 4XPath/4XSLT). 4Suite originally installed itself also as an extension for the xml package; the next 4Suite release will stop doing so, and live completely in the Ft package. HTH, Martin From andrewc@webtronfinance.com Tue May 7 21:51:57 2002 From: andrewc@webtronfinance.com (Andrew Cooke) Date: Tue, 07 May 2002 16:51:57 -0400 Subject: [XML-SIG] Character entities (XHTML) Message-ID: <005d01c1f609$074ba0e0$0e01a8c0@prat> Hi, In the example below I am losing the XHTML character entities. How d= o I avoid this? I've also posted to the ng - apologies to people seeing this same que= stion twice. Andrew Input file: Index

=A1Hola!

initialisación And when this is processed, I see (note that the SGML entity < doe= s appear, but oacute and iexcl don't): F:\home\Andrew\multi\src\xhtml>python Python 2.2.1 (#34, Apr 9 2002, 19:34:33) [MSC 32 bit (Intel)] on win= 32 Type "help", "copyright", "credits" or "license" for more information= . >>> from xml.dom.ext.reader.Sax2 import FromXmlFile >>> from xml.dom.ext import PrettyPrint >>> PrettyPrint(FromXmlFile("index.xhtml")) Index

<Hola!

initialisacin >>> From tpassin@comcast.net Wed May 8 00:49:39 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Tue, 07 May 2002 19:49:39 -0400 Subject: [XML-SIG] Character entities (XHTML) References: <005d01c1f609$074ba0e0$0e01a8c0@prat> Message-ID: <000601c1f621$da45b680$0bf13044@tbp> I'm sure others have told you the same thing. When an xml parser par= ses your file, it replaces any character references and entities with the= ir corresponding characters. There is no memory of how they came to be. There are really only two ways to get the entities back in to the out= put. Either you use or write a serializer to replace certain characters wi= th your entities (and which ones to replace will depend on the encoding), or = you do some preprocessing to replace the entities with some encoded version,= then convert them back with postprocessing. But here you seem to be running HTML Tidy, which may not even be hand= ling the source file as xml depending on how you have configured it. Other= wise, how did the Tidy "meta" element get into it when you don't show it in= the source file? In fact, without a DTD your file cannot be processed b= y an ordinary xml parser because the values of the entities cannot be know= n. So chances are you ran it in xhtml mode, not xml mode, before you fed th= e result to the Python modules. This list probably isn't going to be a= ble to help you with the idiosyncracies of Tidy. Maybe you didn't do that, but you need to explain what you really did because the way you show it, the Python program couldn't have complet= ed and there would be no "Meta" element. Cheers, Tom P [Andrew Cooke] In the example below I am losing the XHTML character entities. How d= o I avoid this? I've also posted to the ng - apologies to people seeing this same que= stion twice. Andrew Input file: Index

=A1Hola!

initialisación And when this is processed, I see (note that the SGML entity < doe= s appear, but oacute and iexcl don't): F:\home\Andrew\multi\src\xhtml>python Python 2.2.1 (#34, Apr 9 2002, 19:34:33) [MSC 32 bit (Intel)] on win= 32 Type "help", "copyright", "credits" or "license" for more information= . >>> from xml.dom.ext.reader.Sax2 import FromXmlFile >>> from xml.dom.ext import PrettyPrint >>> PrettyPrint(FromXmlFile("index.xhtml")) Index

<Hola!

initialisacin >>> _______________________________________________ XML-SIG maillist - XML-SIG@python.org http://mail.python.org/mailman/listinfo/xml-sig From Juergen Hermann" Message-ID: On Tue, 07 May 2002 19:49:39 -0400, Thomas B. Passin wrote: >There are really only two ways to get the entities back in to the outpu= t. >Either you use or write a serializer to replace certain characters with= your >entities (and which ones to replace will depend on the encoding), or yo= u do >some preprocessing to replace the entities with some encoded version, t= hen >convert them back with postprocessing. The third of the two ways is to use a SAX2 LexicalHandler. Ciao, J=FCrgen From tpassin@comcast.net Wed May 8 04:57:25 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Tue, 07 May 2002 23:57:25 -0400 Subject: [XML-SIG] Character entities (XHTML) References: Message-ID: <00c201c1f644$784129b0$0bf13044@tbp> Yes, for some reason in my mind I lumped that in with preprocessing when I wrote my response, but of course it's really not. Tom P [Juergen Hermann] On Tue, 07 May 2002 19:49:39 -0400, Thomas B. Passin wrote: >There are really only two ways to get the entities back in to the output. >Either you use or write a serializer to replace certain characters with your >entities (and which ones to replace will depend on the encoding), or you do >some preprocessing to replace the entities with some encoded version, then >convert them back with postprocessing. The third of the two ways is to use a SAX2 LexicalHandler. From andrewc@webtronfinance.com Wed May 8 15:00:29 2002 From: andrewc@webtronfinance.com (Andrew Cooke) Date: Wed, 08 May 2002 10:00:29 -0400 Subject: [XML-SIG] Character entities (XHTML) References: <005d01c1f609$074ba0e0$0e01a8c0@prat> <000601c1f621$da45b680$0bf13044@tbp> Message-ID: <001901c1f698$b64a5070$0e01a8c0@prat> Hi, Thanks for the reply. Two points in response: 1 - I screwed up with the input file, it was incorrect. My apologies= . I have included a revised demonstration of the problem below (the input= file has been through Tidy, but the entities still exist at that point). 2 - As far as I can tell, the problem isn=B4t that the entities are b= eing replaced by the appropriate character, but that they are being silent= ly dropped. The < entity passes through correctly, but the ó = entity is not replaced by an =F3 (nor is the ¡ replaced by a =A1). Thanks, Andrew PS I am using PyXml installed from PxML-0.7.win32-py2.2.exe F:\home\Andrew\multi\src\xhtml>python Python 2.2.1 (#34, Apr 9 2002, 19:34:33) [MSC 32 bit (Intel)] on win= 32 Type "help", "copyright", "credits" or "license" for more information= . >>> import sys >>> from xml.dom.ext.reader.Sax2 import FromXmlFile >>> from xml.dom.ext import PrettyPrint >>> sys.stdout.writelines(open("index.xhtml").readlines()) Index

¡<Hola!

initialisación >>> PrettyPrint(FromXmlFile("index.xhtml")) Index

<Hola!

initialisacin >>> ----- Original Message ----- =46rom: "Thomas B. Passin" To: Sent: Tuesday, May 07, 2002 7:49 PM Subject: Re: [XML-SIG] Character entities (XHTML) I'm sure others have told you the same thing. When an xml parser par= ses your file, it replaces any character references and entities with the= ir corresponding characters. There is no memory of how they came to be. There are really only two ways to get the entities back in to the out= put. Either you use or write a serializer to replace certain characters wi= th your entities (and which ones to replace will depend on the encoding), or = you do some preprocessing to replace the entities with some encoded version,= then convert them back with postprocessing. But here you seem to be running HTML Tidy, which may not even be hand= ling the source file as xml depending on how you have configured it. Other= wise, how did the Tidy "meta" element get into it when you don't show it in= the source file? In fact, without a DTD your file cannot be processed b= y an ordinary xml parser because the values of the entities cannot be know= n. So chances are you ran it in xhtml mode, not xml mode, before you fed th= e result to the Python modules. This list probably isn't going to be a= ble to help you with the idiosyncracies of Tidy. Maybe you didn't do that, but you need to explain what you really did because the way you show it, the Python program couldn't have complet= ed and there would be no "Meta" element. Cheers, Tom P From bbirkinbine@earthlink.net Wed May 8 18:41:52 2002 From: bbirkinbine@earthlink.net (Brian Birkinbine) Date: Wed, 8 May 2002 12:41:52 -0500 Subject: [XML-SIG] Returning dictionary from endDocument under xml.sax Message-ID: <20020508124152.A7832@core-qe1.charter-stl.com> I'm having difficulty returning a dictionary from the XML code below. I'm new to Python and XML, so please provide constructive comments where necessary. Please let me know if this is not the right forum for this. If not, I'll look at posting to the pythontutor list or elsewhere. Since I am not calling the endDocument() method directly (XML Parser does this), will returning a dictionary from within the endDocument() method work? I know that my dictionary (self.d) is correct when endDocument() is called. If I put in debugging code in endDocument() and print self.d.keys() and self.d.values(), the values are correct. So far I am unable to return the dictionary back to my XMLParse.py program. I appear to be getting 'None' which seems to suggest to me that my return is not making it all the way out of the Class method. I am trying to avoid writing to a file in endDocument(). Thanks in advance, Brian Birkinbine - - - parts of XMLHandler.py - - - import xml.sax class xmlHandler(xml.sax.ContentHandler): def __init__(self): self.xmlname = "" self.xmlvalue = "" self.d = {} def startElement(self, name, attr): # ignore attr for now since I don't need it self.xmlvalue = "" def endElement(self, name): self.xmlname = name self.d[self.xmlname] = self.xmlvalue def characters(self, value): self.xmlvalue = self.xmlvalue + value def endDocument(self): return self.d - - - XMLHandler.py - - - - - - parts of XMLParse.py - - - import xml.sax import XMLHandler import libXML # populate buffer from file buffer = inputfd.read() inputfd.close() # find xml data in buffer and return string with xml section # xmlbuffer is a list containing strings of xml data chunks from libXML.findxmldata() xmlbuffer = libXML.findxmldata(buffer) # use xml handler xmlhandler = XMLHandler.xmlHandler() counter = 0 result = [] while (counter < len(xmlbuffer)): result = xml.sax.parseString(xmlbuffer[counter],xmlhandler) # I've also tried result.append(xml.sax.parseString ...) and it doesn't work print result counter = counter + 1 - - - XMLParse.py - - - From accountmgr@borland.com Wed May 8 19:17:04 2002 From: accountmgr@borland.com (Account Manager) Date: Wed, 08 May 2002 11:17:04 -0700 Subject: [XML-SIG] Re: Barnesandnoble.com llc References: <20020506191713.UTKQ1804.out010.verizon.net@Oonthgqlb> Message-ID: <3CD96BA0.94CA6010@borland.com> --Boundary_(ID_70NzylC+fZY3IU/ZOkDmwA) Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT Thank you for your message. Unfortunately your message did not include any text in the body so we are unable to assist you at this time. If you need further assistance, please indicate how we can offer assistance. Borland Account Manager xml-sig wrote: --Boundary_(ID_70NzylC+fZY3IU/ZOkDmwA) Content-type: text/html; charset=us-ascii Content-transfer-encoding: 7BIT Thank you for your message. Unfortunately your message did not
include any text in the body so we are unable to assist you at this
time.

If you need further assistance, please indicate how we can offer
assistance.

Borland Account Manager

xml-sig wrote:

--Boundary_(ID_70NzylC+fZY3IU/ZOkDmwA)-- From martin@v.loewis.de Wed May 8 20:53:32 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 08 May 2002 21:53:32 +0200 Subject: [XML-SIG] Returning dictionary from endDocument under xml.sax In-Reply-To: <20020508124152.A7832@core-qe1.charter-stl.com> References: <20020508124152.A7832@core-qe1.charter-stl.com> Message-ID: Brian Birkinbine writes: > I'm having difficulty returning a dictionary from the XML code below. Notice that parsing with SAX does not "return" anything. Instead, the SAX XML reader notifies the application (i.e. the ContentHandler) about a series of events - that's it. More does not happen. > result = xml.sax.parseString(xmlbuffer[counter],xmlhandler) > # I've also tried result.append(xml.sax.parseString ...) and it doesn't work That's incorrect. You cannot return a valud from parsing. Instead, you have to collect all data in the content handler, and then query the concent handler after parsing returns. HTH, Martin From tpassin@comcast.net Thu May 9 04:11:50 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Wed, 08 May 2002 23:11:50 -0400 Subject: [XML-SIG] Character entities (XHTML) References: <005d01c1f609$074ba0e0$0e01a8c0@prat> <000601c1f621$da45b680$0bf13044@tbp> <001901c1f698$b64a5070$0e01a8c0@prat> Message-ID: <002301c1f707$43122960$0bf13044@tbp> I've replicated Andrew's results using Py2.1.3 and Pyxml 0.7. The tw= o xhtml entities are getting silently lost, in that they do not appear in the output, neither as characters nor as character references. It's no= t just that the original entities are missing, the characters that they repr= esent are missing. The DTD is getting processed - when I removed the DTD t= he program failed with an error, complaining about unknown entities, as = it should have. I noticed one other thing. The output DOCTYPE declaration is missing= the SYSTEM and PUBLIC identifiers that were present in the source. Cheers, Tom P [Andrew Cooke] Thanks for the reply. Two points in response: 1 - I screwed up with the input file, it was incorrect. My apologies= . I have included a revised demonstration of the problem below (the input= file has been through Tidy, but the entities still exist at that point). 2 - As far as I can tell, the problem isn=B4t that the entities are b= eing replaced by the appropriate character, but that they are being silent= ly dropped. The < entity passes through correctly, but the ó = entity is not replaced by an =F3 (nor is the ¡ replaced by a =A1). Thanks, Andrew PS I am using PyXml installed from PxML-0.7.win32-py2.2.exe F:\home\Andrew\multi\src\xhtml>python Python 2.2.1 (#34, Apr 9 2002, 19:34:33) [MSC 32 bit (Intel)] on win= 32 Type "help", "copyright", "credits" or "license" for more information= . >>> import sys >>> from xml.dom.ext.reader.Sax2 import FromXmlFile >>> from xml.dom.ext import PrettyPrint >>> sys.stdout.writelines(open("index.xhtml").readlines()) Index

¡<Hola!

initialisación >>> PrettyPrint(FromXmlFile("index.xhtml")) Index

<Hola!

initialisacin >>> From martin@v.loewis.de Thu May 9 08:51:28 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 09 May 2002 09:51:28 +0200 Subject: [XML-SIG] Character entities (XHTML) In-Reply-To: <002301c1f707$43122960$0bf13044@tbp> References: <005d01c1f609$074ba0e0$0e01a8c0@prat> <000601c1f621$da45b680$0bf13044@tbp> <001901c1f698$b64a5070$0e01a8c0@prat> <002301c1f707$43122960$0bf13044@tbp> Message-ID: "Thomas B. Passin" writes: > I've replicated Andrew's results using Py2.1.3 and Pyxml 0.7. The two xhtml > entities are getting silently lost, in that they do not appear in the > output, neither as characters nor as character references. That's partially a bug in expatreader, which has been fixed in expatreader.py 1.22. The other part of the problem is that the entity resolver will need to resolve the HTML DTD. Regards, Martin From Mellisa" This is a multi-part message in MIME format --=_NextPart_2rfkindysadvnqw3nerasdf Content-Type: text/plain;charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Dear Sir/Madam, We have visited glory.python.or.kr and found it a thoughtfully-designed one with much helpful information but poorly listed in many search engines. It's time to do something. Find a most effective way of advertising, find FULLPROMOTE=21 Best Service, lowest cost=21 Fullpromote will instantly submit your website to all the famous searching engines around the world.=20 To check our pricelist and submit glory.python.or.kr to 500,000 search engines in the world, go to www.fullpromote.com.We will try our best to publicize your website. Looking forward to your favorable reply. Best regards, Sales & Marketing=20www.fullpromote.com --=_NextPart_2rfkindysadvnqw3nerasdf Content-Type: text/html;charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable We have visited glory.python.or.kr
=20

 

=20 =20
 


=20

Dear Sir/Madam,

I have visited glory.python.or.kr and=20 found it a thoughtfully-designed one with much helpful information=20 but poorly listed in many search engines. It's time to do something.=20 Find a most effective way of advertising, find FULLPROMOTE=21 Best=20 Service, lowest cost=21 Fullpromote will instantly submit your=20 website to all the famous searching engines around the world.

To check our pricelist and submit glory.python.or.kr to 500,000 search engines in the world, go to www.fullpromote.com.We will try our best to publicize your website.

Looking forward to your favorable reply.

Best regards,

Sales & Marketing
www.fullpromote.com

--=_NextPart_2rfkindysadvnqw3nerasdf-- From Martina@Oefelein.de Thu May 9 20:08:36 2002 From: Martina@Oefelein.de (Martina Oefelein) Date: Thu, 9 May 2002 21:08:36 +0200 Subject: [XML-SIG] Python stdlib, pyxml, 4suite? In-Reply-To: References: <20020506153234.A9480@core-qe1.charter-stl.com> Message-ID: Hello Martin, >A part of PyXML was incorporated into Python 2.0 (mainly sax/minidom), >thus PyXML is an extension of the xml package of Python 2.x. Additional Question: Will there more of PyXML be integrated into Python in the future, or will the Python library XML modules evolve separately from PyXML? ciao Martina From tpassin@comcast.net Fri May 10 01:09:01 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Thu, 09 May 2002 20:09:01 -0400 Subject: [XML-SIG] Character entities (XHTML) References: <005d01c1f609$074ba0e0$0e01a8c0@prat> <000601c1f621$da45b680$0bf13044@tbp> <001901c1f698$b64a5070$0e01a8c0@prat> <002301c1f707$43122960$0bf13044@tbp> Message-ID: <000e01c1f7b6$e378fc30$0bf13044@tbp> [Martin v. Loewis] > "Thomas B. Passin" writes: > > > I've replicated Andrew's results using Py2.1.3 and Pyxml 0.7. The two xhtml > > entities are getting silently lost, in that they do not appear in the > > output, neither as characters nor as character references. > > That's partially a bug in expatreader, which has been fixed in > expatreader.py 1.22. > > The other part of the problem is that the entity resolver will need to > resolve the HTML DTD. > It seems to have done so - at least, if the DTD is removed, the document is rejected by virtue of unknown entities. Doesn't that that indicate that the (x)HTML DTD was resolved? Cheers, Tom P From akuchlin@mems-exchange.org Fri May 10 01:58:45 2002 From: akuchlin@mems-exchange.org (akuchlin@mems-exchange.org) Date: Thu, 9 May 2002 20:58:45 -0400 Subject: [XML-SIG] Worth keeping xml-ref? Message-ID: <20020510005844.GA30536@mems-exchange.org> Question: is it worth keeping xml-ref.tex around? It's only irregularly updated, and has this notice up top: THIS DOCUMENT IS SIGNIFICANTLY OUTDATED, DO NOT USE IT AS A BASIS OF APPLICATION DEVELOPMENT. Perhaps we could just use pydoc to generate reference docs, and ask Ping to ensure an up-to-date version of PyXML is on the machine running pydoc.org. Then we could concentrate on the friendlier xml-howto.tex, which is more fun to write. --amk From martin@v.loewis.de Fri May 10 07:16:06 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 10 May 2002 08:16:06 +0200 Subject: [XML-SIG] Character entities (XHTML) In-Reply-To: <000e01c1f7b6$e378fc30$0bf13044@tbp> References: <005d01c1f609$074ba0e0$0e01a8c0@prat> <000601c1f621$da45b680$0bf13044@tbp> <001901c1f698$b64a5070$0e01a8c0@prat> <002301c1f707$43122960$0bf13044@tbp> <000e01c1f7b6$e378fc30$0bf13044@tbp> Message-ID: "Thomas B. Passin" writes: > It seems to have done so - at least, if the DTD is removed, the > document is rejected by virtue of unknown entities. Doesn't that > that indicate that the (x)HTML DTD was resolved? No. Expat, on its own, will never try to access external entities. Also, expatreader will always refer to the EntityResolver for that - although the default entity resolver will arrange to open the system ID. Expat *will* report an error if it can determine that there is one even without reading the external subset - e.g. if the document is standalone, or if there is no declared external subset. The latter is what you are observing: with only an internal subset, expat can know what the available entities are. Regards, Martin From martin@v.loewis.de Fri May 10 07:18:32 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 10 May 2002 08:18:32 +0200 Subject: [XML-SIG] Worth keeping xml-ref? In-Reply-To: <20020510005844.GA30536@mems-exchange.org> References: <20020510005844.GA30536@mems-exchange.org> Message-ID: akuchlin@mems-exchange.org writes: > Question: is it worth keeping xml-ref.tex around? I was still hoping that it would document those parts of PyXML that are not documented in the Python library documentation. Some people have recently contributed changes to it, so it would be a pity if those were lost. I will remove the outdated parts soon; that should reduce the confusion. Regards, Martin From martin@v.loewis.de Fri May 10 07:11:29 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 10 May 2002 08:11:29 +0200 Subject: [XML-SIG] Python stdlib, pyxml, 4suite? In-Reply-To: References: <20020506153234.A9480@core-qe1.charter-stl.com> Message-ID: Martina Oefelein writes: > Additional Question: Will there more of PyXML be integrated into > Python in the future, or will the Python library XML modules evolve > separately from PyXML? Most likely, neither, nor, atleast not in a foreseeable future. IOW, the Python XML library is frozen, at the moment, except for bug fixes. If there are enhancements made, in terms of additional modules, then those will most likely be drawn from PyXML. Even if they aren't, PyXML would reflect the changes made to Python. HTH, Martin From fdrake@acm.org Fri May 10 13:11:59 2002 From: fdrake@acm.org (Fred L. Drake, Jr.) Date: Fri, 10 May 2002 08:11:59 -0400 Subject: [XML-SIG] Worth keeping xml-ref? In-Reply-To: References: <20020510005844.GA30536@mems-exchange.org> Message-ID: <15579.47375.698720.486332@grendel.zope.com> Martin v. Loewis writes: > I was still hoping that it would document those parts of PyXML that > are not documented in the Python library documentation. Some people > have recently contributed changes to it, so it would be a pity if > those were lost. I agree; as long as we can add to the document as we change PyXML, it's worth keeping. What's missing can be documented slowly; doing it all at once is particularly painful. > I will remove the outdated parts soon; that should reduce the > confusion. Thanks! Cleaning house certainly makes it easier to maintain the house. -Fred -- Fred L. Drake, Jr. PythonLabs at Zope Corporation From akuchlin@mems-exchange.org Fri May 10 15:40:50 2002 From: akuchlin@mems-exchange.org (Andrew Kuchling) Date: Fri, 10 May 2002 10:40:50 -0400 Subject: [XML-SIG] List of publicly usable modules Message-ID: Here's a list of modules I've just checked into xml-howto.tex. Are there any public modules that aren't on this list? Are there any modules here that are considered implementation details, and therefore shouldn't be used outside the PyXML implementation? --amk \item[\module{xml.dom}] The Python DOM interface. The full interface support DOM Levels 1 and 2. This implementation is called 4DOM, and was written by Fourthought LLC. \module{xml.dom} contains the implementation for DOM trees built from XML documents. \item[\module{dom.html}] DOM trees built from HTML documents are also supported. \item[\module{dom.javadom}] An adaptor for using Java DOM implementations with Jython. \item[\module{dom.minidom}] A lightweight DOM implementation that's also included in the Python standard library. \item[\module{dom.minitraversal}] Offers traversal and ranges on top of \module{xml.dom.minidom}, using the 4DOM traversal implementation. \item[\module{dom.pulldom}] Provides a stream of DOM elements. This module can make it easy to write certain types of DTD-specific processing code. \item[\module{dom.TreeWalker}] Provides the \class{TreeWalker} class for multidirectional iteration over nodes. \item[\module{dom.ext.Dom2Sax}] A parser to generate SAX events from a DOM tree. \item[\module{dom.ext.Printer}] Classes to print XML from a DOM tree. \item[\module{dom.ext.Visitor}] Classes for walking over a DOM tree. \item[\module{dom.ext.XHtml2HtmlPrinter}] Classes for printing an XHTML DOM tree as HTML. \item[\module{dom.ext.XHtmlPrinter}] Classes for printing an HTML DOM tree as XHTML. \item[\module{dom.ext.c14n}] Takes a DOM tree and outputs another DOM tree containing the Canonical XML representation of the document. \item[\module{dom.ext.reader}] Classes for building DOM trees from various input sources: SAX1 and SAX2 parsers, \module{htmllib}, and directly using Expat. \item[\module{xml.marshal.generic}] Marshals simple Python data types into an XML format. The marshaller class can be subclassed in order to implement marshalling into a different XML DTD. \item[\module{xml.marshal.wddx}] Marshals Python objects into WDDX. (This module is built on top of the preceding generic module.) \item[\module{xml.ns}] Contains constants for the namespace URIs for various XML-related standards. \item[\module{xml.parsers.sgmllib}] A version of the \module{sgmllib} module that's part of the standard Python library, rewritten to run on top of the \module{sgmlop} accelerator module. \item[\module{xml.parsers.xmlproc}] A validating XML parser. \item[\module{xml.sax}] SAX1 and SAX2 support for Python. \item[\module{sax.drivers}] SAX1 drivers for various parsers: \module{htmllib}, LT, Expat, \module{sgmllib}, \module{xmllib}, xmlproc, and XML-Toolkit. \item[\module{sax.drivers2}] SAX2 drivers for various parsers: \module{htmllib}, Java SAX parsers (for Jython), Expat, \module{sgmllib}, xmlproc. \item[\module{sax.handler}] Contains the core SAX2 handler classes \class{ContentHandler}, \class{DTDHandler}, \class{EntityResolver}, and \class{ErrorHandler}. \item[\module{sax.saxexts}] SAX1 extensions. This contains various factory classes that create parser objects, and the \function{make_parser()} function. \item[\module{sax.sax2exts}] SAX2 extensions. Like its SAX1 counterpart, this module contains various factory classes that create parser objects, and the \function{make_parser()} function. \item[\module{sax.saxlib}] Contains two SAX2 handler classes, \class{DeclHandler} and \class{LexicalHandler}, and the \class{XMLFilter} interface. Also contains the deprecated SAX1 handler classes. \item[\module{sax.saxutils}] Various utility classes, such as \class{DefaultHandler}, a default base class for SAX2 handlers, \class{ErrorPrinter} and \class{ErrorRaiser}, two default error handlers, and \class{XMLGenerator}, which generates XML output from a SAX2 event stream. \item[\module{sax.xmlreader}] Contains the \class{XMLReader}, the base interface for implementing SAX2 parsers. \item[\module{xml.schema.trex}] A Python implementation of TREX, a schema language. \item[\module{xml.utils.characters}] Contains the legal XML character ranges as specified in the XML 1.0 Recommendation, and regular expressions that match various XML tokens. \item[\module{xml.utils.iso8601}] Parses ISO-8601 date/time specifiers, which look like \samp{2002-05-09T20:40Z}. \item[\module{xml.utils.qp_xml}] A simple tree-based XML parsing interface. \item[\module{xml.xpath}] An XPath parser and evaluator. \item[\module{xml.xslt}] An implementation of the XSLT transformation language. % XXX do the FourThought guys want a credit in the text here? From akuchlin@mems-exchange.org Fri May 10 15:51:29 2002 From: akuchlin@mems-exchange.org (Andrew Kuchling) Date: Fri, 10 May 2002 10:51:29 -0400 Subject: [XML-SIG] Worth keeping xml-ref? In-Reply-To: <15579.47375.698720.486332@grendel.zope.com> References: <20020510005844.GA30536@mems-exchange.org> <15579.47375.698720.486332@grendel.zope.com> Message-ID: <20020510145129.GA15404@ute.mems-exchange.org> On Fri, May 10, 2002 at 08:11:59AM -0400, Fred L. Drake, Jr. wrote: >I agree; as long as we can add to the document as we change PyXML, >it's worth keeping. What's missing can be documented slowly; doing it >all at once is particularly painful. I'm just doubtful it'll ever happen. A reference manual would be a lot of work cutting-and-pasting from the code into a TeX document; boring! Autogeneration seems the only way we'll ever see anything resembling As an aside, Sean McGrath's XPipe project has a browsable pydoc tree for PyXML 0.6.4: http://xpipe.sourceforge.net/cgi-bin/doc.py?module=xml >Thanks! Cleaning house certainly makes it easier to maintain the >house. On that note, while making the list of modules (there are something like 277 *.py files under xml/ !), I noticed a few things that could be deprecated. * xml.schema.trex : Trex effort is now going into RELAX NG. * Should the SAX1 classes be deprecated? * qp_xml: does it provide anything that pulldom doesn't? * xml.dom.ext.Visitor: is this still needed with the addition of DOM Level 2's TreeWalker? Deprecation would have to be gradual, of course, following Python's approach of "remove docs in first version; add warnings in second version; remove code in third version". --amk From martin@v.loewis.de Fri May 10 17:23:25 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 10 May 2002 18:23:25 +0200 Subject: [XML-SIG] Worth keeping xml-ref? In-Reply-To: <20020510145129.GA15404@ute.mems-exchange.org> References: <20020510005844.GA30536@mems-exchange.org> <15579.47375.698720.486332@grendel.zope.com> <20020510145129.GA15404@ute.mems-exchange.org> Message-ID: Andrew Kuchling writes: > On that note, while making the list of modules (there are something > like 277 *.py files under xml/ !), I noticed a few things that could > be deprecated. > > * xml.schema.trex : Trex effort is now going into RELAX NG. Until RELAX NG is integrated, I'd like to keep trex. I'm sure anybody using the trex module will be aware of its status. > * Should the SAX1 classes be deprecated? Sure, although I'm not so sure how to actually implement the deprecation: We want to support Python 2.0, and this doesn't have the warning framework. Also, people still ask for PyXML 0.5 features from time to time (because of code they found on the net); I expect that the SAX1-based applications will stay around for much longer. Since the code does not introduce maintainance burden, I'd keep it. > * qp_xml: does it provide anything that pulldom doesn't? That's a good question - I've never heard of any qp_xml user. > * xml.dom.ext.Visitor: is this still needed with the addition of > DOM Level 2's TreeWalker? Probably not - although I believe that there are a number of bugs hiding in the traversal-and-ranges part of 4DOM. We really should pass a third-party test suite before telling people to migrate to it. > Deprecation would have to be gradual, of course, following Python's > approach of "remove docs in first version; add warnings in second > version; remove code in third version". I think this could be done at different paces for different modules. I.e. if no user indicates qp_xml usage, I'd happily outright remove it from 0.8 - if somebody the complains, releasing 0.8.1 that adds it back in (or, put an ImportError at the top). For SAX1, I'd be much more hesitant, like keeping it until after PyXML 1.0. Regards, Martin From martin@v.loewis.de Fri May 10 17:50:26 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 10 May 2002 18:50:26 +0200 Subject: [XML-SIG] List of publicly usable modules In-Reply-To: References: Message-ID: Andrew Kuchling writes: > \item[\module{dom.TreeWalker}] > Provides the \class{TreeWalker} class for multidirectional iteration > over nodes. This is an implementation detail - use createTreeWalker on the document instead. > \item[\module{dom.ext.Printer}] > Classes to print XML from a DOM tree. The usual interface is dom.ext.{Pretty}Print, although people may want to use the Printer class directly to subclass it. > \item[\module{dom.ext.XHtmlPrinter}] > Classes for printing an HTML DOM tree as XHTML. Likewise: you normally use dom.ext.XHtmlPrettyPrint. > \item[\module{xml.parsers.xmlproc}] > A validating XML parser. Of the many modules in this package, few are public entry points only. I think Lars-Marius could produce a list. > \item[\module{sax.drivers}] > SAX1 drivers for various parsers: \module{htmllib}, > LT, Expat, \module{sgmllib}, \module{xmllib}, xmlproc, > and XML-Toolkit. These are not "directly" public: use xml.sax.make_parser instead - but you do need to know the module names. > \item[\module{sax.drivers2}] > SAX2 drivers for various parsers: \module{htmllib}, Java SAX parsers > (for Jython), Expat, \module{sgmllib}, xmlproc. Likewise. > \item[\module{sax.handler}] > Contains the core SAX2 handler classes \class{ContentHandler}, > \class{DTDHandler}, \class{EntityResolver}, > and \class{ErrorHandler}. Also contains symbolic names for the features and properties. > \item[\module{sax.saxexts}] > SAX1 extensions. This contains various factory classes that create > parser objects, and the \function{make_parser()} function. make_parser is available through xml.sax (as such, it is also available in Python 2, even though saxexts isn't). Use this only if you need to make a SAX1 parser (could also use a Factory instead) > \item[\module{sax.sax2exts}] > SAX2 extensions. Like its SAX1 counterpart, this module contains > various factory classes that create parser objects, and the > \function{make_parser()} function. Likewise, but never use this make_parser - instead, the various Factory singletons are the public API here, and their make_parser methods. > \item[\module{xml.utils.characters}] > Contains the legal XML character ranges as specified in the XML 1.0 > Recommendation, and regular expressions that match various > XML tokens. This is probably of interest only to authors of parsers, and DOM implementations. > \item[\module{xml.xpath}] > An XPath parser and evaluator. > > \item[\module{xml.xslt}] > An implementation of the XSLT transformation language. > % XXX do the FourThought guys want a credit in the text here? Yes. This code is work-in-progress (awaiting a merger from the next 4Suite release) - the agreement is that the names "4XPath" and "4XSLT" get prominent mentioning where appropriate. Regards, Martin From uche.ogbuji@fourthought.com Sat May 11 05:32:57 2002 From: uche.ogbuji@fourthought.com (Uche Ogbuji) Date: Fri, 10 May 2002 22:32:57 -0600 Subject: [XML-SIG] List of publicly usable modules In-Reply-To: Message from Andrew Kuchling of "Fri, 10 May 2002 10:40:50 EDT." Message-ID: <200205110432.g4B4WvV16889@localhost.localdomain> > Here's a list of modules I've just checked into xml-howto.tex. Are > there any public modules that aren't on this list? Are there any > modules here that are considered implementation details, and therefore > shouldn't be used outside the PyXML implementation? Maybe we should consolidate this with Alexandre Fayolle's list of modules. Of course, I can't find his list in the PyXML source tree right now. > \item[\module{xml.dom}] > The Python DOM interface. The full interface > support DOM Levels 1 and 2. This implementation is called 4DOM, > and was written by Fourthought LLC. \module{xml.dom} contains > the implementation for DOM trees built from XML documents. I might go through and update the LLC -> Inc. > \item[\module{xml.xslt}] > An implementation of the XSLT transformation language. > % XXX do the FourThought guys want a credit in the text here? I think it's fair. Then again, it looks as if we're the only ones with credits in the manifest. Perhaps the credits in the README are sufficient. -- Uche Ogbuji Fourthought, Inc. http://uche.ogbuji.net http://4Suite.org http://fourthought.com Track chair, XML/Web Services One (San Jose, Boston): http://www.xmlconference.com/ DAML Reference - http://www.xml.com/pub/a/2002/05/01/damlref.html The Languages of the Semantic Web - http://www.newarchitectmag.com/documents/s= 2453/new1020218556549/index.html XML, The Model Driven Architecture, and RDF @ XML Europe - http://www.xmleurope.com/2002/kttrack.asp#themodel From primmer@hotmail.com Sat May 11 14:59:00 2002 From: primmer@hotmail.com (Dave Primmer) Date: Sat, 11 May 2002 06:59:00 -0700 Subject: [XML-SIG] how to output xml from a python object Message-ID: I'd like to do something like take a simple python object and make an xml file. I've looked and looked but I can't find any docs on how to do this (only parsing). http://ibm.com/developerworks/library/python2/ has some old code that refers to modules that aren't available anymore but that's basically what i want to do. I don't want xmlPickle or generic marshalling. My data format is relatively static and i'd like non-verbose XML. I'm sure it's in the archives but I can't download a 22 meg file! (death to pipermail) If there is no xml.dom.builder anymore, how do i build a dom tree and then write it out with .toxml()? I started out by just doing "<"+tag+">" stuff and writing elements for everthing but i'd like to be able to do xml attributes also. i'd like to do: object.name = 'bob' object.city = 'sea' object.desc = '

blabedy blah. on and on

' to this:

blabedy blah. on and on

_________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp. From tpassin@comcast.net Sat May 11 15:23:31 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Sat, 11 May 2002 10:23:31 -0400 Subject: [XML-SIG] how to output xml from a python object References: Message-ID: <002101c1f8f7$6d6d8870$0bf13044@tbp> [Dave Primmer] > I'd like to do something like take a simple python object and make an xml > file. I've looked and looked but I can't find any docs on how to do this > (only parsing). http://ibm.com/developerworks/library/python2/ has some old > code that refers to modules that aren't available anymore but that's > basically what i want to do. I don't want xmlPickle or generic marshalling. > My data format is relatively static and i'd like non-verbose XML. I'm sure > it's in the archives but I can't download a 22 meg file! (death to > pipermail) > > If there is no xml.dom.builder anymore, how do i build a dom tree and then > write it out with .toxml()? > > I started out by just doing "<"+tag+">" stuff and writing elements for > everthing but i'd like to be able to do xml attributes also. > > i'd like to do: > object.name = 'bob' > object.city = 'sea' > object.desc = '

blabedy blah. on and on

' > to this: >

blabedy blah. on and > on

If there isn't anything that does what you want, then use SAX. If you can work out how to traverse all the objects you are interested in, just throw SAX events during the traverse. You can modify a handler to build the structures you want, then write it out. The pickle module already knows how to serialize objects, so it should be helpful to look at it. Cheers, Tom P From martin@v.loewis.de Sun May 12 15:49:47 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 12 May 2002 16:49:47 +0200 Subject: [XML-SIG] how to output xml from a python object In-Reply-To: References: Message-ID: "Dave Primmer" writes: > I'd like to do something like take a simple python object and make an > xml file. I've looked and looked but I can't find any docs on how to > do this (only parsing). IMO, generating XML is much simpler than parsing it - you normally don't need any library. Hence, there is no explicit library support for it. > If there is no xml.dom.builder anymore, how do i build a dom tree and > then write it out with .toxml()? If you absolutely think you need to create a DOM tree, you have to use the normal DOM API for creation: use createDocument on the DOM implementation, then use createElement on the document, and appendChild to build the tree. > I started out by just doing "<"+tag+">" stuff and writing elements for > everthing but i'd like to be able to do xml attributes also. > > i'd like to do: > object.name = 'bob' > object.city = 'sea' > object.desc = '

blabedy blah. on and on

' > to this: >

blabedy blah. on and > on

I recommend print '%s' % \ (object.name, object.city, object.desc) Care is needed if the attributes may contain markup. Regards, Martin From noreply@sourceforge.net Mon May 13 06:09:27 2002 From: noreply@sourceforge.net (noreply@sourceforge.net) Date: Sun, 12 May 2002 22:09:27 -0700 Subject: [XML-SIG] [ pyxml-Bugs-555303 ] Sgmlop.HtmlParser uppercases all names Message-ID: Bugs item #555303, was opened at 2002-05-12 22:09 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=106473&aid=555303&group_id=6473 Category: DOM Group: None Status: Open Resolution: None Priority: 5 Submitted By: Nobody/Anonymous (nobody) Assigned to: Nobody/Anonymous (nobody) Summary: Sgmlop.HtmlParser uppercases all names Initial Comment: Sgmlop.HtmlParser uppercases all element and attribute names, making it difficult to treat HTML and XHTML equivalently. For example, If I write an XPath expression, I have to be aware of whether it's being applied to XHTML or HTML, because Sgmlop.HtmlParser expects /HTML/HEAD/LINK[@TYPE="application/xml"]/@HREF whereas if it's XHTML, I need to use /html/head/link[@type="application/xml"]/@HREF with PyExpat. Suggested fix is to lowercase element and attribute names in Sgmlop.HtmlParser. ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=106473&aid=555303&group_id=6473 From paul@boddie.net Mon May 13 11:22:00 2002 From: paul@boddie.net (paul@boddie.net) Date: 13 May 2002 10:22:00 -0000 Subject: [XML-SIG] how to output xml from a python object Message-ID: <20020513102200.5780.qmail@www4.nameplanet.com> >"Dave Primmer" writes: > >> I'd like to do something like take a simple python object and make an >> xml file. I've looked and looked but I can't find any docs on how to >> do this (only parsing). martin@v.loewis.de (Martin v. Loewis) wrote: > >I recommend > >print '%s' % \ > (object.name, object.city, object.desc) > >Care is needed if the attributes may contain markup. I recommend avoiding these printing exercises, for mainly the same reasons that people should avoid quoting values in SQL statements - it's easy to forget to quote things, and while security holes are less likely to be opened in this case, getting some valid input and then seeing things go badly wrong is not very appealing. By the time quoting functions and other extra safeguards are included in your code, you would have been better off in terms of code readability, standardisation and extensibility if you had just used the DOM instead. After all, the various serialisation functions and classes in PyXML have been designed to do this kind of thing, and I don't believe in reinventing the wheel poorly. On a related note, I uploaded my introductory document again, and this is precisely the kind of thing I covered in that document: http://www.boddie.org.uk/python/XML_intro.html Having had to maintain code which did lots of print statements (in Perl as well, for increased maintenance excitement), I can see lots of benefits in not using that approach. Another benefit of the DOM, of course, is the random- access nature of the technology - as soon as you decide you need to revisit parts of your generated document in your program in order to add "extra stuff" (and I'm not saying you definitely will, but it's not unheard of), you'll probably end up doing a big rewrite of the program to use the DOM anyway. Paul From andrewc@webtronfinance.com Mon May 13 14:28:18 2002 From: andrewc@webtronfinance.com (Andrew Cooke) Date: Mon, 13 May 2002 09:28:18 -0400 Subject: [XML-SIG] how to output xml from a python object References: Message-ID: <001f01c1fa82$0b558110$0e01a8c0@prat> Hi, I'm no expert, but I wrote some notes that might help (they cover the very basic of manipulating DOM trees). You can find them at http://www.acooke.org/andrew/writing/python-xml.html If you're creating a document completely from scratch then you'll need to create a document instance first (I don't know how to, but the notes above describe where to look - basically the source and the DOM docs). Andrew ----- Original Message ----- From: "Dave Primmer" To: Sent: Saturday, May 11, 2002 9:59 AM Subject: [XML-SIG] how to output xml from a python object > I'd like to do something like take a simple python object and make an xml > file. I've looked and looked but I can't find any docs on how to do this > (only parsing). http://ibm.com/developerworks/library/python2/ has some old > code that refers to modules that aren't available anymore but that's [...] From martin@v.loewis.de Mon May 13 23:18:20 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 14 May 2002 00:18:20 +0200 Subject: [XML-SIG] how to output xml from a python object In-Reply-To: <20020513102200.5780.qmail@www4.nameplanet.com> References: <20020513102200.5780.qmail@www4.nameplanet.com> Message-ID: paul@boddie.net writes: > Having had to maintain code which did lots of print statements (in > Perl as well, for increased maintenance excitement), I can see lots > of benefits in not using that approach. Another benefit of the DOM, > of course, is the random- access nature of the technology - as soon > as you decide you need to revisit parts of your generated document > in your program in order to add "extra stuff" (and I'm not saying > you definitely will, but it's not unheard of), you'll probably end > up doing a big rewrite of the program to use the DOM anyway. In the specific case, any "political correct" solution would not have worked, though - the user had object.desc = "

text

" and expected the final output document to contain this string literally. How do you get this with the a DOM? Regards, Martin From ravms@asclepius.uwa.edu.au Tue May 14 06:47:38 2002 From: ravms@asclepius.uwa.edu.au (ravms@asclepius.uwa.edu.au) Date: Tue, 14 May 2002 13:47:38 +0800 Subject: [XML-SIG] RAV AntiVirus scan results. Message-ID: <20020514054738.5A1913F731@asclepius.uwa.edu.au> RAV AntiVirus for Linux i686 version: 8.3.2 (snapshot-20020108) Running on host: asclepius.uwa.edu.au <> This is the central UWA virus scanning service. The following message is in regards to a virus infected email. This message is automated; if you believe the email this message concerns did not contain a virus please contact support@ucs.uwa.edu.au and we will investigate. Infected file: (part0001:that.scr) (subject:A powful tool) Sent by: youme@hongkong.com Sent to: xml-sig@python.org, Virus: Win32/Klez.H@mm The file was successfully deleted by RAV AntiVirus. Scan engine 8.7 () for i386. Last update: Sat May 11 15:29:36 2002 Scanning for 67510 malwares (viruses, trojans and worms). From paul@boddie.net Tue May 14 10:42:37 2002 From: paul@boddie.net (paul@boddie.net) Date: 14 May 2002 09:42:37 -0000 Subject: [XML-SIG] how to output xml from a python object Message-ID: <20020514094237.19351.qmail@www2.nameplanet.com> On 14 May 2002 00:18:20 +0200 martin@v.loewis.de (Martin v. Loewis) wrote: > >In the specific case, any "political correct" solution would not have >worked, though - the user had > >object.desc = "

text

" > >and expected the final output document to contain this string >literally. How do you get this with the a DOM? Well, it depends what they're trying to achieve, and I suppose I should familiarise myself with what the problem was again. I've worked on XML documents where literal HTML was required inside CDATA sections, and I'm sure the DOM would have worked just fine in producing those documents. Paul From gherman@darwin.in-berlin.de Tue May 14 12:51:00 2002 From: gherman@darwin.in-berlin.de (gherman@darwin.in-berlin.de) Date: Tue, 14 May 2002 13:51:00 +0200 Subject: [XML-SIG] Jython experience with std. lib. XML and PyXML? Message-ID: <200205141151.g4EBp0Xw011368@hirsch.in-berlin.de> Message-ID: <1021377060.3ce0fa2471c09@webmail.in-berlin.de> Date: Tue, 14 May 2002 13:51:00 +0200 (CEST) From: Dinu Gherman MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit User-Agent: IMP/PHP IMAP webmail program 2.2.6 X-Originating-IP: 217.5.90.230 Hi, does anybody here want to share her experience using the standard library XML modules and/or the PyXML extensions with Jython? Thanks, Dinu From martin@v.loewis.de Tue May 14 19:56:02 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 14 May 2002 20:56:02 +0200 Subject: [XML-SIG] how to output xml from a python object In-Reply-To: <20020514094237.19351.qmail@www2.nameplanet.com> References: <20020514094237.19351.qmail@www2.nameplanet.com> Message-ID: paul@boddie.net writes: > Well, it depends what they're trying to achieve, and I suppose I > should familiarise myself with what the problem was again. I've > worked on XML documents where literal HTML was required inside CDATA > sections, and I'm sure the DOM would have worked just fine in > producing those documents. Perhaps, but in the specific case, you want to generate proper markup from string fragments - the DOM does not help for that. Regards, Martin From ravms@asclepius.uwa.edu.au Wed May 15 15:44:07 2002 From: ravms@asclepius.uwa.edu.au (ravms@asclepius.uwa.edu.au) Date: Wed, 15 May 2002 22:44:07 +0800 Subject: [XML-SIG] RAV AntiVirus scan results. Message-ID: <20020515144407.29FCA40626@asclepius.uwa.edu.au> RAV AntiVirus for Linux i686 version: 8.3.2 (snapshot-20020108) Running on host: asclepius.uwa.edu.au <> This is the central UWA virus scanning service. The following message is in regards to a virus infected email. This message is automated; if you believe the email this message concerns did not contain a virus please contact support@ucs.uwa.edu.au and we will investigate. Infected file: (part0001:setup.exe) (subject:W32.Elkern removal tools) Sent by: youme@hongkong.com Sent to: xml-sig@python.org, Virus: Win32/Klez.H@mm The file was successfully deleted by RAV AntiVirus. Scan engine 8.7 () for i386. Last update: Tue May 14 19:05:14 2002 Scanning for 67707 malwares (viruses, trojans and worms). From akuchlin@mems-exchange.org Thu May 16 15:52:55 2002 From: akuchlin@mems-exchange.org (Andrew Kuchling) Date: Thu, 16 May 2002 10:52:55 -0400 Subject: [XML-SIG] Test suite coverage Message-ID: I ran the test suite and measured the coverage, using the code_coverage.py module that's part of Sancho. Here are the modules which have less than half of their lines executed. (This only measures modules that actually get imported.) Anyone want to expand the test suite to exercise these modules more? Is there a test suite in 4XPath that could be added to PyXML? And does anyone want to volunteer to go through the bugs and fix a few of them. There are open bugs dating back to 2000, and we should see if they're still applicable. --amk 0-50% coverage xml.xslt: 2.6% (4/153) xml.sax.drivers.drv_xmldc: 6.0% (6/100) xml.dom.Range: 6.4% (43/676) xml.sax.drivers.drv_xmltoolkit: 6.8% (5/73) xml.dom.domreg: 18.2% (6/33) xml.xpath.BuiltInExtFunctions: 18.2% (28/154) xml.parsers.xmlproc.dtdparser: 22.1% (116/524) xml.xpath.CoreFunctions: 25.9% (55/212) xml.xpath.yappsrt: 26.4% (29/110) xml.xpath.XPathParserBase: 28.0% (21/75) xml.xpath.ParsedRelativeLocationPath: 28.6% (8/28) xml.xpath.ParsedExpr: 30.2% (153/506) xml.sax: 30.4% (7/23) xml.xpath.ParsedAbbreviatedRelativeLocationPath: 31.0% (13/42) xml.xpath.Conversions: 32.5% (37/114) xml.xpath.ExpandedNameWrapper: 33.3% (6/18) xml.dom.html: 35.2% (25/71) xml.parsers.xmlproc.xmldtd: 36.4% (199/547) xml.dom.ext.Visitor: 37.8% (14/37) xml.xpath.ParsedAbsoluteLocationPath: 38.1% (8/21) xml.dom.javadom: 40.0% (166/415) xml.xpath.Util: 41.2% (49/119) xml.FtCore: 44.4% (4/9) xml.parsers.xmlproc.errors: 44.9% (22/49) xml.xpath.ParsedNodeTest: 44.9% (53/118) xml.parsers.xmlproc.utils: 46.6% (76/163) xml.xpath.Set: 47.4% (9/19) xml.dom.html.HTMLTitleElement: 48.4% (15/31) xml.sax.drivers2.drv_xmlproc: 48.6% (123/253) xml.xpath.ParsedStep: 48.6% (34/70) xml.dom.ext.reader.Sax2: 49.7% (144/290) From pobrien@orbtech.com Thu May 16 18:34:59 2002 From: pobrien@orbtech.com (Patrick K. O'Brien) Date: Thu, 16 May 2002 12:34:59 -0500 Subject: [XML-SIG] Test suite coverage In-Reply-To: Message-ID: [Andrew Kuchling] > > I ran the test suite and measured the coverage, using the > code_coverage.py module that's part of Sancho. Here are the modules > which have less than half of their lines executed. (This only > measures modules that actually get imported.) Anyone want to > expand the test suite to exercise these modules more? In case it might be helpful, I've got a little utility program, called testgen, that will generate a unit test skeleton for an existing python module. The idea is to ease the burden of creating the starting point for coding unit tests, much of which is repetitive code, when you already have a functioning module. The easiest way to see exactly what testgen does is to look at the source code or run it on an existing module. By default it creates a new module with "test_" as the prefix and puts it in a "tests" subdirectory. By no means is it a silver bullet - you still need to flesh out the skeleton - but it can save time. You can get the program at: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/orbtech/Orbtech/TestUtil/test gen.py It does require Optik for command line options. And there are more features I intend to add, but the current version does work. --- Patrick K. O'Brien Orbtech From martin@v.loewis.de Thu May 16 20:50:26 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 16 May 2002 21:50:26 +0200 Subject: [XML-SIG] Test suite coverage In-Reply-To: References: Message-ID: Andrew Kuchling writes: > I ran the test suite and measured the coverage, using the > code_coverage.py module that's part of Sancho. Here are the modules > which have less than half of their lines executed. (This only > measures modules that actually get imported.) Anyone want to > expand the test suite to exercise these modules more? Is there a test > suite in 4XPath that could be added to PyXML? Yes, but that would take some work; the test suite relies on Ft.* being present. Regards, Martin From bestnuno@hotmail.com Fri May 17 16:02:30 2002 From: bestnuno@hotmail.com (bestnuno) Date: 18 May 2002 00:02:30 +0900 Subject: [XML-SIG] All rights reserved. Message-ID: <3W-SMTP-AJIfpT8vWyu0002673e@3w-smtp-aj.korea.com> --=_Boundary_zM1YHMjEfq7OSLhTSt9u Content-Type: text/plain; charset=euc-kr Content-Transfer-Encoding: 8bit *********************** The file, (Rights.bat), was infected with the WORM_KLEZ.H computer virus. The following action has been taken: remove. ***********-*********** --=_Boundary_zM1YHMjEfq7OSLhTSt9u Content-Type: message/rfc822 Content-Disposition: attachment; filename=originalmail.eml Received: from Dryjq ([211.186.39.85]) by 211.109.1.15 with Trend Micro InterScan Messaging Security Suite for SMTP v5.01; Fri, 17 May 2002 18:59:31 +0900 From: bestnuno To: xml-sig@python.org Subject: All rights reserved. MIME-Version: 1.0 Content-Type: multipart/alternative; boundary=M0Pw4c06cD094 --M0Pw4c06cD094 Content-Type: text/html; Content-Transfer-Encoding: quoted-printable --M0Pw4c06cD094 --M0Pw4c06cD094 Content-Type: application/octet-stream; name=20020513_23_04[1].jpg Content-Transfer-Encoding: base64 Content-ID: /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAHgAA/+IMWElDQ19QUk9GSUxF AAEBAAAMSExpbm8CEAAAbW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WTrj6Wa+BqrZetPmb3+QA94EU8dxj51jof5jR+11dPj/zoh/m+N/qqeK/k vmVyt/F/L8zYDuUY41lu8Rpt960kI/Yn9aqMlb8S/TlUR/5f8XU9lR36+perr1Xw1ZeNaYlr pae5nmcrWrXbYMJRnTDKGZlI9tM4038TW9tbnOOjZgdNzbhTybm5oQ10p6lAhxJNLFcOKCep Tl6mofVQBsvkXbJLLvd4QTJFp28fIK3rf61FX+9+YthswUjPxEwwKofSp8WrIR/zH8Dteh/+ bjq6Oeu/r61sb3p2x+H1r1v7v4fyW8KajqPXoT9x3PuHcpCSzRxXuFUlVt7MTSxbZveVnV7Y kEg1LHTwtlb2U7C32VSjoD5dZHbbu3cNuQrOZoxhZrX/ANWdTU3uz3jktIySMLMkmCn7qg4W XXlwoDdHHl99Z3VX1tV+Jgujv0U/eXLK8TRjVoUHTpsCGHAU3UGlGg6BCbdOxx1eHLDCoW3+ J6LdO/S/9z3b/posvxmj1e5bHTnUJd2vU0l9vuCsyojvONVyCoKgkAY4G2FTtlIHjZgGUXuA 18QRnjVWnxeGq97C+rlb03o0X8pj07aeN7VSSndE2bjb8iyLU3XVcP5rV69On2U3/wC0/T71 X8TP4H//2T== --M0Pw4c06cD094-- --=_Boundary_zM1YHMjEfq7OSLhTSt9u-- From xml-sig@python.org Tue May 21 20:54:42 2002 From: xml-sig@python.org (Albert Chin) Date: Tue, 21 May 2002 14:54:42 -0500 Subject: [XML-SIG] Reading characters Message-ID: <20020521145442.A1765@oolong.il.thewrittenword.com> I have an XML element that contains a lot of data (it's a base64 encoded file). Reading the characters through the default characters() function is slow (one line at a time). How can I read more? I'm using PyXML 0.7.1 and Python 2.2.1. -- albert chin (china@thewrittenword.com) From fdrake@acm.org Tue May 21 21:04:50 2002 From: fdrake@acm.org (Fred L. Drake, Jr.) Date: Tue, 21 May 2002 16:04:50 -0400 Subject: [XML-SIG] Reading characters In-Reply-To: <20020521145442.A1765@oolong.il.thewrittenword.com> References: <20020521145442.A1765@oolong.il.thewrittenword.com> Message-ID: <15594.43106.86530.228274@grendel.zope.com> Albert Chin writes: > I have an XML element that contains a lot of data (it's a base64 > encoded file). Reading the characters through the default characters() > function is slow (one line at a time). How can I read more? That's a general behavior of Expat which is not configurable at this time. -Fred -- Fred L. Drake, Jr. PythonLabs at Zope Corporation From martin@v.loewis.de Tue May 21 23:07:08 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 22 May 2002 00:07:08 +0200 Subject: [XML-SIG] Reading characters In-Reply-To: <20020521145442.A1765@oolong.il.thewrittenword.com> References: <20020521145442.A1765@oolong.il.thewrittenword.com> Message-ID: Albert Chin writes: > I have an XML element that contains a lot of data (it's a base64 > encoded file). Reading the characters through the default characters() > function is slow (one line at a time). How can I read more? > > I'm using PyXML 0.7.1 and Python 2.2.1. Can you elaborate? What kind of parsing technology do you use? Expat, SAX, minidom, something else? What do you mean by "read through"? Can you share a bit of code? Regards, Martin From xml-sig@python.org Wed May 22 00:33:38 2002 From: xml-sig@python.org (Albert Chin) Date: Tue, 21 May 2002 18:33:38 -0500 Subject: [XML-SIG] Reading characters In-Reply-To: ; from martin@v.loewis.de on Wed, May 22, 2002 at 12:07:08AM +0200 References: <20020521145442.A1765@oolong.il.thewrittenword.com> Message-ID: <20020521183338.A6399@oolong.il.thewrittenword.com> On Wed, May 22, 2002 at 12:07:08AM +0200, Martin v. Loewis wrote: > Albert Chin writes: > > > I have an XML element that contains a lot of data (it's a base64 > > encoded file). Reading the characters through the default characters() > > function is slow (one line at a time). How can I read more? > > > > I'm using PyXML 0.7.1 and Python 2.2.1. > > Can you elaborate? What kind of parsing technology do you use? Expat, > SAX, minidom, something else? I'm using expat to the best of my knowledge: from xml.sax import saxexts, saxlib ... fh = open (self.path, 'r') xmlh = read_pkg_db (self.data) p = saxexts.make_parser () p.setDocumentHandler (xmlh) p.parseFile (fh) fh.close () p.close () > What do you mean by "read through"? Can you share a bit of code? class read_pkg_db (saxlib.HandlerBase): def __init__ (self, data, extract = 0): self.in_data = 0 self.data = data self.extract = extract # whether or not to extract payload ... def startElement (self, name, attrs): ... def characters (self, ch, start, length): if self.in_data and self.extract: self.payload = self.payload + ch[start:start+length] ... Sample XML file: 2002-05-21T23:22:05Z m4 TWWm4 1.4 5 m u QlpoOTFBWSZTWaGX1TsBL+V/////////////////////////////////////////////4fZgDz61 ABSQpQAAbb1tvuilfS9gyp31kPqW9nX3b7Z8RSmb0zz3wAEQkAeA+xhAXIADtgKp9OgABoAAFAoA ... -- albert chin (china@thewrittenword.com) From xml-sig@python.org Wed May 22 00:34:16 2002 From: xml-sig@python.org (Albert Chin) Date: Tue, 21 May 2002 18:34:16 -0500 Subject: [XML-SIG] Reading characters In-Reply-To: <15594.43106.86530.228274@grendel.zope.com>; from fdrake@acm.org on Tue, May 21, 2002 at 04:04:50PM -0400 References: <20020521145442.A1765@oolong.il.thewrittenword.com> <15594.43106.86530.228274@grendel.zope.com> Message-ID: <20020521183416.B6399@oolong.il.thewrittenword.com> On Tue, May 21, 2002 at 04:04:50PM -0400, Fred L. Drake, Jr. wrote: > > Albert Chin writes: > > I have an XML element that contains a lot of data (it's a base64 > > encoded file). Reading the characters through the default characters() > > function is slow (one line at a time). How can I read more? > > That's a general behavior of Expat which is not configurable at this > time. Can I use another SAX parser in PyXML? -- albert chin (china@thewrittenword.com) From tpassin@comcast.net Wed May 22 00:49:34 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Tue, 21 May 2002 19:49:34 -0400 Subject: [XML-SIG] Reading characters References: <20020521145442.A1765@oolong.il.thewrittenword.com> <20020521183338.A6399@oolong.il.thewrittenword.com> Message-ID: <000f01c20122$28edbca0$0bf13044@tbp> [Albert Chin] > > What do you mean by "read through"? Can you share a bit of code? > > class read_pkg_db (saxlib.HandlerBase): > def __init__ (self, data, extract = 0): > self.in_data = 0 > self.data = data > self.extract = extract # whether or not to extract payload > > ... > > def startElement (self, name, attrs): > > ... > > def characters (self, ch, start, length): > if self.in_data and self.extract: > self.payload = self.payload + ch[start:start+length] > If there are many "ch" chunks to add to the payload, that might be the slowest part of the chain, especially if the payload gets large. There are two standard ways to speed such string concatenations up. You either use CStringIO and get the data from it when you are done adding, or you append each chunk to a list, then do list.join() at the end. Either one can give dramatic speedups if that's your problem. I'd certainly try one of these first. Cheers, Tom P From xml-sig@python.org Wed May 22 01:09:26 2002 From: xml-sig@python.org (Albert Chin) Date: Tue, 21 May 2002 19:09:26 -0500 Subject: [XML-SIG] Reading characters In-Reply-To: <000f01c20122$28edbca0$0bf13044@tbp>; from tpassin@comcast.net on Tue, May 21, 2002 at 07:49:34PM -0400 References: <20020521145442.A1765@oolong.il.thewrittenword.com> <20020521183338.A6399@oolong.il.thewrittenword.com> <000f01c20122$28edbca0$0bf13044@tbp> Message-ID: <20020521190926.C6399@oolong.il.thewrittenword.com> On Tue, May 21, 2002 at 07:49:34PM -0400, Thomas B. Passin wrote: > [Albert Chin] > > > > What do you mean by "read through"? Can you share a bit of code? > > > > def characters (self, ch, start, length): > > if self.in_data and self.extract: > > self.payload = self.payload + ch[start:start+length] > > > > If there are many "ch" chunks to add to the payload, that might be the > slowest part of the chain, especially if the payload gets large. There are > two standard ways to speed such string concatenations up. You either use > CStringIO and get the data from it when you are done adding, or you append > each chunk to a list, then do list.join() at the end. Either one can give > dramatic speedups if that's your problem. WOW! WOW! WOW! Without cStringIO: def characters (self, ch, start, length): if self.in_data and self.extract: self.payload += ch $ time ./pkg-inst [blah] [blah] 93.25s user 0.48s system 94% cpu 1:39.50 total With cStringIO: def characters (self, ch, start, length): if self.in_data and self.extract: self.payload.write (ch) $ time ./pkg-inst [blah] [blah] 5.36s user 0.41s system 50% cpu 11.467 total This is just unbelievable! Thanks a lot! -- albert chin (china@thewrittenword.com) From fdrake@acm.org Wed May 22 03:36:31 2002 From: fdrake@acm.org (Fred L. Drake, Jr.) Date: Tue, 21 May 2002 22:36:31 -0400 Subject: [XML-SIG] Reading characters In-Reply-To: <20020521183416.B6399@oolong.il.thewrittenword.com> References: <20020521145442.A1765@oolong.il.thewrittenword.com> <15594.43106.86530.228274@grendel.zope.com> <20020521183416.B6399@oolong.il.thewrittenword.com> Message-ID: <15595.1071.643644.247030@grendel.zope.com> Albert Chin writes: > Can I use another SAX parser in PyXML? There is xmlproc, which is written entirely in Python. I don't think it breaks input into separate lines, which may offer some improvement for performance, but I don't know that it isn't swallowed by the cost of implementing the parser in Python. It would be nice if Expat could avoid breaking the input into separate lines, at least as an option. This would be largely an issue for the underlying parser and not the Python binding. I suspect it would not be too difficult to do at least when the input and output encodings match (at the Expat library layer, not the Python layer). Here's a feature request for Expat: http://sourceforge.net/tracker/index.php?func=detail&aid=558977&group_id=10127&atid=110127 -Fred -- Fred L. Drake, Jr. PythonLabs at Zope Corporation From martin@v.loewis.de Wed May 22 07:40:56 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 22 May 2002 08:40:56 +0200 Subject: [XML-SIG] Reading characters In-Reply-To: <20020521190926.C6399@oolong.il.thewrittenword.com> References: <20020521145442.A1765@oolong.il.thewrittenword.com> <20020521183338.A6399@oolong.il.thewrittenword.com> <000f01c20122$28edbca0$0bf13044@tbp> <20020521190926.C6399@oolong.il.thewrittenword.com> Message-ID: Albert Chin writes: > This is just unbelievable! Thanks a lot! I suspected that you would perform repeated addition of the characters you get. This algorithm is quadratic in length of the final string (if you have chunks of limited length), since the first character is copied over and over again. Without seeing the source, that was impossible to know for sure, though. Regards, Martin From tpassin@comcast.net Wed May 22 13:40:05 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Wed, 22 May 2002 08:40:05 -0400 Subject: [XML-SIG] Reading characters References: <20020521145442.A1765@oolong.il.thewrittenword.com> <20020521183338.A6399@oolong.il.thewrittenword.com> <000f01c20122$28edbca0$0bf13044@tbp> <20020521190926.C6399@oolong.il.thewrittenword.com> Message-ID: <000a01c2018d$cccc1ae0$0bf13044@tbp> [Albert Chin] > > If there are many "ch" chunks to add to the payload, that might be the > > slowest part of the chain, especially if the payload gets large. There are > > two standard ways to speed such string concatenations up. You either use > > CStringIO and get the data from it when you are done adding, or you append > > each chunk to a list, then do list.join() at the end. Either one can give > > dramatic speedups if that's your problem. > > WOW! WOW! WOW! > Yes, pretty amazing. Works in javascript, too, where you do it with arrays. Cheers, Tom P From matt@reprocessed.org Wed May 22 16:44:34 2002 From: matt@reprocessed.org (Matt Patterson) Date: Wed, 22 May 2002 16:44:34 +0100 Subject: [XML-SIG] outputting non-ascii strings Message-ID: Hello, I've been lurking on this list for a while and am trying my hand at some SAX processing for the first time. I've done a small amount of DOM processing, but I'm still a relative Python newbie. I've run into an irritating and (hopefully) newbie-related problem: Parsing an XML file containing Unicode characters using SAX works fine, until I actually want to output the character stream somewhere: having tried print() and write() I've hit the same error - the unicode text is being automatically converted to 7-bit ASCII and the non ASCII characters (typographer's quotes, in this case) are causing the operation to fail: > Traceback (most recent call last): > File "./reprocessed_generate.py", line 16, in ? > outputFile.write(cHandler.body) > UnicodeError: ASCII encoding error: ordinal not in range(128) How can I output a UTF-8 text file? (Or output UTF-8 strings to stdout, for that matter.) Thank you Matt -- Matt Patterson | Typographer | http://reprocessed.org/ From Juergen Hermann" Message-ID: On Wed, 22 May 2002 16:44:34 +0100, Matt Patterson wrote: >How can I output a UTF-8 text file? (Or output UTF-8 strings to stdout,= >for that matter.) Two ways: Explicit: stream.write(u.encode('utf-8')) Implicit: Use codecs.lookup('utf-8') to get reader/writer wrappers, then= you say utf8_stdout =3D utf8_wrapper(sys.stdout) Ciao, J=FCrgen From martin@v.loewis.de Wed May 22 20:02:31 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 22 May 2002 21:02:31 +0200 Subject: [XML-SIG] outputting non-ascii strings In-Reply-To: References: Message-ID: "Juergen Hermann" writes: > Explicit: stream.write(u.encode('utf-8')) > > Implicit: Use codecs.lookup('utf-8') to get reader/writer wrappers, then > you say utf8_stdout = utf8_wrapper(sys.stdout) Since Python 2.2, it is better to use codecs.getwriter("utf-8"), since that saves the trouble of knowing in which order the result of .lookup is. Regards, Martin From matt@reprocessed.org Wed May 22 21:39:54 2002 From: matt@reprocessed.org (Matt Patterson) Date: Wed, 22 May 2002 21:39:54 +0100 Subject: [XML-SIG] outputting non-ascii strings In-Reply-To: Message-ID: On 22/5/02, Martin v. Loewis wrote: > "Juergen Hermann" writes: > > > Implicit: Use codecs.lookup('utf-8') to get reader/writer wrappers, > > then you say utf8_stdout = utf8_wrapper(sys.stdout) > > Since Python 2.2, it is better to use codecs.getwriter("utf-8"), since > that saves the trouble of knowing in which order the result of .lookup > is. I'm using Python 2.1.3, and PyXML 0.7, so that isn't an option for me, and as I said to Juergen - I'm still a python newbie, and the reader/writer wrappers thing is a bit beyond me... The other thing that's cropped up now - using Juergen's suggestion to use stream.write(ustring.encode('utf-8')), which works a treat, decodes all the entities in the text, so I now have free-floating ampersands and angle brackets, where before I had entities. I do have typographer's quotes still :-) Is there an easy way around this problem? I've looked through my Python books (Learning Python, Programming Python, Python and XML) and can't find a comprehensive treatment of this issue - if there is one I'd like to know, please! Is there a good place to go and look for such documentation? Thanks again Matt -- Matt Patterson | Typographer | http://reprocessed.org/ From Juergen Hermann" Message-ID: On Wed, 22 May 2002 21:39:54 +0100, Matt Patterson wrote: >Is there an easy way around this problem? Is there a problem? With UTF-8, you need no stinkin' entities! But if you insist on burning cpu cycles: >>> ''.join([c.encode('ascii', 'ignore') or "&#%d;" % ord(c) for c in u'= \u8314=E4=F6=FC=DF?abc']) '茔„”á?abc' Ciao, J=FCrgen From martin@v.loewis.de Thu May 23 07:44:50 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 23 May 2002 08:44:50 +0200 Subject: [XML-SIG] outputting non-ascii strings In-Reply-To: References: Message-ID: Matt Patterson writes: > The other thing that's cropped up now - using Juergen's suggestion to > use stream.write(ustring.encode('utf-8')), which works a treat, decodes > all the entities in the text, so I now have free-floating ampersands and > angle brackets, where before I had entities. I do have typographer's > quotes still :-) > > Is there an easy way around this problem? I've looked through my Python > books (Learning Python, Programming Python, Python and XML) and can't > find a comprehensive treatment of this issue - if there is one I'd like > to know, please! Is there a good place to go and look for such > documentation? I'm not sure what issue you are referrring to, here? Are you saying that, - when using XML library functions to generate XML, it will produce ampersands and angle brackets which are not markup? That would be a bug; please report details. - when using your own custom XML generating functions, you see such things? You may use xml.sax.saxutils.escape to replace them with the built-in entity references. - with your custom writeback routines, you see more "literal" characters in the output text than you originally had in the input document, and you want them all back, exactly where they used to be? This is not possible. You have the option of searching the output strings yourself, and either writing character references or entity references where appropriate. Regards, Martin From martin@v.loewis.de Thu May 23 07:45:53 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 23 May 2002 08:45:53 +0200 Subject: [XML-SIG] outputting non-ascii strings In-Reply-To: References: Message-ID: "Juergen Hermann" writes: > Is there a problem? With UTF-8, you need no stinkin' entities! If the output is XML, you sure do: atleast for & < > Regards, Martin From rathnaprabhu1@hotmail.com Thu May 23 21:21:51 2002 From: rathnaprabhu1@hotmail.com (RATHNA PRABHU RAJENDRAN) Date: Thu, 23 May 2002 20:21:51 +0000 Subject: [XML-SIG] Transforming text data to XML Message-ID: Hi all, Are there any libraries for converting text data to xml ? I tried using the XMLGenerator that comes along with saxutils, but it has no support for DTD. Is there any python library which does the following : Given a DTD and a text file, outputs well-formed valid XML data (atleast something close to this functionality ) ? Thanks in advance, Prabhu ================================== RathnaPrabhu Rajendran www.cs.arizona.edu/people/prabhu Graduate Associate, Teaching University of Arizona Tucson USA ================================== _________________________________________________________________ MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx From lolita86@libero.it Thu May 23 18:25:03 2002 From: lolita86@libero.it (lolita) Date: Fri, 24 May 2002 00.25.07 +0200 Subject: [XML-SIG] Eros e soldi:guadagna con internet 0,08 euro a clic Message-ID: sono lolita=2C voglio presentarti il mio nuovo sito affiliazione gratuita con guadagni immediati=3A erotismo=2C chat=2Cloghi e sonerie etc=2C etc=2C l'unico sito che paga cos=EC tanto 0=2C08 euro a clic =2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2Eguarda bene la pg di affiliazione=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2E=2Ee buon divertimento=2E visita il sito=3A http=3A=2F=2Fmembers=2Exoom=2Eit=2Fmarym1976 http=3A=2F=2Fmembers=2Exoom=2Eit=2Fmarym1976 http=3A=2F=2Fmembers=2Exoom=2Eit=2Fmarym1976 From martin@v.loewis.de Fri May 24 08:45:35 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 24 May 2002 09:45:35 +0200 Subject: [XML-SIG] Transforming text data to XML In-Reply-To: References: Message-ID: "RATHNA PRABHU RAJENDRAN" writes: > Is there any python library which does the following : > Given a DTD and a text file, outputs well-formed valid XML data > (atleast something close to this functionality ) ? No, and I think it is pretty much impossible to implement such a library (assuming you meant not just well-formed, but valid). Actually, interpreting your question strictly, it is very easy to do so, since you did not require that the text and the resulting XML file bear any relationship. So given the text of your question, and the XHTML DTD, a resulting file could read It certainly is possible to implement such a library, but I doubt this is what you want... Regards, Martin From ians@etrials.com Fri May 24 14:06:29 2002 From: ians@etrials.com (Ian Sparks) Date: Fri, 24 May 2002 09:06:29 -0400 Subject: [XML-SIG] Schema -> Python Objects framework? Message-ID: <3758A5EAF91DD411AF3600B0D02188DD83B29E@mail.etrials.com> I have on occasion found myself writing python classes with the ability to read and write themselves to XML : class x: def toxml(self): return '' % (xmlencode(self.att1),xmlencode(self.att2)) def fromxml(self,element): self.att1 = element.getAttribute('att1') ... Sometimes this is more useful than using a DOM directly (for instance, where you want to keep memory usage low). It occurs to me that it might be fairly easy to write some code that would take an XML Schema and convert it into skeleton python classes with these toXML() and fromXML() methods auto-generated. This then begs the question : Has anyone done this? - Ian Sparks. From Matt Gushee Fri May 24 17:21:19 2002 From: Matt Gushee (Matt Gushee) Date: Fri, 24 May 2002 10:21:19 -0600 Subject: [XML-SIG] Schema -> Python Objects framework? In-Reply-To: <3758A5EAF91DD411AF3600B0D02188DD83B29E@mail.etrials.com> References: <3758A5EAF91DD411AF3600B0D02188DD83B29E@mail.etrials.com> Message-ID: <20020524162119.GA434@swordfish.havenrock.com> On Fri, May 24, 2002 at 09:06:29AM -0400, Ian Sparks wrote: > > I have on occasion found myself writing python classes with the ability to > read and write themselves to XML : > > It occurs to me that it might be fairly easy to write some code that would > take an XML Schema and convert it into skeleton python classes with these > toXML() and fromXML() methods auto-generated. > > This then begs the question : Has anyone done this? Thought about it, never got around to it. And I'm not aware of any Python package that handles XML Schema in any way. If you do this, I hope you will share your work with the community. I imagine many people would be interested. By the way, has it occurred to you that your XML object serialization stuff could be more flexible, and probably lose little or nothing in performance, if you used dictionaries for attributes instead of hard- coding their names? -- Matt Gushee Englewood, Colorado, USA mgushee@havenrock.com http://www.havenrock.com/ From rsalz@datapower.com Fri May 24 18:49:21 2002 From: rsalz@datapower.com (Rich Salz) Date: Fri, 24 May 2002 13:49:21 -0400 Subject: [XML-SIG] Schema -> Python Objects framework? References: <3758A5EAF91DD411AF3600B0D02188DD83B29E@mail.etrials.com> <20020524162119.GA434@swordfish.havenrock.com> Message-ID: <3CEE7D21.9000309@datapower.com> > Thought about it, never got around to it. And I'm not aware of any Python > package that handles XML Schema in any way. http://soapy.sf.net /r$ From ians@etrials.com Fri May 24 19:03:20 2002 From: ians@etrials.com (Ian Sparks) Date: Fri, 24 May 2002 14:03:20 -0400 Subject: [XML-SIG] Schema -> Python Objects framework? Message-ID: <3758A5EAF91DD411AF3600B0D02188DD83B2A6@mail.etrials.com> Thanks Praveen, looks like xml_Objectify does some of what I want. Good pointer from Rich too (thank you)... I suppose SOAP serialization would require this Python <-> XML encoding, though I was under the impression that SOAP was an object *access* protocol rather than a way of passing python objects themselves. I'll look into that too. - Ian S. -----Original Message----- From: Praveen Kumar [mailto:pk1u@yahoo.com] Sent: Friday, May 24, 2002 1:33 PM To: ians@etrials.com Cc: mertz@gnosis.cx Subject: re: [XML-SIG] Schema -> Python Objects framework? Ian, I've been looking for this too. It would be nice if the util/module also included a framework for generating sql tables and doing the binding among xml, python objects, and sql tables; like Castor for Java ( see http://www.castor.org/ ). Something you might find useful is xml_objectify; see http://www-106.ibm.com/developerworks/xml/library/xml-matters2/index.html?dw zone=xml I know that the author, David Mertz ( mertz@gnosis.cx ), is working on these problems; I'm a bit too swamped atm to work on it, but if you're interested, maybe the two of you can coordinate work on these problems. Regards, Praveen ----- From: Ian Sparks To: xml-sig@python.org Date: Fri, 24 May 2002 09:06:29 -0400 Subject: [XML-SIG] Schema -> Python Objects framework? I have on occasion found myself writing python classes with the ability to read and write themselves to XML : class x: def toxml(self): return '' % (xmlencode(self.att1),xmlencode(self.att2)) def fromxml(self,element): self.att1 = element.getAttribute('att1') ... Sometimes this is more useful than using a DOM directly (for instance, where you want to keep memory usage low). It occurs to me that it might be fairly easy to write some code that would take an XML Schema and convert it into skeleton python classes with these toXML() and fromXML() methods auto-generated. This then begs the question : Has anyone done this? - Ian Sparks. __________________________________________________ Do You Yahoo!? LAUNCH - Your Yahoo! Music Experience http://launch.yahoo.com From mertz@gnosis.cx Fri May 24 19:56:17 2002 From: mertz@gnosis.cx (David Mertz, Ph.D.) Date: Fri, 24 May 2002 14:56:17 -0400 Subject: [XML-SIG] Schema -> Python Objects framework? Message-ID: Ian Sparks wrote: |Thanks Praveen, looks like xml_Objectify does some of what I want. |I have on occasion found myself writing python classes |with the ability to read and write themselves to XML : I'm coming into the middle of this conversation, so I might be missing some context. But I think that xml_pickle might come even closer to accomplishing what you want. All my utilities/libraries are now in a common package, and you can find it at: http://gnosis.cx/download/Gnosis_Utils-current.tar.gz You've always been able to add the ability to serialize an object to (xml_pickle dialect) XML, by mixing in inheritence from XML_Pickler. But I've recently, quietly, added a (mostly untested, semi-documented) metaclass approach to the idea. I find this possibility really quite fascinating, but probably too magical for most users: Python 2.2 (#0, Dec 24 2001, 18:42:48) [EMX GCC 2.8.1] on os2emx Type "help", "copyright", "credits" or "license" for more information >>> import gnosis.magic >>> __metaclass__ = gnosis.magic.MetaPickler >>> class Boring: ... def __init__(self): ... self.this = 'that' ... self.spam = 'eggs' ... def print_spam(self): ... print self.spam ... >>> boring = Boring() >>> boring.print_spam() eggs >>> print boring.dumps() Basically, the contrast between xml_pickle and xml_objectify is the following: if you have arbitrary Python objects, and you want to make XML out of them, use xml_pickle; if you have arbitrary XML dialects, and you want to make Python objects out of them, use xml_objectify. Unfortunately, I think the two aspects cannot be 100% unified. Yours, David... -- ---[ to our friends at TLAs (spread the word) ]-------------------------- Echelon North Korea Nazi cracking spy smuggle Columbia fissionable Stego White Water strategic Clinton Delta Force militia TEMPEST Libya Mossad ---[ Postmodern Enterprises ]-------------------------- From phthenry@earthlink.net Sun May 26 00:14:20 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Sat, 25 May 2002 19:14:20 -0400 Subject: [XML-SIG] losing cdata tag Message-ID: <20020525191420.I16955@localhost.localdomain> I have copied the code below from python cookbook, but it is not working. Specifically, the "def startCDATA(self)" method does not get invoked. Since this method does not get invoked, my cdata is not getting put between the right tags. That means my output file is no longer valid xml, and I cannot parse it again. Thanks Paul ************** #!/usr/bin/python from xml.sax import sax2exts, saxutils, handler from xml.sax import SAXNotSupportedException, SAXNotRecognizedException import sys class EchoGenerator(saxutils.XMLGenerator): def __init__(self, out=None, encoding="iso-8859-1"): saxutils.XMLGenerator.__init__(self, out, encoding) self._in_entity = 0 self._in_cdata = 0 def characters(self, content): if self._in_entity: return elif self._in_cdata: self._out.write(content) else: saxutils.XMLGenerator.characters(self, content) # -- LexicalHandler interface def comment(self, content): self._out.write('' % content) def startDTD(self, name, public_id, system_id): self._out.write('\n') def startEntity(self, name): self._out.write('&%s;' % name) self._in_entity = 1 def endEntity(self, name): self._in_entity = 0 def startCDATA(self): self._out.write('') self._in_cdata = 0 def test(xmlfile): parser = sax2exts.make_parser([ 'pirxx', 'xml.sax.drivers2.drv_xmlproc', 'xml.sax.drivers2.drv_pyexpat', ]) print >>sys.stderr, "*** Using", parser try: parser.setFeature(handler.feature_namespaces, 1) except (SAXNotRecognizedException, SAXNotSupportedException): print "not recognized" try: parser.setFeature(handler.feature_validation, 0) except (SAXNotRecognizedException, SAXNotSupportedException): print "not recognized" saxhandler = EchoGenerator() parser.setContentHandler(saxhandler) parser.setProperty(handler.property_lexical_handler, saxhandler) parser.parse(xmlfile) if __name__ == "__main__": file = "/home/paul/Documents/help.notes/my_python_documentation.xml" test(file) -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From Juergen Hermann" Message-ID: On Sat, 25 May 2002 19:14:20 -0400, Paul Tremblay wrote: >I have copied the code below from python cookbook, but it is not >working. Specifically, the "def startCDATA(self)" method does not >get invoked. That depends on the parser you use. >Since this method does not get invoked, my cdata is not getting >put between the right tags. That means my output file is no >longer valid xml, and I cannot parse it again. Are you sure on that, or did you just guess that? When in_cdata is never set, ALL text becomes escaped, i.e. the output is still valid XML, even if without CDATA sections. Ciao, J=FCrgen From phthenry@earthlink.net Mon May 27 05:14:57 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Mon, 27 May 2002 00:14:57 -0400 Subject: [XML-SIG] losing cdata tag In-Reply-To: References: <20020525191420.I16955@localhost.localdomain> Message-ID: <20020527001456.K16955@localhost.localdomain> On Sun, May 26, 2002 at 09:35:48PM +0200, Juergen Hermann wrote: > > > >I have copied the code below from python cookbook, but it is not > >working. Specifically, the "def startCDATA(self)" method does not > >get invoked. > > That depends on the parser you use. Yes, I was afraid this was the case. In fact, I don't know what parser I am using! Pardon me for my ignorance. I know that expat in on my system. I also know that just about 3 weeks ago I downloaded the library from python--not the newest one, but the one that has been a standard for a long time. (Does the snippet of code tell you what parsere I am using?) > > >Since this method does not get invoked, my cdata is not getting > >put between the right tags. That means my output file is no > >longer valid xml, and I cannot parse it again. > > Are you sure on that, or did you just guess that? When in_cdata is > never set, ALL text becomes escaped, i.e. the output is still valid > XML, even if without CDATA sections. Yes, I did try to parse the data again with no luck. When I use an xslt style sheet with xsltproc, the CDATA in fact becomes escaped. But when I use these libraries: from xml.sax import saxutils from xml.sax import make_parser from xml.sax.handler import feature_namespaces the data is not escaped. Specifially, I had this between my CDATA: This was passed on as "" and not <some text>. I have come up with a temporary solution. Before I parse my file, I change the following lines: re.sub(r"", "##END OF CDATA##\n"]]>) After I parse the file, I know exactly where my CDATA flags began and end, and I replace them with the tags again ("<[CDATA[" and "]]>"). I am then ready to parse the data again. Although my method works, it seems like a pretty bad hack. Thanks Paul -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From martin@v.loewis.de Mon May 27 07:43:37 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 27 May 2002 08:43:37 +0200 Subject: [XML-SIG] losing cdata tag In-Reply-To: <20020527001456.K16955@localhost.localdomain> References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> Message-ID: Paul Tremblay writes: > Yes, I was afraid this was the case. In fact, I don't know what > parser I am using! Pardon me for my ignorance. I know that expat > in on my system. I also know that just about 3 weeks ago I > downloaded the library from python--not the newest one, but the > one that has been a standard for a long time. (Does the snippet > of code tell you what parsere I am using?) Not really. It first tries pirxx (which is not part of PyXML, but could be installed on your system); it then tries xmlproc, then expat. With PyXML installed and pirxx not, it will always use xmlproc. > the data is not escaped. I cannot reproduce this problem. Given the document ]]> your original code will produce the output *** Using <some text> with PyXML 0.7.1, and pirx not installed. If I remove the xmlproc option, I get *** Using ]]> so with pyexpat, it even puts the CDATA back in. So again, I cannot see a problem. Regards, Martin From Juergen Hermann" Message-ID: On Mon, 27 May 2002 00:14:57 -0400, Paul Tremblay wrote: >escaped. But when I use these libraries: > > >from xml.sax import saxutils >from xml.sax import make_parser >from xml.sax.handler import feature_namespaces > >the data is not escaped. If you except the data your character() event receives to be escaped, this is a wrong assumption. That is why you use a parser, to not have to do things yourself. Ciao, J=FCrgen From stephane.bidoul@softwareag.com Mon May 27 15:06:06 2002 From: stephane.bidoul@softwareag.com (=?iso-8859-1?Q?St=E9phane_Bidoul?=) Date: Mon, 27 May 2002 16:06:06 +0200 Subject: [XML-SIG] Jython experience with std. lib. XML and PyXML? In-Reply-To: <200205141151.g4EBp0Xw011368@hirsch.in-berlin.de> Message-ID: <001301c20587$a672a410$8614200a@acsesbi> For me, it does work quite well (PyXML 0.7.0 & Jython 2.1). To set it up, I renamed _xmlplus to lib/xml, effectively replacing the xml package from the std jython lib (I seem to recall that the _xmlplus magic did not work well under jython, but I don't know the specifics anymore). I had only 2 minor issues:=20 - the xmlproc sax driver has a bug=20 (a minor one, actually, but important for my purpose): pyxml bug #503411: changing content handler during parse - the javasax driver is not completely finished: it lacks some xml namespace support: I patched it up=20 just enough to fill my needs [if anyone is interested,=20 I can polish up those patches and submit them] There is also an issue with the javasax driver (pyxml bug #503823) and python streams, but that one looks difficult to solve (how to map a python file object to a java stream?) 'hope this helps. -Stephane > -----Original Message----- > From: gherman@darwin.in-berlin.de [mailto:gherman@darwin.in-berlin.de] > Sent: 14 May, 2002 13:51 > To: xml-sig@python.org > Subject: [XML-SIG] Jython experience with std. lib. XML and PyXML? >=20 >=20 > Message-ID: <1021377060.3ce0fa2471c09@webmail.in-berlin.de> > Date: Tue, 14 May 2002 13:51:00 +0200 (CEST) > From: Dinu Gherman > MIME-Version: 1.0 > Content-Type: text/plain; charset=3DISO-8859-1 > Content-Transfer-Encoding: 8bit > User-Agent: IMP/PHP IMAP webmail program 2.2.6 > X-Originating-IP: 217.5.90.230 >=20 > Hi,=20 > =20 > does anybody here want to share her experience using the standard=20 > library XML modules and/or the PyXML extensions with Jython? > =20 > Thanks,=20 > =20 > Dinu >=20 >=20 > _______________________________________________ > XML-SIG maillist - XML-SIG@python.org > http://mail.python.org/mailman/listinfo/xml-sig From jedp@ilm.com Tue May 28 17:45:49 2002 From: jedp@ilm.com (Jed Parsons) Date: Tue, 28 May 2002 09:45:49 -0700 (PDT) Subject: [XML-SIG] xslt: incorporating xml with document() Message-ID: <200205281645.JAA25901@ocean.lucasdigital.com> Salutations. I want to incorporate some xml pieces into a larger document using the document() function in xslt with 4xslt. When I do, xsl:numbers for elements in the original document get reset on the corresponding elements in the included xml. Here's an example - two xml documents, a stylesheet, and some output: * * * This document: * * *
One
Three
* * * And this document called "tiny.xml": * * *
Insert me as number Two
* * * When munged by this stylesheet: * * *

.

* * * Give me this result: * * *

1. One

1. Insert me as number Two

2. Three

What can I do to ensure that elements in the included document will be enuerated in the same series as elements in the original document? Thanks for any advice, Jed -- Jed Parsons Industrial Light + Magic (415) 448-2974 grep(do{for(ord){(!$_&&print"$s\n")||(($O+=(($_-1)%6+1)and grep(vec($s,$O++,1)=1,1..int(($_-6*6-1)/6))))}},(split(//, "++,++2-27,280,481=1-7.1++2,800+++2,8310/1+4131+1++2,80\0. What!?"))); From reagle@w3.org Tue May 28 21:31:21 2002 From: reagle@w3.org (Joseph Reagle) Date: Tue, 28 May 2002 16:31:21 -0400 Subject: [XML-SIG] C14N Performacne Message-ID: <20020528203122.685E912AB@policy.w3.org> Doing XPath selection and C14N has *terrible* performance with PyXML. For a 100K xml file, it's not even worth it, I'll walk away from the computer come back later, and it'll still be working at it. The big problem is the XPath evaluation. The default nodeset that is canonicalized is to "blow up" the input document/nodeset akin to a "pattern = '(//. | //@* | //namespace::*)'" [1] I know this is a very bad (slow) evaluation (this is where I time-out) so can anyone suggest an optimization/alternative I can use in its place? test_c14n.py ... pattern = '(//. | //@* | //namespace::*)' ... r = PYE() dom = r.fromStream(IN) context = Context(dom, processorNss=nsdict) nodelist = xpath.Evaluate(query, context=context) if exclusive: Canonicalize(dom, OUT, subset=nodelist, comments=comments, unsuppressedPrefixes=pfxlist) else: Canonicalize(dom, OUT, subset=nodelist, comments=comments) # nsdict=nsdict OUT.close() [1] http://www.w3.org/TR/2001/REC-xml-c14n-20010315#DefaultExpression ---------- Forwarded Message ---------- Subject: Re: Exclusive C14n in Apache Date: Tue, 28 May 2002 16:24:03 -0400 From: Joseph Reagle To: Christian Geuer-Pollmann , jboyer@PureEdge.com Cc: w3c-ietf-xmldsig@w3.org On Monday 27 May 2002 11:29 am, Christian Geuer-Pollmann wrote: > Well, the main difference between inclusive and exclusive c14n is that in > inclusive c14n, I can simply output the changes to the inscope namespace > decls. In exclusive c14n, I also have to check whether a namespace is > visibly utilized. That's the additional overhead. But I have to reduce > this 1.3-1.6 to a lower level of 1.1-1.2. Yes, so that should mean for every element one tests to see if the node.prefix or any of the attributes prefixes are the same as the namespace prefix avaible in its axis. I haven't dug deeply but in the small tests I can do, this is a neglible difference in performance (and for other reasons, exc-c14n tends to be slight faster as the size of the document grows.) However, I'll also say I'm not expert at this... ------------------------------------------------------- -- Joseph Reagle Jr. http://www.w3.org/People/Reagle/ W3C Policy Analyst mailto:reagle@w3.org IETF/W3C XML-Signature Co-Chair http://www.w3.org/Signature/ W3C XML Encryption Chair http://www.w3.org/Encryption/2001/ From phthenry@earthlink.net Wed May 29 05:28:07 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Wed, 29 May 2002 00:28:07 -0400 Subject: [XML-SIG] losing cdata tag In-Reply-To: References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> Message-ID: <20020529002807.A6147@localhost.localdomain> On Mon, May 27, 2002 at 08:43:37AM +0200, Martin v. Loewis wrote: > > Paul Tremblay writes: > > Not really. It first tries pirxx (which is not part of PyXML, but > could be installed on your system); it then tries xmlproc, then > expat. With PyXML installed and pirxx not, it will always use xmlproc. > I can't figure out what xml processor python is using: which: no xmlproc in (/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/paul/bin) which: no expat in (/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/paul/bin) which: no pirxx in (/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/paul/bin) In fact, expat is part of my Mandrake distribution, so I could install this. How exactly do you find out which processor is being used, and how can you control this? > > I cannot reproduce this problem. Given the document > > > > ]]> > I re-tried my code with your example above, and got this result: The code I'm using is below. Thanks! Paul *************************** #!/usr/bin/python from xml.sax import saxutils from xml.sax import make_parser from xml.sax.handler import feature_namespaces class CopyTree(saxutils.DefaultHandler): def __init__(self): self.character = "" def startElement(self, name, attrs): print "<" + name, for theKey in attrs.keys(): print " " + theKey + "=\"" + attrs[theKey] + "\"", print ">", def characters(self, ch): self.character = self.character + ch def endElement(self, name): print self.character + "", self.character="" parser = make_parser() #Tell the parser we are not interested in XML namespaces parser.setFeature(feature_namespaces, 0) # Create the handler dhObj = CopyTree() # Tell the parser to use our handler parser.setContentHandler(dhObj) # Parse the input file = "/home/paul/paultemp/test.xml" parser.parse(file) -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From Juergen Hermann" Message-ID: On Wed, 29 May 2002 00:28:07 -0400, Paul Tremblay wrote: >I can't figure out what xml processor python is using: >>> from xml.sax import sax2exts >>> p =3D sax2exts.make_parser() >>> print p Easy, ain't it? ;) Ciao, J=FCrgen From martin@v.loewis.de Wed May 29 08:41:45 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 29 May 2002 09:41:45 +0200 Subject: [XML-SIG] losing cdata tag In-Reply-To: <20020529002807.A6147@localhost.localdomain> References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> Message-ID: Paul Tremblay writes: > I can't figure out what xml processor python is using: > > which: no xmlproc in (/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/paul/bin) > which: no expat in (/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/paul/bin) > which: no pirxx in (/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/usr/games:/home/paul/bin) Neither xmlproc nor pirxx is an executable program on any system. Instead, they are libraries. xmlproc ships with Python, so you most definitely have it available. > I re-tried my code with your example above, and got this result: What version of PyXML are you using? Can you try 0.7.1? Regards, Martin From mike@skew.org Wed May 29 10:01:40 2002 From: mike@skew.org (Mike Brown) Date: Wed, 29 May 2002 03:01:40 -0600 (MDT) Subject: [XML-SIG] xslt: incorporating xml with document() In-Reply-To: <200205281645.JAA25901@ocean.lucasdigital.com> "from Jed Parsons at May 28, 2002 09:45:49 am" Message-ID: <200205290901.g4T91eJl030495@chilled.skew.org> Jed Parsons wrote: > What can I do to ensure that elements in the included document will be > enuerated in the same series as elements in the original document? The relative order of nodes from different documents is unspecified; it will vary from processor to processor. It won't be possible to use xsl:number to predictably generate a number that is based on the current node's position relative to others that span multiple documents. Likewise, it won't be possible to use position() to generate the numbers, if you were to select and iterate over the entire cross-document node-set. I would look at simulating the behavior of xsl:number with something else that will dig into the included docs where necessary. I'd try it with one or two recursive templates. It could get hairy. Given a root node of a document, count the number of sections in that document. Process the includes in that document by getting the root nodes of those documents and adding that to the count you just got. Add the final result to count(ancestor::section) and add 1? If you get stuck again, ask on xsl-list (see www.mulberrytech.com for info about the list). - Mike ____________________________________________________________________________ mike j. brown | xml/xslt: http://skew.org/xml/ denver/boulder, colorado, usa | resume: http://skew.org/~mike/resume/ From Olivier.Cayrol@logilab.fr Wed May 29 10:49:03 2002 From: Olivier.Cayrol@logilab.fr (Olivier CAYROL (Logilab)) Date: Wed, 29 May 2002 11:49:03 +0200 (CEST) Subject: [XML-SIG] xslt: incorporating xml with document() In-Reply-To: <200205281645.JAA25901@ocean.lucasdigital.com> Message-ID: On 05-28-2002, Jed Parsons wrote: > > version=3D"1.0" > xmlns=3D"http://www.w3.org/1999/xhtml"> > ... > > >

> . > >

> > >
This xsl:number instruction numbers the
element inside the current document. - For your first
node, you get the number 1. - Then, with your node, you use the document() function and you are changing your current document. In this new document, your node is the first one so you get the number 1. - Then, you're coming back to your first document (that is again your current document) and in this document, the next
node is the second one so you get number 2. > What can I do to ensure that elements in the included document will be > enuerated in the same series as elements in the original document? The only way I see is either using a processor that implements the xinclude behaviour (see http://www.w3.org/TR/xinclude/ ) or transforming your xml in two steps (first one for processing elements and second one for turning the XML to HTML). O. CAYROL. _________________________________________________________________________ Olivier CAYROL LOGILAB - Paris (France) http://www.logilab.com/ Change your millenium, try NARVAL the Intelligent Personal Assistant. Changez de mill=E9naire, essayez NARVAL l'Assistant Personnel Intelligent. _________________________________________________________________________ From Alexandre.Fayolle@logilab.fr Wed May 29 13:22:26 2002 From: Alexandre.Fayolle@logilab.fr (Alexandre) Date: Wed, 29 May 2002 14:22:26 +0200 Subject: [XML-SIG] where to ask python/libxml2 related questions ? Message-ID: <20020529122226.GA6420@orion.logilab.fr> Hello, Since this mailing list is not only about PyXML, I was wondering if it was a good place to ask python-specific questions on libxml2 and libxslt, or if the gnome project mailing lists are better suited (and then which one? xml-bindings?. Looking for python in the gnome mailing lists xml, xml-bindings and xslt doesn't show much traffic on the topic (or shows that the search engine is very broken). Alexandre Fayolle -- LOGILAB, Paris (France). http://www.logilab.com http://www.logilab.fr http://www.logilab.org Narval, the first software agent available as free software (GPL). From samuzeau@oreka.com Wed May 29 14:17:28 2002 From: samuzeau@oreka.com (Pascal Samuzeau) Date: Wed, 29 May 2002 14:17:28 +0100 Subject: [XML-SIG] [XML-checkins]Try to install PyXML under WinNT Message-ID: <200205291217.OAA85390@mailhub1.isdnet.net> Hi, I've tried to install PyXML under WinNT without results. I failed on : "cl.exe not found..." For sure, I haven't cl.exe on my server.But where I can get it? It seems to belong of Visual C++ Do I have to have Visual C++ on my server ???? Sincerily PS -------------------------------------------------- Oreka ! Nous sommes l'internet moins cher ! Surfez 25% moins cher avec http://www.oreka.com _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm _______________________________________________ Pyxml-checkins mailing list Pyxml-checkins@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pyxml-checkins From tpassin@comcast.net Wed May 29 13:35:50 2002 From: tpassin@comcast.net (Thomas B. Passin) Date: Wed, 29 May 2002 08:35:50 -0400 Subject: [XML-SIG] where to ask python/libxml2 related questions ? References: <20020529122226.GA6420@orion.logilab.fr> Message-ID: <002201c2070d$5df769a0$0bf13044@tbp> [Alexandre] This is the one, according to Daniel Veillard (If he doesn't know, who would?) http://mail.gnome.org/mailman/listinfo/xml (email address:xml@gnome.org) Cheers, Tom P > > Since this mailing list is not only about PyXML, I was wondering if it > was a good place to ask python-specific questions on libxml2 and > libxslt, or if the gnome project mailing lists are better suited (and > then which one? xml-bindings?. > > Looking for python in the gnome mailing lists xml, xml-bindings and xslt > doesn't show much traffic on the topic (or shows that the search engine > is very broken). > > Alexandre Fayolle > -- From veillard@redhat.com Wed May 29 14:18:58 2002 From: veillard@redhat.com (Daniel Veillard) Date: Wed, 29 May 2002 09:18:58 -0400 Subject: [XML-SIG] where to ask python/libxml2 related questions ? In-Reply-To: <20020529122226.GA6420@orion.logilab.fr>; from Alexandre.Fayolle@logilab.fr on Wed, May 29, 2002 at 02:22:26PM +0200 References: <20020529122226.GA6420@orion.logilab.fr> Message-ID: <20020529091858.C25066@redhat.com> On Wed, May 29, 2002 at 02:22:26PM +0200, Alexandre wrote: > Hello, > > Since this mailing list is not only about PyXML, I was wondering if it > was a good place to ask python-specific questions on libxml2 and > libxslt, or if the gnome project mailing lists are better suited (and > then which one? xml-bindings?. yep, xml-bindings@gnome.org is the most appropriate place. > Looking for python in the gnome mailing lists xml, xml-bindings and xslt > doesn't show much traffic on the topic (or shows that the search engine > is very broken). there isn't much traffic, that's right, mostly requests for enhancements Daniel -- Daniel Veillard | Red Hat Network https://rhn.redhat.com/ veillard@redhat.com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/ http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/ From phthenry@earthlink.net Wed May 29 16:49:38 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Wed, 29 May 2002 11:49:38 -0400 Subject: [XML-SIG] losing cdata tag In-Reply-To: References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> Message-ID: <20020529114937.B6147@localhost.localdomain> On Wed, May 29, 2002 at 09:41:45AM +0200, Martin v. Loewis wrote: > > > What version of PyXML are you using? Can you try 0.7.1? I downloaded the most stable version of PyXML about 3 weeks ago, so I'm thinking an outdated library is not the fault (though of course I could be wrong.) However, I used Juergen's suggestion (thanks Juergen!): >>> from xml.sax import sax2exts >>> p =sax2exts.make_parser() >>> print p So it seems like I'm using expat, and it is likely that I could be using an outdated version(?) (Also, how come when I do $which expat, I get "no expat found...etc?) One last thing occurrs to me. Mandrake (my linux distribution) puts its libraries in a non-standard place. I just updated python at the same exact time I downloaded and installed PyXML. The new version puts the libraries in the standard place. However, I never bothered to remove the old libraries. I wonder if they are being used? Though again, since python is using expat, this wouldn't be a factor. Thanks Paul -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From reagle@w3.org Wed May 29 17:33:06 2002 From: reagle@w3.org (Joseph Reagle) Date: Wed, 29 May 2002 12:33:06 -0400 Subject: [XML-SIG] Re: C14N Performacne Message-ID: <20020529163306.B2F65859F5@aeon.w3.org> On Tuesday 28 May 2002 04:31 pm, Joseph Reagle wrote: > Doing XPath selection and C14N has *terrible* performance with PyXML. For > a 100K xml file, it's not even worth it, I'll walk away from the computer > come back later, and it'll still be working at it. The big problem is the > XPath evaluation. The default nodeset that is canonicalized is to "blow > up" the input document/nodeset akin to a "pattern = '(//. | //@* | > //namespace::*)'" [1] I know this is a very bad (slow) evaluation (this > is where I time-out) so can anyone suggest an optimization/alternative I > can use in its place? If I'm c14n'izing a file (not an xpath subset) the problem is easily remedied as such (don't do the XPath evaluation if you don't need to). diff -r1.4 test_c14n.py 286c286,287 < query = '(//. | //@* | //namespace::*)' --- > #query = '(//. | //@* | //namespace::*)' > query = None 331c332,335 < nodelist = xpath.Evaluate(query, context=context) --- > if query: > nodelist = xpath.Evaluate(query, context=context) > else: > nodelist = None Arbitrary From martin@v.loewis.de Wed May 29 23:44:35 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 30 May 2002 00:44:35 +0200 Subject: [XML-SIG] losing cdata tag In-Reply-To: <20020529114937.B6147@localhost.localdomain> References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> <20020529114937.B6147@localhost.localdomain> Message-ID: Paul Tremblay writes: > >>> from xml.sax import sax2exts > >>> p =sax2exts.make_parser() > >>> print p > > > So it seems like I'm using expat, and it is likely that I could > be using an outdated version(?) (Also, how come when I do $which > expat, I get "no expat found...etc?) Unlikely. Expat ships with PyXML, and PyXML normally uses the included expat. There is not much point in guessing what software configuration might have gone wrong; instead, it is more productive finding out why your installation does not work correctly. As a starting point, locate the copy of expatreader.py that you are using, and edit the function def _reset_lex_handler_prop(self): self._parser.CommentHandler = self._lex_handler_prop.comment self._parser.StartCdataSectionHandler = self._lex_handler_prop.startCDATA self._parser.EndCdataSectionHandler = self._lex_handler_prop.endCDATA to read def _reset_lex_handler_prop(self): print "Resettint the lexical handler", self._lex_handler_prop.startCDATA self._parser.CommentHandler = self._lex_handler_prop.comment self._parser.StartCdataSectionHandler = self._lex_handler_prop.startCDATA self._parser.EndCdataSectionHandler = self._lex_handler_prop.endCDATA Then report whether this prints anything. If it does, report what it prints; if it doesn't, locate def reset(self): print "print ADDED: reset" ... if self._lex_handler_prop: print "print ADDED: reset_lex_handler_prop" self._reset_lex_handler_prop() Regards, Martin From phthenry@earthlink.net Thu May 30 04:39:09 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Wed, 29 May 2002 23:39:09 -0400 Subject: [XML-SIG] losing cdata tag In-Reply-To: References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> <20020529114937.B6147@localhost.localdomain> Message-ID: <20020529233909.D6147@localhost.localdomain> On Thu, May 30, 2002 at 12:44:35AM +0200, Martin v. Loewis wrote: > > There is not much point in guessing what software configuration might > have gone wrong; instead, it is more productive finding out why your > installation does not work correctly. As a starting point, locate the > copy of expatreader.py that you are using, and edit the function > > def _reset_lex_handler_prop(self): > self._parser.CommentHandler = self._lex_handler_prop.comment > self._parser.StartCdataSectionHandler = self._lex_handler_prop.startCDATA > self._parser.EndCdataSectionHandler = self._lex_handler_prop.endCDATA > > to read > > def _reset_lex_handler_prop(self): > print "Resettint the lexical handler", self._lex_handler_prop.startCDATA > self._parser.CommentHandler = self._lex_handler_prop.comment > self._parser.StartCdataSectionHandler = self._lex_handler_prop.startCDATA > self._parser.EndCdataSectionHandler = self._lex_handler_prop.endCDATA I copied your code exactly as you said, and got no result. I then inserted the following block of code: def reset(self): print "print ADDED: reset" if self._namespaces: self._parser = expat.ParserCreate(None, " ", intern = self._interning) self._parser.StartElementHandler = self.start_element_ns self._parser.EndElementHandler = self.end_element_ns if self._lex_handler_prop: print "print ADDED: reset_lex_handler_prop" self._reset_lex_handler_prop() I got this as a result: print ADDED: reset print ADDED: reset Thanks for your patience Paul -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From martin@v.loewis.de Thu May 30 08:11:03 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 30 May 2002 09:11:03 +0200 Subject: [XML-SIG] losing cdata tag In-Reply-To: <20020529233909.D6147@localhost.localdomain> References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> <20020529114937.B6147@localhost.localdomain> <20020529233909.D6147@localhost.localdomain> Message-ID: Paul Tremblay writes: > def reset(self): > print "print ADDED: reset" > > if self._namespaces: > self._parser = expat.ParserCreate(None, " ", intern = self._interning) > self._parser.StartElementHandler = self.start_element_ns > self._parser.EndElementHandler = self.end_element_ns > > if self._lex_handler_prop: > print "print ADDED: reset_lex_handler_prop" > self._reset_lex_handler_prop() > > > I got this as a result: > > print ADDED: reset > print ADDED: reset So it appears that self._lex_handler_prop is false. Can you change the prints to print "print ADDED: reset", repr(self._lex_handler_prop) If that prints None, can you also change your program to read parser.setProperty(handler.property_lexical_handler, saxhandler) print repr(parser._lex_handler_prop) parser.parse(xmlfile) Something very strange is happening here... Regards, Martin From noreply@sourceforge.net Thu May 30 11:29:40 2002 From: noreply@sourceforge.net (noreply@sourceforge.net) Date: Thu, 30 May 2002 03:29:40 -0700 Subject: [XML-SIG] [ pyxml-Bugs-562276 ] xmlproc 0.7.1 reports incorrect version Message-ID: Bugs item #562276, was opened at 2002-05-30 06:29 You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=106473&aid=562276&group_id=6473 Category: xmlproc Group: None Status: Open Resolution: None Priority: 5 Submitted By: Matthew Gruenke (mgruenke) Assigned to: Lars Marius Garshol (larsga) Summary: xmlproc 0.7.1 reports incorrect version Initial Comment: On line 19 of xmlproc.py, in release 0.7.1 it says: version="0.70" When I assume it means to say: version="0.71" BTW, I think it's a mistake to try to treat versions as real numbers. They are similar, especially in notation, but really very different. I prefer to implement versions as a 3-element tuple, which does make compatibility checking a little more cumbersome than a simple numerical comparison. The other alternative would be to have a version_major, version_minor, and version_patch (or version.major, version.minor, and version.patch, if you have a version class), if you prefer something more structured than a tuple. Anyhow, if your versioning semantics follow the traditional UNIX shared-library model, a difference in the major version of a library is usually used to signify an incompatibility with programs written to a previous major version. If this convention is followed, than the simple numeric comparison suggested by treating version IDs as real numbers is actually incorrect. In my python modules (e.g. http://sourceforge.net/projects/xml-extractor), I actually run the .py file through sed, to expand the version numbers, which are maintained in a separate file that gets sourced by my release script (which passes the values to sed). Admittedly, it's arguable whether such trouble to centralize version numbers in a single place is really worthwhile, but it does solve the problem of keeping in synch what version the setup.py script thinks it has, and the version reported by the actual module. ---------------------------------------------------------------------- You can respond by visiting: http://sourceforge.net/tracker/?func=detail&atid=106473&aid=562276&group_id=6473 From phthenry@earthlink.net Thu May 30 18:42:44 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Thu, 30 May 2002 13:42:44 -0400 Subject: [XML-SIG] losing cdata tag In-Reply-To: References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> <20020529114937.B6147@localhost.localdomain> <20020529233909.D6147@localhost.localdomain> Message-ID: <20020530134244.E6147@localhost.localdomain> On Thu, May 30, 2002 at 09:11:03AM +0200, Martin v. Loewis wrote: > > So it appears that self._lex_handler_prop is false. Can you change the > prints to > > print "print ADDED: reset", repr(self._lex_handler_prop) The output when I added the above code is: print ADDED: reset None print ADDED: reset None > > If that prints None, can you also change your program to read > > parser.setProperty(handler.property_lexical_handler, saxhandler) > print repr(parser._lex_handler_prop) > parser.parse(xmlfile) > I added this, but my program wouldn't run: Traceback (most recent call last): File "/home/paul/paultemp/python.temp.py", line 45, in ? parser.setProperty(handler.property_lexical_handler, dhObj) NameError: name 'handler' is not defined If I comment the first line of the above code, I get: None print ADDED: reset None print ADDED: reset None print ADDED: reset None print ADDED: reset None But I don't believe that is telling us anything. Thanks Paul -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************ From akuchlin@mems-exchange.org Thu May 30 20:07:36 2002 From: akuchlin@mems-exchange.org (Andrew Kuchling) Date: Thu, 30 May 2002 15:07:36 -0400 Subject: [XML-SIG] XML HOWTO updated Message-ID: I've updated the XML HOWTO to match the current state of PyXML, updating for SAX2, filling out the DOM section, and adding sections on XPath and xml.marshal. http://pyxml.sourceforge.net/topics/howto/xml-howto.html Please offer comments, bug reports, and suggestions for additional topics that should be covered. --amk From jedp@ilm.com Thu May 30 20:22:54 2002 From: jedp@ilm.com (Jed Parsons) Date: Thu, 30 May 2002 12:22:54 -0700 (PDT) Subject: [XML-SIG] merging xml sources (again) Message-ID: <200205301922.MAA37116@ocean.lucasdigital.com> Here's a variant of a recently-asked question (with thanks again to those who responded): Is it possible to insert elements into the stream being parsed by an xml.sax parser while it's parsing? I would like to be able to merge bits of xml into a document while it's being parsed. Merging is triggered by an element I'm calling 'include-xml' that indicates the location of an external xml document. Presently, I'm using what's essentially an identity transformation with xslt to produce a document derived from multiple sources (all same namespace; no additional transformations necessary), and then parsing that document. Basically, this just smells wrong :-) It's slow, too. Can I roll the transformation phase right into my document handler? Thanks for any advice. Cheers, Jed -- Jed Parsons Industrial Light + Magic (415) 448-2974 grep(do{for(ord){(!$_&&print"$s\n")||(($O+=(($_-1)%6+1)and grep(vec($s,$O++,1)=1,1..int(($_-6*6-1)/6))))}},(split(//, "++,++2-27,280,481=1-7.1++2,800+++2,8310/1+4131+1++2,80\0. What!?"))); From eklein@learninginsights.com Thu May 30 21:21:06 2002 From: eklein@learninginsights.com (Erez Klein) Date: Thu, 30 May 2002 15:21:06 -0500 Subject: [XML-SIG] interpreter problem Message-ID: <20065C33DD1AD611BC4300805FEDABBC0CCA06@mail.li> This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. ------_=_NextPart_001_01C20817.870CFAC0 Content-Type: text/plain; charset="iso-8859-1" I am experiencing a problem with the interpreter when trying to import the xml.sax module. When I run the following 1 line program (saved in a file called xml.py): import xml.sax by launching the interpreter like this: python.exe c:\xml.py I get this error: Traceback (most recent call last): File "c:\xml.py", line 1, in ? import xml.sax File "c:\xml.py", line 1, in ? import xml.sax ImportError: No module named sax At first, I thought it was an environment variable problem, so I printed out sys.path, but it does have c:\python21\lib, which is where the module is installed. Interestingly, if I change the import statement to "import xml" (without sax) it doesn't complain. Also, when I launch the interpreter in interactive mode and try to import xml.sax, I get no errors. I am running python 2.1, and pyxml 0.7.1 on windows 98. Is there anything I installed improperly? I appreciate your assistance. Erez Klein IT Development Manager Learning Insights, Inc ------_=_NextPart_001_01C20817.870CFAC0 Content-Type: text/html; charset="iso-8859-1"
I am experiencing a problem with the interpreter when trying to import the xml.sax module.
 
When I run the following 1 line program (saved in a file called xml.py):
import xml.sax
 
by launching the interpreter like this: python.exe c:\xml.py
 
I get this error:
Traceback (most recent call last):
  File "c:\xml.py", line 1, in ?
    import xml.sax
  File "c:\xml.py", line 1, in ?
    import xml.sax
ImportError: No module named sax
At first, I thought it was an environment variable problem, so I printed out sys.path, but it does have c:\python21\lib, which is where the module is installed.
Interestingly, if I change the import statement to "import xml" (without sax) it doesn't complain. Also, when I launch the interpreter in interactive mode and try to import xml.sax, I get no errors.
 
I am running python 2.1, and pyxml 0.7.1 on windows 98.
 
Is there anything I installed improperly? I appreciate your assistance.
 
Erez Klein
IT Development Manager
Learning Insights, Inc
 
------_=_NextPart_001_01C20817.870CFAC0-- From akuchlin@mems-exchange.org Thu May 30 21:41:51 2002 From: akuchlin@mems-exchange.org (Andrew Kuchling) Date: Thu, 30 May 2002 16:41:51 -0400 Subject: [XML-SIG] interpreter problem In-Reply-To: <20065C33DD1AD611BC4300805FEDABBC0CCA06@mail.li> References: <20065C33DD1AD611BC4300805FEDABBC0CCA06@mail.li> Message-ID: <20020530204151.GA28623@ute.mems-exchange.org> On Thu, May 30, 2002 at 03:21:06PM -0500, Erez Klein wrote: >When I run the following 1 line program (saved in a file called xml.py): >import xml.sax It's importing your 'xml.py' module as the 'xml' module. Try renaming your test file to xml-test.py or something like that. --amk From martin@v.loewis.de Thu May 30 23:07:54 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 31 May 2002 00:07:54 +0200 Subject: [XML-SIG] merging xml sources (again) In-Reply-To: <200205301922.MAA37116@ocean.lucasdigital.com> References: <200205301922.MAA37116@ocean.lucasdigital.com> Message-ID: Jed Parsons writes: > Basically, this just smells wrong :-) It's slow, too. Can I roll the > transformation phase right into my document handler? Certainly, if your document handler can handle that... Regards, Martin From martin@v.loewis.de Thu May 30 23:54:47 2002 From: martin@v.loewis.de (Martin v. Loewis) Date: 31 May 2002 00:54:47 +0200 Subject: [XML-SIG] losing cdata tag In-Reply-To: <20020530134244.E6147@localhost.localdomain> References: <20020525191420.I16955@localhost.localdomain> <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> <20020529114937.B6147@localhost.localdomain> <20020529233909.D6147@localhost.localdomain> <20020530134244.E6147@localhost.localdomain> Message-ID: Paul Tremblay writes: > I added this, but my program wouldn't run: > > Traceback (most recent call last): > File "/home/paul/paultemp/python.temp.py", line 45, in ? > parser.setProperty(handler.property_lexical_handler, dhObj) > NameError: name 'handler' is not defined Now, this is *really* surprising, since, in http://mail.python.org/pipermail/xml-sig/2002-May/007750.html you reported that this very code executes sucessfully (even though not with the desired result). Can you please double-check that you are executing the code that you said you are executing? Regards, Martin From Nicolas.Chauvat@logilab.fr Fri May 31 09:24:49 2002 From: Nicolas.Chauvat@logilab.fr (Nicolas Chauvat) Date: Fri, 31 May 2002 10:24:49 +0200 (CEST) Subject: [XML-SIG] merging xml sources (again) In-Reply-To: <200205301922.MAA37116@ocean.lucasdigital.com> Message-ID: > Here's a variant of a recently-asked question (with thanks again to > those who responded): > > Is it possible to insert elements into the stream being parsed by an > xml.sax parser while it's parsing? I would like to be able to merge > bits of xml into a document while it's being parsed. Merging is > triggered by an element I'm calling 'include-xml' that indicates the > location of an external xml document. Presently, I'm using what's > essentially an identity transformation with xslt to produce a document > derived from multiple sources (all same namespace; no additional > transformations necessary), and then parsing that document. If you are into this, here is a feature I've been wanting to implement (and never got time to). --- Document (doc.xml) --- Other document (otherdoc.xml) Nicolas --- transform (transfo.xslt) ... ... --- Result Would be cool if reading in doc.xml would be equivalent to reading in Nicolas don't you think ? -- Nicolas Chauvat http://www.logilab.com - "Mais où est donc Ornicar ?" - LOGILAB, Paris (France) From phthenry@earthlink.net Fri May 31 20:20:47 2002 From: phthenry@earthlink.net (Paul Tremblay) Date: Fri, 31 May 2002 15:20:47 -0400 Subject: [XML-SIG] losing cdata tag In-Reply-To: References: <20020527001456.K16955@localhost.localdomain> <20020529002807.A6147@localhost.localdomain> <20020529114937.B6147@localhost.localdomain> <20020529233909.D6147@localhost.localdomain> <20020530134244.E6147@localhost.localdomain> Message-ID: <20020531152046.A29240@localhost.localdomain> > > Now, this is *really* surprising, since, in > > http://mail.python.org/pipermail/xml-sig/2002-May/007750.html > > you reported that this very code executes sucessfully (even though not > with the desired result). > > Can you please double-check that you are executing the code that you > said you are executing? Sorry if I didn't make this clear from the start. There were two sets of code. The code you mentioned above I got off python cookbook. I have just tried this code, and hot this result: <some text> So the CDATA is escaped! (Though it would be nice to have the characters unescaped but enclosed in CDATA tags; that way it is easier to go back and change things on your xml doc before final output.) The other set of code apparently uses a different library. I had been using this code for my parsing, and saw that it wasn't escaping the CDATA. This code must somehow be broken. I am a big unfamiliar with the "good" code. I suppose it follows all of the SAX protocols. However, I notice that it is very, very slow. It took around 15 seconds just to parse the above data! Any thoughts as to why the "bad" code is bad would help me. Thanks Paul ############################## # This code does not escape the CDATA. # It is the code I have been working with # all along #!/usr/bin/python from xml.sax import saxutils from xml.sax import make_parser from xml.sax.handler import feature_namespaces class CopyTree(saxutils.DefaultHandler): def __init__(self): self.character = "" def startElement(self, name, attrs): print "<" + name, for theKey in attrs.keys(): print " " + theKey + "=\"" + attrs[theKey] + "\"", print ">", def characters(self, ch): self.character = self.character + ch def endElement(self, name): print self.character + "", self.character="" parser = make_parser() #Tell the parser we are not interested in XML namespaces parser.setFeature(feature_namespaces, 0) # Create the handler dhObj = CopyTree() # Tell the parser to use our handler parser.setContentHandler(dhObj) # Parse the input file = "/home/paul/paultemp/test.xml" parser.parse(file) -- ************************ *Paul Tremblay * *phthenry@earthlink.net* ************************