parser.add_argument('--val', dest='val', action='store', choices=['a', 'b',
    'c'], help='Special testing value')
args = parser.parse_args(sys.argv[1:])
Allowing a specific value for an Argparse argument