Debug Levels when writing an application

前端 未结 8 1270
别那么骄傲
别那么骄傲 2020-12-23 12:11

I would like to know if you guys have any suggestions about debug levels when writing an application.

I thought about 4 levels:

0 : No Debug
1 : All inpu

8条回答
  •  隐瞒了意图╮
    2020-12-23 13:07

    I have:

    • Critical/Fatal, the program can't possible continue, normally the user lost it.
    • Error, someting really wrong, used data can be corrupt, but you can be lucky.
    • Warning, this is not right, I can continue, but please have a look.
    • Hint/Information, i like to say something, but I don't expect you to listen.
    • Debug, all information only interesting for programmers.

    Normaly the lowest two levels are blocked. But the others are shown. And if you want to block the Fatal level, its fine with me, but don't expect that I clean up the mess afterwards (unfortunately I still have to...).

提交回复
热议问题