Peter,

It seems we fixed the ui manager code for you in python 2.7.
So, this error you have with 3.2 also. This is strange, as StringIO of 3.2 should be the cStringIO of 2.7 ...

Benny


2012/11/23 Benny Malengier <benny.malengier@gmail.com>
svn up,

should be fixed rev 20698. Although cStringIo should be like StringIo, it does not seem to be the case in reality.

Concerning your interface  not being drawn correctly, that is harder to fix. Probably problems in the Gtk lib. Did somebody else not have that, and fix it?
I do see you have for cairo a .0 version.

I have no problems using older libs:


Gramps Settings:
----------------
 python    : 2.7.3
 gramps    : 4.0.0
 gtk++     : 3.6.1
 gobject   : 3.3.2
 Not using bsddb3
 bsddb     : 5.1.2
 bsddb.db  : (5, 1, 25)
 cairo     : 1.8.8
 osmgpsmap : not found
 pyexiv2   : 0.3.2
 o.s.      : Linux
 kernel    : 3.2.0-33-generic

Environment settings:
---------------------
 LANG      : sv
 LANGUAGE  : sv

 GRAMPSI18N: not set
 GRAMPSHOME: not set
 GRAMPSDIR : not set
 PYTHONPATH:
    /home/benny/gramps/trunk
    /usr/local/lib/python2.7/dist-packages/scikits.odes-1.0.0-py2.7-linux-x86_64.egg
    /usr/local/lib/python2.7/dist-packages/FiPy-3.0_dev5303-py2.7.egg
    /usr/lib/python2.7/dist-packages/pysparse-1.2_dev224-py2.7-linux-x86_64.egg
    /usr/lib/python2.7/dist-packages/gnuplot_py-1.8_-py2.7.egg
    /usr/lib/python2.7/dist-packages/FiPy-2.2_dev4804-py2.7.egg
    /usr/local/lib/python2.7/site-packages
    /usr/lib/python2.7
    /usr/lib/python2.7/plat-linux2
    /usr/lib/python2.7/lib-tk
    /usr/lib/python2.7/lib-old
    /usr/lib/python2.7/lib-dynload
    /usr/local/lib/python2.7/dist-packages
    /usr/lib/python2.7/dist-packages
    /usr/lib/python2.7/dist-packages/PIL
    /usr/lib/pymodules/python2.7/gtk-2.0
    /usr/lib/python2.7/dist-packages/gtk-2.0
    /usr/lib/pymodules/python2.7
    /usr/lib/python2.7/dist-packages/wx-2.6-gtk2-unicode

Non-python dependencies:
------------------------
 Graphviz  : dot - graphviz version 2.26.3 (20100126.1600)
 Ghostscr. : 9.05


System PATH env variable:
-------------------------
     /usr/local/sbin
     /usr/local/bin
     /usr/sbin
     /usr/bin
     /sbin
     /bin
     /usr/games


Note that on your distribution python.bsddb is an old version, while the core bsddb is newer than mine. That is a strange choice of your distro.

Benny



2012/11/23 Jérôme <romjerome@yahoo.fr>
> I suppose it is related to an other localedir (see tests on gui/trans.py).

Sorry, under 'gen/utils/trans.py'


