Thanks to you two, I didn't realize that it can cause other troubles.. So I will continue to use pushInfo/repportError !
Regards, 2018-07-10 2:56 GMT+02:00 Nyall Dawson <nyall.daw...@gmail.com>: > On Tue, 10 Jul 2018 at 05:15, Jean-Baptiste Desbas <jb.des...@gmail.com> > wrote: > > > > > > Hi, > > > > I just want to display a messageBar instead of displaying it un the > processing output console (feedback.pushInfo) It's ni big deal but i was > just confused. > > As Matthias has said -- don't do this! Apart from the crashes, it will > also break use of your algorithms from standalone scripts, where iface > is not available. It also means the output is not properly logged, so > users who want to save the log from model execution for later > reference won't have these messages included. > > > Do toi have any tips of use case of the differents pushInfo, > pushConsoleInfo, etc. ? > > Basically you can stick to pushInfo and reportError. Use pushInfo for > informative messages, such as "Building spatial index" or "Found 56 > matching features", and reportError for... errors... e.g. "Feature > does not have a point geometry, skipping". > > Nyall >
_______________________________________________ Qgis-user mailing list Qgis-user@lists.osgeo.org List info: https://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user