Skip to main content

XUpdate Generator for ERP5

Project description


This is a XUpdate Generator to compare any XML document.

See <> for information on XUpdate.


python setup install


python setup test


Once you have installed erp5diff, you can use “erp5diff” in a shell:

erp5diff old.xml new.xml

Or in a python console:

from ERP5Diff import ERP5Diff
erp5diff = ERP5Diff()
old_xml = """
new_xml = """
""", new_xml)
<xupdate:modifications xmlns:xupdate="" version="1.0">
  <xupdate:remove select="/ul/li[5]"/>
  <xupdate:remove select="/ul/li[6]"/>
  <xupdate:append child="first()">
    <xupdate:element name="li">5</xupdate:element>
    <xupdate:element name="li">6</xupdate:element>
</xupdate:modifications> (unreleased)

  • Bug fix
  • Add support of deletion/addition for tailed text nodes (2011/08/08)

  • Fix rst syntax
  • Improve Handling of mixed content (2011/08/05)

  • Tail text nodes was not detected (…<node/>blablabla…)
  • fix import issue of main() function (2011/01/25)

  • add long_description, improve README
  • add missing namespace declaration of egg (2011/01/25)

  • [fix] installation of egg (2011/01/25)

  • [Fix] position starts to 1 [Nicolas Delaby]

version 0.8.1 Nicolas Delaby

Bug Fix

  • Some nodes stay orphans if they are replaced by another one and followed by a modification (test 30)
  • Exclude comments or processing instruction as sibling node

version 0.8 Nicolas Delaby


  • Include ‘gid’ in attributes allowed to build an xpath expression with a unique identifier.
  • Use better algorithm to compare two xml nodes (faster).

Bug Fix

  • In node comparaison discard text nodes with only withe-spaces.
  • Fix relative calculation of position for xupdate:insert-before nodes
  • Add namespace declaration on xupdate nodes which are using prefix in builded xpath expression.

version 0.7 Nicolas Delaby

Bug fix

  • Nodes whose position change were discarded.
  • Declare namespaces used in xpath expression on xupdate output.

version 0.6 Nicolas Delaby

Bug Fix

  • Fix generated xpath expression, the root element was missing.

version 0.5 Nicolas Delaby


  • Add support of namespaces
  • Support xupdate:insert-after

version 0.4 Nicolas Delaby


  • Change output of xupdate:append by adding Implied attribute child

version 0.3 Nicolas Delaby

Bug Fix

  • Append position in xpath expression when value of id attribute is not unique regarding is sibling

version 0.2 Nicolas Delaby

Bug Fix

  • Position in xpath starts from 1

version 0.1 Tatuya Kamada


  • ERP5diff implemented with ElemenTree (lxml)

version 0 Yoshinori Okuji

  • initial ERP5diff with DOM API (minidom)

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
erp5diff- (16.6 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page