[Zope3-checkins] SVN: Zope3/trunk/src/zope/ Internationalized
apidoc modules description.
Dmitry Vasiliev
dima at hlabs.spb.ru
Thu Sep 2 11:54:02 EDT 2004
Stephan Richter wrote:
> On Thursday 02 September 2004 03:59, Dmitry Vasiliev wrote:
>
>>Modified: Zope3/trunk/src/zope/i18n/__init__.py
>>===================================================================
>>--- Zope3/trunk/src/zope/i18n/__init__.py 2004-09-02 07:05:38 UTC
>>(rev 27409) +++ Zope3/trunk/src/zope/i18n/__init__.py 2004-09-02
>>07:59:06 UTC (rev 27410) @@ -17,6 +17,7 @@
>> """
>> import re
>> import warnings
>>+from zope.security.proxy import isinstance, removeSecurityProxy
>> from zope.component import queryUtility
>> from zope.i18nmessageid import MessageIDFactory, MessageID
>> from zope.i18n.interfaces import ITranslationDomain
>>@@ -33,6 +34,7 @@
>> def _translate(msgid, domain=None, mapping=None, context=None,
>> target_language=None, default=None):
>>
>>+ msgid = removeSecurityProxy(msgid)
>>
>> if isinstance(msgid, MessageID):
>> domain = msgid.domain
>
>
> Dimitry,
>
> this is unacceptable, since it creates a dependence of zope.security in
> zope.i18n. Since this problem occurred only as you internationalized API doc,
> we should be able to quickly determine the place where we should call the
> removeSecurityProxy() call.
Oh, right. I'll move removeSecurityProxy call in
APIDocumentationView.getModuleList.
--
Dmitry Vasiliev (dima at hlabs.spb.ru)
http://hlabs.spb.ru
More information about the Zope3-Checkins
mailing list