parameters: ()
docstring: Run the script.
docstring_summary: Run the script.
docstring_tokens: Run the script .
function: def main():
      """Run the script."""
      arg_parser = argparse.ArgumentParser(description=__doc__)
      arg_parser.add_argument("-v", "--verbose", action="count", help="Enable verbose logging")
      arg_parser.add_argument("--old-include", dest="old_include", type=str, action="append",
                              default=[], help="Directory to search for old IDL import files")
      arg_parser.add_argument("--new-include", dest="new_include", type=str, action="append",
                              default=[], help="Directory to search for new IDL import files")
      arg_parser.add_argument("old_idl_dir", metavar="OLD_IDL_DIR",
                              help="Directory where old IDL files are located")
      arg_parser.add_argument("new_idl_dir", metavar="NEW_IDL_DIR",
                              help="Directory where new IDL files are located")
      args = arg_parser.parse_args()
  
      error_coll = check_compatibility(args.old_idl_dir, args.new_idl_dir, args.old_include,
                                       args.new_include)
      if error_coll.has_errors():
          sys.exit(1)
  
      old_basic_types_path = os.path.join(args.old_idl_dir, "mongo/idl/basic_types.idl")
      new_basic_types_path = os.path.join(args.new_idl_dir, "mongo/idl/basic_types.idl")
      error_reply_coll = check_error_reply(old_basic_types_path, new_basic_types_path,
                                           args.old_include, args.new_include)
      if error_reply_coll.has_errors():
          sys.exit(1)
  
      old_generic_args_path = os.path.join(args.old_idl_dir, "mongo/idl/generic_argument.idl")
      new_generic_args_path = os.path.join(args.new_idl_dir, "mongo/idl/generic_argument.idl")
      error_gen_args_coll = check_generic_arguments_compatibility(old_generic_args_path,
                                                                  new_generic_args_path)
      if error_gen_args_coll.has_errors():
          sys.exit(1)
function_tokens: def main ( ) : arg_parser = argparse . ArgumentParser ( description = __doc__ ) arg_parser . add_argument ( "-v" , "--verbose" , action = "count" , help = "Enable verbose logging" ) arg_parser . add_argument ( "--old-include" , dest = "old_include" , type = str , action = "append" , default = [ ] , help = "Directory to search for old IDL import files" ) arg_parser . add_argument ( "--new-include" , dest = "new_include" , type = str , action = "append" , default = [ ] , help = "Directory to search for new IDL import files" ) arg_parser . add_argument ( "old_idl_dir" , metavar = "OLD_IDL_DIR" , help = "Directory where old IDL files are located" ) arg_parser . add_argument ( "new_idl_dir" , metavar = "NEW_IDL_DIR" , help = "Directory where new IDL files are located" ) args = arg_parser . parse_args ( ) error_coll = check_compatibility ( args . old_idl_dir , args . new_idl_dir , args . old_include , args . new_include ) if error_coll . has_errors ( ) : sys . exit ( 1 ) old_basic_types_path = os . path . join ( args . old_idl_dir , "mongo/idl/basic_types.idl" ) new_basic_types_path = os . path . join ( args . new_idl_dir , "mongo/idl/basic_types.idl" ) error_reply_coll = check_error_reply ( old_basic_types_path , new_basic_types_path , args . old_include , args . new_include ) if error_reply_coll . has_errors ( ) : sys . exit ( 1 ) old_generic_args_path = os . path . join ( args . old_idl_dir , "mongo/idl/generic_argument.idl" ) new_generic_args_path = os . path . join ( args . new_idl_dir , "mongo/idl/generic_argument.idl" ) error_gen_args_coll = check_generic_arguments_compatibility ( old_generic_args_path , new_generic_args_path ) if error_gen_args_coll . has_errors ( ) : sys . exit ( 1 )