How do I get rid of runtime warning in Python?
To disable warnings in Python, we can make use of the filterwarnings() method from the warnings module in Python. The warning filter contains a list of filter parameters.
How do I ignore a user warning in Python?
If you wish to squelch deprecation warnings, you can start Python with -Wi::Deprecation. This sets all deprecation warnings to ignored.