Re: [pygccxml-development] improving user experience
Brought to you by:
mbaas,
roman_yakovenko
From: Roman Y. <rom...@gm...> - 2006-07-17 10:24:10
|
On 7/17/06, Matthias Baas <ba...@ir...> wrote: > Roman Yakovenko wrote: > > Hi. I just committed a set of changes, that should improve usability > > of pyplusplus. > > To be more specific: by default only important messages are send to the > > user: > > 1. gccxml invocation command line ( info ) > > 2. warning about declaration, that could not be exported > > I've noticed two things: > > - Even though there are several logging streams now I think warning > message should still be issued using warning() instead of info() (so > that I can set up a file handler at the root logger that only writes > true warnings). For example, in calldef_t._exportable_impl() the message > about the max_arity thing is still written using info(). Roman, do you > mind if I change that to warning()? Please do it. > - Most warnings are still "hidden" from the user until he explicitly > obtains them using the readme() method. I did a test and modified the > code in decl_wrapper_t.get_exportable() so that any time > self._exportable_reason is set to a non-empty string this string is also > written to the logger. What I don't know is if the "exportable" > attribute will always be obtained by pyplusplus internally, i.e. if > get_exportable() will always be called or not. Yes. Please take a look on _get_ignore method. It will be always called from it. > By running my Maya stuff > it seems to be the case as I got much more warnings. So should I check > that in as well? I don't understand, sorry. What do you want to check/fix? >And are there other methods that create warning/error > messages that are only returned as strings instead of being written to a > logger? decl_wrappers.decl_wrapper_t derived classes should not directly write to log. Instead of this, they should implement _exportable_impl method, that will return string( explanation ) if declaration could not be exported and None if it could. > A lot of the above new warnings are about compiler generated > constructors (it always seems to be the copy constructor in my case). Is > this really worth a message at all? I certainly don't expect pyplusplus > to generate wrappers for things that are not there, so I think > pyplusplus could just silently ignore those artifical declarations that > are only created by gccxml (I don't really know why they are generated > at all?). I thought, I disabled them. I will check one more time. Can you check, whether you are running with latest version? Thanks -- Roman Yakovenko C++ Python language binding http://www.language-binding.net/ |