Hi Zach, et al., I have been looking into adding a toggle in the help menu for turning on chirp debug logging. It’s sort of cumbersome for many users to have to set env var (e.g., CHIRP_DEBUG) and launch. It would be much easier to just ask them to toggle something in a menu, similar to “enable developer settings”, we could have “enable debug logs”) when troubleshooting an issue and asking for debug.log.
I have added such a thing to the help menu in mainapp.py, however when I try to toggle it, the root/global logging levels are not changed. I am a novice with Python logging.
I’m basically doing this:
logger = logging.getLogger() logger.setLevel(logging.DEBUG)
My understanding is that this should get an instance of the root logger, and set the level of all children, but this doesnt seem to be happening.
Can you offer some advice or insight on how to do this?
PS: while looking at this, I re-noticed that chirp doesn’t have any kind of “settings” menu like other programs. I bring this up, because looking at your logger module, it makes me think there should actually be an option for user to set one of several possible log levels (warning, info, debug, etc), but that is probably a much longer topic ;)
-Jens