[Asterisk-code-review] contrib/sip to pjsip: add a --quiet option to avoid prints (asterisk[13])

George Joseph asteriskteam at digium.com
Wed Oct 31 09:31:58 CDT 2018


George Joseph has posted comments on this change. ( https://gerrit.asterisk.org/10566 )

Change subject: contrib/sip_to_pjsip: add a --quiet option to avoid prints
......................................................................


Patch Set 1:

(1 comment)

https://gerrit.asterisk.org/#/c/10566/1/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py
File contrib/scripts/sip_to_pjsip/sip_to_pjsip.py:

https://gerrit.asterisk.org/#/c/10566/1/contrib/scripts/sip_to_pjsip/sip_to_pjsip.py@1277
PS1, Line 1277:     stdout_handler = logging.StreamHandler(sys.stdout)
              :     stdout_handler.setFormatter(logging.Formatter('%(message)s'))
              :     if options.quiet:
              :         log_level = logging.ERROR
              :     else:
              :         log_level = logging.INFO
              : 
              :     stdout_handler.setLevel(log_level)
              :     logger.addHandler(stdout_handler)
              :     logger.setLevel(log_level)
Why not have the errors always go to stderr then have your -q option just suppress the info messages?



-- 
To view, visit https://gerrit.asterisk.org/10566
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: comment
Gerrit-Change-Id: I7b0e2e90e2549f3f8e01dc96701f111b5874c88d
Gerrit-Change-Number: 10566
Gerrit-PatchSet: 1
Gerrit-Owner: Pascal Cadotte Michaud <pcm at wazo.io>
Gerrit-Reviewer: Benjamin Keith Ford <bford at digium.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2 (1000185)
Gerrit-Comment-Date: Wed, 31 Oct 2018 14:31:58 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20181031/dbcaf3c8/attachment.html>


More information about the asterisk-code-review mailing list