What are the benefits of using logging in python
Most people do not understand the knowledge points of this article "what are the benefits of using logging in python", so the editor summarizes the following contents, detailed contents, clear steps, and has a certain reference value. I hope you can get something after reading this article. Let's take a look at this article "what are the benefits of using logging in python?"
Description
1. Allows you to specify the level of recording information, including debug, info, warning, error, etc.
2. Another advantage of logging is that through simple configuration, a statement can be output to different places at the same time, such as console and file.
Example
Import logginglogging.basicConfig (level=logging.INFO) s = '0roomn = int (s) logging.info (' n =% d'% n) print (10 / n) what does python mean? Python is a cross-platform, interpretive, compiled, interactive and object-oriented scripting language that was originally designed to write automated scripts. as versions are constantly updated and new features are added, Python is often used to develop independent and large projects.
The above is about the article on "what are the benefits of using logging in python?" I believe we all have a certain understanding. I hope the content shared by the editor will be helpful to you. If you want to know more about the relevant knowledge, please follow the industry information channel.