Understanding Python: Logging Basics
Вставка
- Опубліковано 25 лют 2024
- #python #pythontutorial #pythontutorialforbeginners
So you wrote a great program that runs silently until all of a sudden {crash!} it drops an exception. You want to know what led up to this error, but scattering print statements isn't going to cut it. That's when you need to turn to logging, stick with me and you'll learn everything you need to reveal your program's runtime mysteries.
As always, please comment below if you have any questions or suggestions for future videos.
Chapters
00:50 - Getting Started
06:34 - Formatting
Follow me on X: x.com/JakeJCallahan
Source: github.com/JacobCallahan/Unde...
Intro music: 失望した by Eva
Link: • EVA - 失望した [Synthwave]...
Outro music: Elix by Synthness
Link: • Synthness - Elix ★ No ... - Наука та технологія
Logging is a large subject! Is there anything you'd specifically like to know, or something you find difficult?
Amazing video, my dear friend! Congrats!! 😉👍
another great video! love your intro! smooth and well done!
GREAT VIDEO! I've put off diving into the specifics of logger for a while now as it wasn't really a priority. Looks like you did all the heavy lifting for me!
Suggestion: It would have been cool to see an example of implementing a application argument via argeparse to set the default log level.
I was wondering if there are any particular benefits to writing class-based loggers. Also, how to do them 'right'...
Would love to see something on that subject.
Hi, Jake and thanks as always.
Have you tried loguru instead of builtin logging? if yes, what is your opinion on it? looks like it is much simpler for configuration.
For most of my work/personal projects, I use logzero. However, that project is no longer maintained, so will eventually die off.
I have looked into loguru as an alternative and it does look promising.
However, I'd really have to look into it's features before adopting over my own custom-built logging solution, since I tend to like to do things myself!
If you do try it out, please follow up with your thoughts on it, I'd be very interested in what you think.
"Promosm" 👏