simple xml pickle

Michael Stenner mstenner at phy.duke.edu
Wed Sep 4 13:29:51 EDT 2002


On Wed, Sep 04, 2002 at 12:13:04PM -0400, David Mertz, Ph.D. wrote:
> Michael Stenner <mstenner at phy.duke.edu> wrote previously:
> |  the "old" xml_pickle.py, which appears to not work at all with
> |  python2.2, but is otherwise appealing....
> |  the "new" xml.pickle as it appears in the Gnosis tools.  This is
> |  less appealing because it's very large and distributed over several
> |  files...
> 
> I think there are some good reasons why the "new" gnosis.xml.pickle is
> organized into a package namespace.  And there are some new capabilities
> and modularity that go along with that.

You're quite right.  I should have said "less appealing as a solution
in my current task" or something similarly qualified.

> However, the "old" xml_pickle (use the latest such one, labelled 0.51)
> can be fixed up for Python 2.2 by adjusting two uses of dir().  That
> built-in function changed meaning in Python 2.2--or at least it changed
> behavior.  Just replace occurrences of 'dir(obj)' with
> 'obj.__dict__.keys()', and I'm pretty sure all will be well.

That's the version that I was playing with last night.  I'll take
another look at it.  I think there were some api changes in the DOM
stuff too, though.  I'm not sure of the specifics.

The xml marshalling does almost exactly what I want, and the
modifications to make it "standalone" for Python 2.2 were very easy
(patch forthcoming) so I may just stick with that.  Nonetheless, I'll
look at xml_pickle again and see what I can see.

> Yours, David (the xml_pickle guy)...

Yeah, I remembered the name... when you a google search on "xml
pickle" you see "David Mertz, Ph.D" popping up everywhere :)

					-Michael
-- 
  Michael Stenner                       Office Phone: 919-660-2513
  Duke University, Dept. of Physics       mstenner at phy.duke.edu
  Box 90305, Durham N.C. 27708-0305




More information about the Python-list mailing list