Using cElementTree and elementtree.ElementInclude

Discussion in 'Python' started by Mark, Oct 20, 2006.

  1. Mark

    Mark Guest

    I have an elementtree created with cElementTree. I then use
    ElementInclude to resolve some xinclude elements. But then I want to
    move those included elements to be children of the root

    root.append(included_child)

    but I get an error message

    TypeError: 'append() argument 1 must be Element, not instance'


    The type of included_child is 'instance'. The type of the cElementTree
    children is 'Element'. How do I resolve this conflict? I am using
    cElementTree version 1.0.3 and elementtree version 1.2.6 and python
    version 2.3.4. Will later versions correct the problem?

    Thanks,
    Mark
     
    Mark, Oct 20, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark E. Smith
    Replies:
    0
    Views:
    268
    Mark E. Smith
    Oct 23, 2006
  2. Mark
    Replies:
    0
    Views:
    315
  3. Michael Becker
    Replies:
    1
    Views:
    268
    Stefan Behnel
    Mar 23, 2008
  4. Kee Nethery
    Replies:
    12
    Views:
    2,197
    Stefan Behnel
    Jun 27, 2009
  5. Ben Temperton

    When to clear elements using cElementTree

    Ben Temperton, Oct 19, 2012, in forum: Python
    Replies:
    1
    Views:
    194
    Ben Temperton
    Oct 19, 2012
Loading...

Share This Page