Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Problem with module 'evolution' after moving system

Reply
Thread Tools

Problem with module 'evolution' after moving system

 
 
tinnews@isbd.co.uk
Guest
Posts: n/a
 
      11-24-2010
I have just moved my desktop system (running xubuntu 10.04) to new
hardware. I have an almost trivial python program that uses the
evolution module which no longer works and I'm having trouble working
out why.

The program is:-

#!/usr/bin/python
#
#
#
#
import evolution
import sys


addrs = evolution.ebook.open_addressbook('default')

result = addrs.search(sys.argv[1])

print "Found ", len(result), " matches"
if len(result) > 0:
for nm in result:
print nm.get_property('email-1'), "\t", nm.get_property('full-name')
exit(0)
else:
exit(1)


When I run it I get the error:-

chris$ getEvoAddress.py zelma
Traceback (most recent call last):
File "/home/chris/bin/getEvoAddress.py", line 10, in <module>
addrs = evolution.ebook.open_addressbook('default')
AttributeError: 'NoneType' object has no attribute 'open_addressbook'

Using 'help' reveals basic information for evolution but reports "no
documentation ...." for evolution.ebook. On the old system (exactly
the same version of python, same OS, same everything just about)
"help(evolution.ebook)" shows the expected documentation.

So, what's wrong, is some python module missing that the evolution
module needs? (It's quite likely that there are far more modules
installed on the old system than the new one)

--
Chris Green
 
Reply With Quote
 
 
 
 
tinnews@isbd.co.uk
Guest
Posts: n/a
 
      11-24-2010
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
[snip]

> Using 'help' reveals basic information for evolution but reports "no
> documentation ...." for evolution.ebook. On the old system (exactly
> the same version of python, same OS, same everything just about)
> "help(evolution.ebook)" shows the expected documentation.
>
> So, what's wrong, is some python module missing that the evolution
> module needs? (It's quite likely that there are far more modules
> installed on the old system than the new one)
>

A bit further trying to see what's wrong it seems that Python is
failing to load .so libraries for some reason on the system where it
doesn't work.

The initialisation code in the evolution module has:-

import ebook

So, obviously this works on the old system but not on the new system.
The ebook.so file is present on both systems in exactly the same place.

--
Chris Green
 
Reply With Quote
 
 
 
 
tinnews@isbd.co.uk
Guest
Posts: n/a
 
      11-24-2010
(E-Mail Removed) wrote:
> (E-Mail Removed) wrote:
> [snip]
>
> > Using 'help' reveals basic information for evolution but reports "no
> > documentation ...." for evolution.ebook. On the old system (exactly
> > the same version of python, same OS, same everything just about)
> > "help(evolution.ebook)" shows the expected documentation.
> >
> > So, what's wrong, is some python module missing that the evolution
> > module needs? (It's quite likely that there are far more modules
> > installed on the old system than the new one)
> >

> A bit further trying to see what's wrong it seems that Python is
> failing to load .so libraries for some reason on the system where it
> doesn't work.
>
> The initialisation code in the evolution module has:-
>
> import ebook
>
> So, obviously this works on the old system but not on the new system.
> The ebook.so file is present on both systems in exactly the same place.
>

..... and I've finally found what was missing, I tried:-

import evolution.ebook

and it told me that 'import bonobo' was failing. A little searching
and I found that python-gnome2 (which includes bonobo) was installed
on the old system but not on the new one. Installing it has fixed my
problem.

--
Chris Green
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Moving Guide Moving Companies Movers Storage linkswanted ASP .Net 0 01-23-2008 01:08 AM
Free Moving Estimate, Local Movers, Long Distance Moving, PackingSupplies, Storage Rental, Home Moving, Apartment Moving, Office Moving,Commercial Moving linkswanted ASP .Net 0 01-06-2008 04:45 AM
Moving to California Moving to L.A linkswanted Digital Photography 3 01-05-2008 04:22 PM
movers los angeles moving storage services movers in L.A companymoving companies moving in calfornia los angeles linkswanted HTML 0 12-21-2007 10:55 PM



Advertisments