gnumed-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-devel] <bug>: :) first 0.3.2 bug ?? - In production I was


From: Karsten Hilbert
Subject: Re: [Gnumed-devel] <bug>: :) first 0.3.2 bug ?? - In production I was
Date: Sun, 12 Oct 2008 13:13:04 +0200
User-agent: Mutt/1.5.18 (2008-05-17)

> On Sat, Sep 13, 2008 at 10:10:28AM -0400, Dr.Rogerio Luz wrote:
> 
> > user comment  : :) first 0.3.2 bug ?? - In production I
> > was closing the consult and when I clicked again at my
> > Health Issue for the same episode this appeared, seems
> > everything was saved and edited as my needs seem fit,
> 
> ...
> 
> > 2008-09-13 11:00:53  DEBUG     gm.i18n 
> > (/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/pycommon/gmI18N.py::__log_locale_settings()
> >  #167): ${LANG}=pt_BR.UTF-8
> ...
> > 2008-09-13 11:00:53  DEBUG     gm.i18n 
> > (/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/pycommon/gmI18N.py::activate_locale()
> >  #213): activating user-default locale with 
> > <locale.setlocale(locale.LC_ALL, '')> returns: [pt_BR.UTF-8]
> 
> You are running on a Brazilian machine.
> 
> > 2008-09-13 11:00:53  DEBUG     gm.i18n 
> > (/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/pycommon/gmI18N.py::install_domain()
> >  #293): trying [/usr/share/locale](/pt_BR/LC_MESSAGES/gnumed.mo)
> > 2008-09-13 11:00:53  DEBUG     gm.i18n 
> > (/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/pycommon/gmI18N.py::install_domain()
> >  #306): found msg catalog: [Translate this or i18n will not work properly 
> > !] => [Traduza isso ou o i18n não funcionará de maneira correta ! ]
> 
> GNUmed finds a Brazilian translation. Everything works until ...
> 
> > 2008-09-13 11:07:42  DEBUG     gm.gui 
> > (/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/wxpython/gmExceptionHandlingWidgets.py::handle_uncaught_exception_wx()
> >  #45): unhandled exception caught:
> > Traceback (most recent call last):
> >   File 
> > "/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/wxpython/gmEMRBrowser.py",
> >  line 466, in _on_tree_item_selected
> >     self.__update_text_for_selected_node()
> >   File 
> > "/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/wxpython/gmEMRBrowser.py",
> >  line 171, in __update_text_for_selected_node
> >     txt = node_data.format(left_margin=1, patient = self.__pat)
> >   File 
> > "/home/rogerio/Desktop/Gnumed/GNUmed-client.0.3.2/GNUmed-0.3.2/Gnumed/business/gmEMRStructItems.py",
> >  line 166, in format
> >     self._payload[self._idx['pk']]
> > TypeError: not all arguments converted during string formatting
> 
> ... this happens. The error says that there must be
> something like
> 
>       '%s' % some_value
> 
> in line 166 of gmEMRStructItems. Here is that line:
> 
>       lines.append(_('Foundational Health Issue %s%s%s [#%s]') % (
>               u'\u00BB',
>               self._payload[self._idx['description']],
>               u'\u00AB',
>               self._payload[self._idx['pk']]
>       ))
> 
> Strange. There is 4 %s and also 4 arguments after the "%".
> However, the string is getting translated by _(). That
> means, the translated string could contain the actual error.
> So, see pt_BR.po:
> 
>       msgid "Foundational Health Issue %s%s%s [#%s]"
>       msgstr "Patologia Básica"
> 
> Indeed ! The line is lacking %s's ! The last line must be:
> 
>       msgstr "Patologia Básica %s%s%s [#%s]"
> 
> I have fixed the faulty translation in CVS.
> 
> Karsten
> -- 
> GPG key ID E4071346 @ wwwkeys.pgp.net
> E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346

-- 
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346




reply via email to

[Prev in Thread] Current Thread [Next in Thread]