SiLab-Bonn / pylandau

Simple Landau distribution definitions to be used in Python.
GNU Lesser General Public License v2.1
20 stars 4 forks source link

Use python's in-built logging module #29

Open umute97 opened 1 year ago

umute97 commented 1 year ago

More of a feature request: At the moment, warnings and errors are printed out via print() functions. I suggest using the logging module to filter feedback from pylandau based on a verbosity level.

This happens on the latest release pylandau==2.2.1.

Example

WARNING: sigma > 100 * eta can lead to oszillations. Check result.

cbespin commented 1 year ago

Thanks for the suggestion! I completely agree, but have very limited time currently for support. Since the fix is minimal, could you provide a pull request?

guigoruiz1 commented 3 weeks ago

I second that. The warning is quite annoying and I'd like to be able to silence it

cbespin commented 3 weeks ago

Sorry, that I did not come to this sooner. I will deal with it probably next week if nobody opens a merge request