[Libreoffice-bugs] [Bug 132110] Wizard service broken

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Wed Apr 15 10:01:10 UTC 2020


https://bugs.documentfoundation.org/show_bug.cgi?id=132110

--- Comment #8 from Stephan Bergmann <sbergman at redhat.com> ---
(In reply to Julien Nabet from comment #7)
> Stephan: taking a look at this error:
> Python exception: <class 'RuntimeError'>: Type [] string is unknown,
> traceback follows
>   File
> "/home/julien/lo/libreoffice/instdir/user/uno_packages/cache/uno_packages/
> lu146xe6.tmp_/OAuth2OOo.oxt/pythonpath/unolib/unolib.py", line 46, in
> getPropertySetInfo
>     properties = self._getPropertySetInfo()
>   File
> "/home/julien/lo/libreoffice/instdir/user/uno_packages/cache/uno_packages/
> lu146xeb.tmp_/smtpMailerOOo.oxt/pythonpath/smtpmailer/wizardhandler.py",
> line 383, in _getPropertySetInfo
>     properties['DataSources'] = getProperty('DataSources', '[] string',
> transient)
>   File
> "/home/julien/lo/libreoffice/instdir/user/uno_packages/cache/uno_packages/
> lu146xe6.tmp_/OAuth2OOo.oxt/pythonpath/unolib/unotools.py", line 53, in
> getProperty
>     property.Type = uno.getTypeByName(type)
>   File "/home/julien/lo/libreoffice/instdir/program/uno.py", line 73, in
> getTypeByName
>     return pyuno.getTypeByName(typeName)
> 
> I thought we could use this patch:
> diff --git a/cppu/source/typelib/typelib.cxx
> b/cppu/source/typelib/typelib.cxx
> index 92a7e6ca5120..b9f008365bcf 100644
> --- a/cppu/source/typelib/typelib.cxx
> +++ b/cppu/source/typelib/typelib.cxx
> @@ -1906,6 +1906,7 @@ extern "C" void SAL_CALL
> typelib_typedescription_getByName(
>          if (2 < name.getLength() && '[' == name[ 0 ])
>          {
>              OUString element_name( name.copy( 2 ) );
> +            element_name = element_name.trim();
>              typelib_TypeDescription * element_td = nullptr;
>              typelib_typedescription_getByName( &element_td,
> element_name.pData );
>              if (nullptr != element_td)
> 
> What do you think?

No, such errors should always be fixed on the calling side.  There is a precise
grammar for names of UNO type system entities (see
<http://www.openoffice.org/udk/common/man/typesystem.html>), and we shouldn't
second-guess what calling code actually meant.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20200415/493b8df4/attachment.htm>


More information about the Libreoffice-bugs mailing list