tag 427829 +help
thanks

  Hi,

  I do not see yet how this bug can be correctly handle. I will explain
it more in detail for non-debian people. If anyone has an idea...

  mercurial read all files in /etc/mercurial/hgrc.d
This allows other packages such as 'qct' to install here a configuration
file so that mercurial will read this extension when installed.

/etc/mercurial/hgrc.d/qct.rc is a debian conffile. That is :
if the admin modifies it (so that qct is not system-wide enabled by
default for example) it will not be overwritten on upgrade (the admin
will have to choose between keeping the old version, getting the new
one, watch the differences...)

When a debian user wants to remove a package, he can 'remove' it or
'purge' it. The difference is about the conffiles: when removing the
package, conffiles are let on the system (so that the admin keeps its
modifications if any (if he want to reinstall the package later for
example)). When purging, conffiles are also removed.

  The problem occurs when qct package is removed but not purged.
In this case, the conffile keep here. So mercurial try to load
qct but cannot because the extension is not here anymore.
  I cannot remove /etc/mercurial/hgrc.d/qct.rc on 'remove' operation
because this will go against debian policy.


  One solution I see would be to extend the syntax of extension loading
in mercurial so that it would be possible to try to load the extension
if present but not to fail if the extension is not present.
  Note that this cannot be the default: if a user requires a extension,
it is better to fail immediately if the extension is not here.

  Another solution would be that the error message from mercurial tells
the user about the file that request this extension. In this case, I
can add a comment in this file (/etc/mercurial/hgrc.d/qct.rc) to explain
what to do (disabling the extension or purging the package)


  So, if you have any comment/idea, that would be great.

  Best regards,
    Vincent

John Goerzen wrote:
> Package: qct
> Severity: important
> 
> Removing this package causes all hg commands to spew:
> 
> *** failed to import extension hgext.qct: No module named qct
> 
> This appears to be due to the qct config file /etc/mercurial/hgrc.d/qct.rc
> 
> this is an unmodified file.
> 
> purging qct fixes the problem
> 
> -- System Information:
> Debian Release: lenny/sid
>   APT prefers unstable
>   APT policy: (500, 'unstable'), (99, 'experimental')
> Architecture: i386 (i686)
> 
> Kernel: Linux 2.6.18-4-k7 (SMP w/2 CPU cores)
> Locale: LANG=C, LC_CTYPE=en_US (charmap=ISO-8859-1)
> Shell: /bin/sh linked to /bin/bash
> 
> Versions of packages qct depends on:
> ii  cvs                         1:1.12.13-8  Concurrent Versions System
> ii  mercurial                   0.9.3-2      Scalable distributed version 
> contr
> ii  python                      2.4.4-6      An interactive high-level 
> object-o
> pn  python-qt4                  <none>       (no description available)
> ii  python-support              0.6.4        automated rebuilding support for 
> p
> ii  subversion                  1.4.2dfsg1-2 Advanced version control system
> 
> qct recommends no packages.
> 



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to