Le 23/11/2012 12:24, Jérôme a écrit :
> See post on [Gramps-devel] mailing list:
>       "Trunk and LANG" (2012-11-13).
>
> I suppose it is related to an other localedir (see tests on gui/trans.py).
>
> It is looking at:
>
> elif os.path.exists(os.path.join(PREFIXDIR, "share/locale")):
>       LOCALEDIR = os.path.join(PREFIXDIR, "share/locale")
>
> Not certain of the cause of the problem (python3?), but by tracking this
> down:
>
> <gramps.gen.plug._pluginreg.PluginData object at 0x989a66c>] {0:
> u'Analyse et exploration', 1: u"Modification de l'arbre familial", 2:
> u"R\xe9paration de l'arbre familial", 3: u'Contr\xf4le de r\xe9vision',
> 4: u'Utilitaires', -1: u'D\xe9boguer'}
>
> we can see some 'unicode' strings.
>
>
> As temp workaround, I am using an existing GRAMPSI18N dir (even without
> compiled translations into this dir)!
>
> $ GRAMPSI18N=/home/jerome
> PYTHONPATH=/usr/local/lib/python2.7/site-packages/ python Gramps.py
>
> ie. it is related to a previous LOCALEDIR (gramps 3.4.2) or local
> compilation...
>
>
> Jérôme
>
>
> Le 23/11/2012 10:49, Gary Burton a écrit :
>> Hello Peter,
>>
>> The error you get suggests the XML is broken but the XML looks well formed to me.
>>
>> I think the problem you are seeing might be due to the XML parser not being able to handle the ä and ö characters which appear in the action attributes. Figuring out why you are getting these warnings will probably help
>>
>>> 179: WARNING: trans.py: line 66: Locale dir does not exist at
>>> /home/peter/Gramps/trunk/gramps/gen/../share/locale
>>> 179: WARNING: trans.py: line 67: Running ./configure
>>> --prefix=YourPrefixDir might fix the problem
>>
>> Bye
>>
>> Gary
>>
>> ----- Original Message -----
>>> From: Peter Landgren <peter.talken@telia.com>
>>> To: Benny Malengier <benny.malengier@gmail.com>
>>> Cc: Gramps Development List <gramps-devel@lists.sourceforge.net>
>>> Sent: Friday, 23 November 2012, 9:25
>>> Subject: Re: [Gramps-devel] Running trunk with åython 2.7
>>>
>>> Benny,
>>>
>>> This is what I print out. I have edited it so it is more readable:
>>> uidef=
>>> <ui>
>>> <menubar name="MenuBar">
>>> <menu action="ToolsMenu">
>>> <placeholder name="P_ToolsMenu">
>>> <menu action="Analys-och-utforskning">
>>> <menuitem action="dbrowse"/>
>>> <menuitem action="eventcmp"/>
>>> </menu>
>>> <menu action="Bearbetar-Släktträd">
>>> <menuitem action="dupfind"/>
>>> <menuitem action="excity"/>
>>> <menuitem action="patchnames"/>
>>> <menuitem action="chname"/>
>>> <menuitem action="editowner"/>
>>> <menuitem action="mergecitations"/>
>>> <menuitem action="reorder_ids"/>
>>> <menuitem action="sortevents"/>
>>> <menuitem action="evname"/>
>>> <menuitem action="chtype"/>
>>> </menu>
>>> <menu action="Felsökning">
>>> <menuitem action="test_for_date_parser_and_displayer"/>
>>> <menuitem action="dgenstats"/>
>>> <menuitem action="testcasegenerator"/>
>>> <menuitem action="populatesources"/>
>>> <menuitem action="eval"/>
>>> <menuitem action="leak"/>
>>> </menu>
>>> <menu action="Hjälpmedel">
>>> <menuitem action="not_related"/>
>>> <menuitem action="mediaman"/>
>>> <menuitem action="soundgen"/>
>>> <menuitem action="relcalc"/>
>>> <menuitem action="verify"/>
>>> </menu>
>>> <menu action="Reparera-Släktträd">
>>> <menuitem action="rebuild_refmap"/>
>>> <menuitem action="check"/>
>>> <menuitem action="rebuild"/>
>>> <menuitem action="remove_unused"/>
>>> <menuitem action="rebuild_genstats"/>
>>> </menu>
>>> </placeholder>
>>> </menu>
>>> </menubar>
>>> </ui>
>>>
>>>
>>> I also printed out parameters:
>>>
>>> text=
>>> ToolsMenu
>>>
>>> item_list=
>>> [<gramps.gen.plug._pluginreg.PluginData object at 0x343b990>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bad0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343b9d0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527650>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343be90>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527350>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343ba90>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343b8d0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bf50>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x35271d0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527490>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343b950>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bc10>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bb90>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527510>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bbd0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527590>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527710>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bdd0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527610>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bcd0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x35275d0>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343b910>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bd50>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527690>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x3527410>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343bd10>,
>>> <gramps.gen.plug._pluginreg.PluginData object at 0x343ba50>]
>>>
>>> categories=
>>> {0: u'Analys och utforskning',
>>> 1: u'Bearbetar Sl\xe4kttr\xe4d',
>>> 2: u'Reparera Sl\xe4kttr\xe4d',
>>> 3: u'Versionshantering',
>>> 4: u'Hj\xe4lpmedel',
>>> -1: u'Fels\xf6kning'}
>>>
>>> /Peter
>>>
>>> Den Thursday 22 November 2012 22.25.12 skrev Benny Malengier:
>>>> Peter,
>>>>
>>>> A wrong uidef has been generated on your computer, could be a locale issue.
>>>> To know, add a print statement in front of the offending line, so in front
>>>> of line 1754
>>>>
>>>>       File "/home/peter/Gramps/trunk/gramps/gui/viewmanager.py",
>>> line 1754,
>>>> in __build_tools_menu
>>>>         self.tool_menu_ui_id =
>>>> self.uistate.uimanager.add_ui_from_string(uidef)
>>>>
>>>> add a
>>>>     print (uidef)
>>>>
>>>> uidef will contain an error. This could be due to an error in a 3rd party
>>>> tool, or a locale issue, ...
>>>>
>>>> The error will come from the line
>>>>
>>>>           (uidef, actions) = self.build_plugin_menu(
>>>>               'ToolsMenu', tool_menu_list, tool.tool_categories,
>>>>               make_plugin_callback)
>>>>
>>>> so we will need the values of the parameters to investigatte further
>>>> You could add prints in the build_plugin_menu to see where the wrong uidef
>>>> is created exactly.
>>>>
>>>> Benny
>>>>
>>>> 2012/11/22 Peter Landgren <peter.talken@telia.com>
>>>>
>>>>> Hi,
>>>>>
>>>>> I'm trying to run trunk, but get this msg:
>>>>> 5439: ERROR: grampsgui.py: line 344:
>>>>> Gramps misslyckades med att starta. Rapportera detta som en bug.
>>>>> detta skulle kunna bero på en (third party) vy vid uppstart.
>>>>> För att använda en annan vy, ladda inget släktträd, ändra vy och ladda
>>>>> sedan ditt släktträd.
>>>>> Du kan även ändra detta manuellt uppstartvyn filen gramps.ini
>>>>> genom att ändra parametern "last-view".
>>>>>
>>>>> Traceback (most recent call last):
>>>>>       File "/home/peter/Gramps/trunk/gramps/gui/grampsgui.py",
>>> line 313, in
>>>>>
>>>>> __startgramps
>>>>>
>>>>>         Gramps(argparser)
>>>>>
>>>>>       File "/home/peter/Gramps/trunk/gramps/gui/grampsgui.py",
>>> line 238, in
>>>>>
>>>>> __init__
>>>>>
>>>>>         self.vm.init_interface()
>>>>>
>>>>>       File
>>> "/home/peter/Gramps/trunk/gramps/gui/viewmanager.py", line 960,
>>>>>
>>>>> in init_interface
>>>>>
>>>>>         self.__build_tools_menu(self._pmgr.get_reg_tools())
>>>>>
>>>>>       File
>>> "/home/peter/Gramps/trunk/gramps/gui/viewmanager.py", line 1754,
>>>>>
>>>>> in __build_tools_menu
>>>>>
>>>>>         self.tool_menu_ui_id =
>>>>>
>>>>> self.uistate.uimanager.add_ui_from_string(uidef)
>>>>>
>>>>>       File
>>> "/usr/lib64/python2.7/site-packages/gi/overrides/Gtk.py", line
>>>>>
>>>>> 297, in add_ui_from_string
>>>>>
>>>>>         return Gtk.UIManager.add_ui_from_string(self, buffer, length)
>>>>>
>>>>>       File "/usr/lib64/python2.7/site-packages/gi/types.py",
>>> line 47, in
>>>>>
>>>>> function
>>>>>
>>>>>         return info.invoke(*args, **kwargs)
>>>>>
>>>>> GError: Fel på rad 1 tecken 1182:Dokumentet tog oväntat slut inuti
>>>>> stängningstaggen för elementet "menubar"
>>>>>
>>>>>                 (Error in line 1 chr 1182:Doc ended unexpectedly inside
>>>>>
>>>>> the closing tag for element "menubar")
>>>>>
>>>>> Versions:
>>>>> [peter@dell2 trunk]$ python Gramps.py -v
>>>>> 179: WARNING: trans.py: line 66: Locale dir does not exist at
>>>>> /home/peter/Gramps/trunk/gramps/gen/../share/locale
>>>>> 179: WARNING: trans.py: line 67: Running ./configure
>>>>> --prefix=YourPrefixDir might fix the problem
>>>>> Gramps Settings:
>>>>> ----------------
>>>>>
>>>>>     python    : 2.7.3
>>>>>     gramps    : 4.0.0
>>>>>     gtk++    : 3.6.2
>>>>>     gobject  : 3.4.2
>>>>>     Not using bsddb3
>>>>>     bsddb    : 4.8.4.2
>>>>>     bsddb.db  : (5, 3, 21)
>>>>>     cairo    : 1.10.0
>>>>>     osmgpsmap : not found
>>>>>     pyexiv2  : 0.3.0
>>>>>     o.s.      : Linux
>>>>>     kernel    : 3.6.5-desktop-1.mga3
>>>>>
>>>>> Environment settings:
>>>>> ---------------------
>>>>>
>>>>>     LANG      : sv_SE.UTF-8
>>>>>     LANGUAGE  : sv_SE.UTF-8
>>>>>     GRAMPSI18N: not set
>>>>>     GRAMPSHOME: not set
>>>>>     GRAMPSDIR : not set
>>>>>
>>>>>     PYTHONPATH:
>>>>>         /home/peter/Gramps/trunk
>>>>>         /usr/lib/python27.zip
>>>>>         /usr/lib64/python2.7
>>>>>         /usr/lib64/python2.7/plat-linux2
>>>>>         /usr/lib64/python2.7/lib-tk
>>>>>         /usr/lib64/python2.7/lib-old
>>>>>         /usr/lib64/python2.7/lib-dynload
>>>>>         /usr/lib64/python2.7/site-packages
>>>>>         /usr/lib64/python2.7/site-packages/PIL
>>>>>         /usr/lib64/python2.7/site-packages/gtk-2.0
>>>>>         /usr/lib/python2.7/site-packages
>>>>>
>>>>> /usr/lib/python2.7/site-packages/setuptools-0.6c11-py2.7.egg-info
>>>>>
>>>>> Non-python dependencies:
>>>>> ------------------------
>>>>>
>>>>>     Graphviz  : dot - graphviz version 2.28.0 (20121105.0942)
>>>>>     Ghostscr. : 9.06
>>>>>
>>>>> System PATH env variable:
>>>>> -------------------------
>>>>>
>>>>>         /usr/bin
>>>>>         /bin
>>>>>         /usr/local/bin
>>>>>         /usr/X11R6/bin/
>>>>>         /usr/games
>>>>>         /usr/lib64/qt4/bin
>>>>>         /home/peter/bin
>>>>>
>>>>> /Peter
>>>>>
>>>>>
>>>>>
>>>>>
>>> -------------------------------------------------------------------------
>>>>> ----- Monitor your physical, virtual and cloud infrastructure from a
>>>>> single web console. Get in-depth insight into apps, servers,
>>> databases,
>>>>> vmware, SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>>>>> Pricing starts from $795 for 25 servers or applications!
>>>>> http://p.sf.net/sfu/zoho_dev2dev_nov
>>>>> _______________________________________________
>>>>> Gramps-devel mailing list
>>>>> Gramps-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/gramps-devel
>>>
>>> --
>>> Peter Landgren
>>> Talken Hagen
>>> 671 94  BRUNSKOG
>>> 0570-530 21
>>> 070-345 0964
>>> peter.talken@telia.com
>>> Skype: pgl4820.2
>>>
>>> ------------------------------------------------------------------------------
>>> Monitor your physical, virtual and cloud infrastructure from a single
>>> web console. Get in-depth insight into apps, servers, databases, vmware,
>>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>>> Pricing starts from $795 for 25 servers or applications!
>>> http://p.sf.net/sfu/zoho_dev2dev_nov
>>> _______________________________________________
>>> Gramps-devel mailing list
>>> Gramps-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/gramps-devel
>>>
>>
>> ------------------------------------------------------------------------------
>> Monitor your physical, virtual and cloud infrastructure from a single
>> web console. Get in-depth insight into apps, servers, databases, vmware,
>> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
>> Pricing starts from $795 for 25 servers or applications!
>> http://p.sf.net/sfu/zoho_dev2dev_nov
>> _______________________________________________
>> Gramps-devel mailing list
>> Gramps-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gramps-devel
>>
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
> _______________________________________________
> Gramps-devel mailing list
> Gramps-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gramps-devel
>


------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Gramps-devel mailing list
Gramps-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gramps-devel