Package: pwman3
Version: 0.0.6-1
Severity: grave
Tags: patch

--- Please enter the report below this line. ---
After upgrading python to 2.5 pwman3 refuses to start, with the
following error:

$ pwman3
Traceback (most recent call last):
  File "/usr/bin/pwman3", line 22, in <module>
    from pwman.ui.cli import PwmanCli
File "/var/lib/python-support/python2.5/pwman/ui/cli.py", line 21, in <module>
    import pwman.exchange.importer as importer
File "/var/lib/python-support/python2.5/pwman/exchange/importer.py", line 20, in <module>
    import cElementTree as ET
ImportError: No module named cElementTree

I found two solutions:

1. Use explicitely python2.4

2. Replace all occurences of cElementTree with xml.etree.cElementTree
   and drop the dependency on python-celementtree (see attached patch)

--- System information. ---
Architecture: i386
Kernel:       Linux 2.6.24-1-686

Debian Release: lenny/sid
  500 unstable        ftp.fr.debian.org
  450 experimental    ftp.fr.debian.org

--- Package information. ---
Depends                  (Version) | Installed
==================================-+-===========
python                    (>= 2.3) | 2.5.2-1
python-support            (>= 0.2) | 0.7.7
python-pysqlite2                   | 2.4.1-1
python-celementtree                | 1.0.5-10
python-crypto                      | 2.0.1+dfsg1-2.1

diff -ru pwman3-0.0.6/debian/control pwman3-0.0.6.new/debian/control
--- pwman3-0.0.6/debian/control	2008-04-30 12:50:52.000000000 +0200
+++ pwman3-0.0.6.new/debian/control	2008-04-30 13:08:08.000000000 +0200
@@ -7,7 +7,7 @@
 
 Package: pwman3
 Architecture: all
-Depends: ${python:Depends}, python-pysqlite2, python-celementtree, python-crypto
+Depends: ${python:Depends}, python-pysqlite2, python-crypto
 Description: console password managment application
  Pwman3 aims to provide a simple but powerful command line interface for
  password managment. It allows to store your password in a sqlite database
diff -ru pwman3-0.0.6/pwman/exchange/exporter.py pwman3-0.0.6.new/pwman/exchange/exporter.py
--- pwman3-0.0.6/pwman/exchange/exporter.py	2007-02-04 19:44:43.000000000 +0100
+++ pwman3-0.0.6.new/pwman/exchange/exporter.py	2008-04-30 13:04:17.000000000 +0200
@@ -17,7 +17,7 @@
 # Copyright (C) 2006 Ivan Kelly <[EMAIL PROTECTED]>
 #============================================================================
 
-from cElementTree import Element, SubElement, dump, ElementTree
+from xml.etree.cElementTree import Element, SubElement, dump, ElementTree
 from pwman.data.nodes import Node
 from pwman.data.tags import Tag
 
diff -ru pwman3-0.0.6/pwman/exchange/importer.py pwman3-0.0.6.new/pwman/exchange/importer.py
--- pwman3-0.0.6/pwman/exchange/importer.py	2007-02-04 19:44:43.000000000 +0100
+++ pwman3-0.0.6.new/pwman/exchange/importer.py	2008-04-30 13:04:04.000000000 +0200
@@ -17,7 +17,7 @@
 # Copyright (C) 2006 Ivan Kelly <[EMAIL PROTECTED]>
 #============================================================================
 
-import cElementTree as ET
+import xml.etree.cElementTree as ET
 from pwman.data.nodes import Node
 from pwman.data.tags import Tag
 

Reply via email to