logger head configuration failed

Asked by Vijaya Kumar

Hi,

I have branched loggerhead into my bzr plugins

>cd /usr/lib/python2.6/site-packages/bzrlib/plugins
bzr branch http://bazaar.launchpad.net/~loggerhead-team/loggerhead/trunk-rich loggerhead

Then i tried
./serve-branches

Error:
Traceback (most-recent call last):
File "./serve-branches", line 23, in?
File "../../..bzrlib/plugins/loggerhead/loggerhead/main.py", line 24, in ?
from bzrlib.plugin import load_plugins
ImportError: No module named bzrlib.plugin

Also i tried
bzr serve --http

Error:
No module named pkg_resources
bzr: ERROR: No module named paste.httpexceptions
you may need to install this Python library separately

I have verified for all libraries and everything is in place.

Question information

Language:
English Edit question
Status:
Solved
For:
loggerhead Edit question
Assignee:
No assignee Edit question
Solved by:
Vijaya Kumar
Solved:
Last query:
Last reply:
Revision history for this message
John A Meinel (jameinel) said :
#1

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 1/18/2012 10:31 AM, Vijaya Kumar wrote:
> New question #185078 on loggerhead:
> https://answers.launchpad.net/loggerhead/+question/185078
>
> Hi,
>
> I have branched loggerhead into my bzr plugins
>
>> cd /usr/lib/python2.6/site-packages/bzrlib/plugins
> bzr branch
> http://bazaar.launchpad.net/~loggerhead-team/loggerhead/trunk-rich
> loggerhead
>
> Then i tried ./serve-branches

I generally wouldn't use serve-branches, but if you do, you need to
make sure that "bzrlib" is in your search path.

Instead, you can do "bzr serve --http" which should work better for you.

John
=:->

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEUEARECAAYFAk8WmEMACgkQJdeBCYSNAAN7zACgyd/0zOWGtL7sRvu2lzi7INRY
3qAAliW+PIT+pVmczjsWEOzp2+TUI6I=
=QwxB
-----END PGP SIGNATURE-----

Revision history for this message
Jelmer Vernooij (jelmer) said :
#2

On 01/18/2012 10:31 AM, Vijaya Kumar wrote:
> New question #185078 on loggerhead:
> https://answers.launchpad.net/loggerhead/+question/185078
>
> Hi,
>
> I have branched loggerhead into my bzr plugins
>
>> cd /usr/lib/python2.6/site-packages/bzrlib/plugins
> bzr branch http://bazaar.launchpad.net/~loggerhead-team/loggerhead/trunk-rich loggerhead
>
> Then i tried
> ./serve-branches
>
> Error:
> Traceback (most-recent call last):
> File "./serve-branches", line 23, in?
> File "../../..bzrlib/plugins/loggerhead/loggerhead/main.py", line 24, in ?
> from bzrlib.plugin import load_plugins
> ImportError: No module named bzrlib.plugin
>
> Also i tried
> bzr serve --http
>
> Error:
> No module named pkg_resources
> bzr: ERROR: No module named paste.httpexceptions
> you may need to install this Python library separately
>
> I have verified for all libraries and everything is in place.
Do you have python-paste and python-pkg-resources installed?

Cheers,

Jelmer

Revision history for this message
Vijaya Kumar (vijayakumar-cm) said :
#3

Seems the issue becoz of python-paste

>>># bzr serve --http
Paste>=1.6
bzr: ERROR: No module named paste.httpexceptions
You may need to install this Python library separately.

But the packages has already in.
>>>#
Package python-paste-1.7.4-1.el5.noarch already installed and latest version

Revision history for this message
Vijaya Kumar (vijayakumar-cm) said :
#4

any idea on this..

[root@P690-6YWJR1S loggerhead]# sudo python26 setup.py install
Traceback (most recent call last):
  File "setup.py", line 23, in <module>
    import loggerhead
  File "/usr/lib/python2.6/site-packages/bzrlib/plugins/loggerhead/loggerhead/__init__.py", line 28, in <module>
    pkg_resources.get_distribution('Paste>=1.6')
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 292, in get_distribution
    if isinstance(dist,Requirement): dist = get_provider(dist)
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 176, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 648, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 546, in resolve
    raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: Paste>=1.6

============ Installed: pkg_resources ========================
python26-distribute.noarch : Easily build and distribute Python packages
python26-numpy-tests.i386 : Tests for Numpy distribute

Revision history for this message
Martin Pool (mbp) said :
#5

Are you sure those packages are installed in a directory where 'sudo
python26' will see them? How did you install them?

Revision history for this message
Vijaya Kumar (vijayakumar-cm) said :
#6

I installed using yum command..

Actually our server has 2 python versions installed (python2.4 and python2.6), could this be the cause for package missing?

Revision history for this message
Vijaya Kumar (vijayakumar-cm) said :
#7

i have removed python 2.4 from server and i copied the python2.4/site-packages/paste to new python2.6/site-packages/paste
Still the same error...

seems the plugin load successfully but now working..

>bzr plugins
...
...
loggerhead 1.18.1
  Loggerhead web viewer for Bazaar branches.
....

Revision history for this message
Vijaya Kumar (vijayakumar-cm) said :
#8

Any idea from this...

/usr/lib/python2.6/site-packages/bzrlib/plugins/loggerhead

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[root@P690-6YWJR1S loggerhead]# bzr serve --http
bzr: ERROR: No module named paste.httpexceptions
You may need to install this Python library separately.

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
[root@P690-6YWJR1S loggerhead]# ./serve-branches
Traceback (most recent call last):
  File "./serve-branches", line 23, in <module>
    from loggerhead.main import main
  File "/usr/lib/python2.6/site-packages/bzrlib/plugins/loggerhead/loggerhead/__init__.py", line 28, in <module>
    pkg_resources.get_distribution('Paste>=1.6')
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 292, in get_distribution
    if isinstance(dist,Requirement): dist = get_provider(dist)
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 176, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 648, in require needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 546, in resolve raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: Paste>=1.6
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

[root@P690-6YWJR1S loggerhead]# sudo python26 setup.py install
Traceback (most recent call last):
  File "setup.py", line 23, in <module>
    import loggerhead
  File "/usr/lib/python2.6/site-packages/bzrlib/plugins/loggerhead/loggerhead/__init__.py", line 28, in <module>
    pkg_resources.get_distribution('Paste>=1.6')
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 292, in get_distribution
    if isinstance(dist,Requirement): dist = get_provider(dist)
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 176, in get_provider
    return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 648, in require needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python2.6/site-packages/pkg_resources.py", line 546, in resolve raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: Paste>=1.6
[root@P690-6YWJR1S loggerhead]#
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

Revision history for this message
Vijaya Kumar (vijayakumar-cm) said :
#9

finally i'm able to bring up the loggerhead..issue is with the paste(python lib) installation.. i reinstalled all using "sudo python26 "

anyhow its working with localhost but not with TCP..

Revision history for this message
Martin Pool (mbp) said :
#10

On 19 January 2012 21:55, Vijaya Kumar
<email address hidden> wrote:
> anyhow its working with localhost but not with TCP..

What specifically is going wrong?

nb you should not start the server as root (ie through sudo).

--
Martin