On Mon, 28 Sep 2009, David Douard wrote:
On Saturday 26 September 2009 21:34:01 Faheem Mitha wrote:
Hi,
I downloaded the source from
http://hg.logilab.org/hgview
and compiled a Debian package. When trying to bring up hgview, I got an
error about pyrcc4. apt-file informed me that this was in pyqt4-dev-tools.
On installation the error went away and hgview worked, and after removing
pyqt4-dev-tools it still worked, so I'm guessing it did some one-time
thing.
Yes it does. There is a .qrc file holding resources (icons) that is
automatically "compiled" into a python module using pyrcc4 if the python
module is not found or if the .qrc file is newer than the .qrc file (this is
done in hgviewlib/qt4/__init__.py ).
The errors you encountered may be related to the way the deb package in
testing has been built; it probably lacks the python module generated from
the qrc file. I'll discuss with Alexandre this point ASAP.
Hi David,
Just a followup on my earlier post. I tried on a different system, but
can't get it to work here. Transcript follows, on Debian lenny.
fah...@avicenna:~/snpdb$ hgview
pyrcc4: File does not exist
'/usr/lib/pymodules/python2.5/hgviewlib/qt4/hgqv.qrc'
ERROR: Cannot convert the resource file '%s' into a python module.
Please check the PyQt 'pyrcc4' tool is installed, or do it by hand running:
pyrcc4 /usr/lib/pymodules/python2.5/hgviewlib/qt4/hgqv.qrc -o
/usr/lib/pymodules/python2.5/hgviewlib/qt4/hgqv_rc.py
Traceback (most recent call last):
File "/usr/bin/hgview", line 24, in <module>
from hgviewlib.qt4.hgrepoviewer import main
File "/usr/lib/pymodules/python2.5/hgviewlib/qt4/__init__.py", line 43, in
<module>
import hgqv_rc
ImportError: No module named hgqv_rc
fah...@avicenna:~/snpdb$ dlocate pyrcc4
pyqt4-dev-tools: /usr/bin/pyrcc4
pyqt4-dev-tools: /usr/share/man/man1/pyrcc4.1.gz
fah...@avicenna:~/snpdb$ sudo pyrcc4
/usr/lib/pymodules/python2.5/hgviewlib/qt4/hgqv.qrc -o
/usr/lib/pymodules/python2.5/hgviewlib/qt4/hgqv_rc.py
[sudo] password for faheem:
pyrcc4: File does not exist
'/usr/lib/pymodules/python2.5/hgviewlib/qt4/hgqv.qrc'
fah...@avicenna:~/snpdb$ dlocate hgqv.qrc
fah...@avicenna:~/snpdb$ dpkg -S hgqv.qrc
dpkg: *hgqv.qrc* not found.
I'm not sure how I persuaded it to work the last time. I've got the
impression that, weirdly, I got pyrcc4 to work by removing the
pyqt4-dev-tools package, but I tried it just now, and nothing happens, and
I don't have a transcript of my previous session. Any suggestions about
getting this to work?
Regards, Faheem.
_______________________________________________
Python-Projects mailing list
Python-Projects@lists.logilab.org
http://lists.logilab.org/mailman/listinfo/python-projects