0

Trying to print a customised help section with Argparse:

import logging
logging.getLogger("scapy.runtime").setLevel(logging.ERROR)
import sys
from scapy.all import *
import argparse
parser = argparse.ArgumentParser()
parser.add_argument("--remote_host")
parser.add_argument("--verbose")
parser.add_argument("--help")
args = parser.parse_args()

if args.help:
    print("HELP...")

running --help on the script results in the following error:

raise ArgumentError(action, message % conflict_string)
argparse.ArgumentError: argument --help: conflicting option string: --help
jonrsharpe
  • 107,083
  • 22
  • 201
  • 376
IlludiumPu36
  • 4,058
  • 9
  • 56
  • 97

0 Answers0