P4DTI issue job000315

TitleUpgrading P4DTI may make Bugzilla integration fail
Statusclosed
Priorityessential
Assigned userNick Barnes
OrganizationRavenbrook
DescriptionA user upgraded the Bugzilla integration from P4DTI release 1.0.5 to P4DTI release 1.1.1 and the new P4DTI failed to start, with the following message:

% python run.py
Traceback (innermost last):
  File "run.py", line 19, in ?
    from init import r
  File "init.py", line 90, in ?
    raise error, catalog.msg(1000, config.dt_name)
P4DTI Initialization error: (P4DTI-10004) The defect tracker 'Bugzilla' is not supported.
AnalysisThis error indicates that the P4DTI failed to import either the configure_bugzilla module or the dt_bugzilla module.
It is possible that the timestamps on the byte-compiled Python files (*.pyc) may be confusing the Python interpreter. A new P4DTI release should not be installed over the top of an old P4DTI release. We need to clarify this in the readme (this is not currently stated in the case of a .tar.gz installation).
Given that this is the same error message as for a faulty MySQLdb installation (job000336), there needs to be a way to distinguish between the two cases. If a user has previously run the P4DTI successfully, they are probably seeing this issue rather than job000336. The way to test it more directly is to try importing the configuration and defect tracker modules directly from a Python prompt. Like this:

$ python
Python 1.5.2 (#1, Feb 1 2000, 16:32:16) [GCC egcs-2.91.66 19990314/Linux (egcs- on linux-i386
Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam
>>> import configure_bugzilla
>>> import dt_bugzilla
>>>
$

If the user is seeing this error message (P4DTI-10004), then one of these two commands should fail with a more specific error message.

GDR 2001-06-20: This is Perforce's job 5896.
GDR 2001-07-14: This is mostly fixed by (a) better error message when an import fails; and (b) the new release build procedure, which makes a tarball that unpacks into a directory that contains the release number. So overwriting won't happen when the installation comes from a tarball. And if they use the RPM, we advise uninstallation using rpm -e p4dti before installing. Does that work? We must check this.
How foundcustomer
Evidence<URL: http://info.ravenbrook.com/mail/2001/05/10/19-15-13/0.txt>
Observed in1.1.1
Introduced in1.1.0
Created byNick Barnes
Created on2001-05-14 15:00:04
Last modified byGareth Rees
Last modified on2001-12-10 19:42:50
History2001-05-10 NB Created.
2001-06-20 GDR Added reference to job at Perforce.
2001-07-14 GDR Added analysis.

Fixes

Change Effect Date User Description
14136 closed 2001-07-14 22:22:02 Gareth Rees Removed try/except around imports; this was obscuring other import errors.
14097 open 2001-07-13 16:30:52 Gareth Rees Automated much of the build procedure.