From: Alex R. <sh...@al...> - 2004-08-11 21:50:32
|
Matthieu, On 08/11/2004 04:35:10 PM, Tieum wrote: >=20 > My relationship script worked pretty well. I did some more modifications = and > nothing does not work any more .... Here's the patch that takes care of the error. The "degree" was mistakenly out of the quotation marks. Do not apply this patch, since the accented letter is iso-8859-1 instead of=20 unicode in this email. Just move the quotation marks in=20 your source by hand :-) =3D=3D=3D=3D=3D=3D=3D=3D --- rel_fr.py 2004-08-11 16:36:57.000000000 -0500 +++ rel_fr.py.new 2004-08-11 16:40:28.000000000 -0500 @@ -77,10 +77,10 @@ apply_filter(family.getMother(),index+1,plist,pmap) =20 def get_male_cousin(level): - return "cousin au %s" degr=E9% (_level_name[level]) + return "cousin au %s degr=E9" % (_level_name[level]) =20 def get_female_cousin(level): - return "cousine au %s" degr=E9% (_level_name[level]) + return "cousine au %s degr=E9" % (_level_name[level]) =20 def get_parents(level): if level>len(_parents_level)-1: =3D=3D=3D=3D=3D=3D=3D=3D > In /usr/local/share/plugins, I get rel_fr.py but not rel_fr.pyo. In GRAMP= S the > relationship are in English. This is because the file could not be parsed due to the above error. With the corrected plugin I get the proper pyo file.=20 Please commit it :-) Alex P.S. With the plugins, the syntax errors will lead to not loading the plugin. In your case it resulted in falling back to English=20 relations. To check the status of plugins, use Help->Show Plugin status. The window will show all the tracebacks from the plugins that failed to load. --=20 Alexander Roitman http://ebner.neuroscience.umn.edu/people/alex.html Dept. of Neuroscience, Lions Research Building 2001 6th Street SE, Minneapolis, MN 55455 Tel (612) 625-7566 FAX (612) 626-9201 |