cbc-apitool: compatibility with python < 3.7
The "required" parameter to argparse.add_subparsers() was only added in python 3.7. However, given that it defaults to 'required' and was always unconditionally required even in python 2.x, we can safely remove it. Change-Id: Ia0ffca055f47016fb29ef009acecac2a139e4077
This commit is contained in:
parent
e8ab2f3148
commit
d6a3728bce
|
@ -117,7 +117,7 @@ def main(argv):
|
|||
parser.add_argument("-p", "--port", help="TCP port to connect to", default=12345)
|
||||
parser.add_argument("-v", "--verbose", help="increase output verbosity", action='count', default=0)
|
||||
|
||||
subparsers = parser.add_subparsers(required=True)
|
||||
subparsers = parser.add_subparsers()
|
||||
|
||||
parser_c_cbs = subparsers.add_parser('create-cbs', help='Create a new CBS message')
|
||||
parser_c_cbs.add_argument("--msg-id", type=int, help='Message Identifier', required=True)
|
||||
|
|
Loading…
Reference in New Issue