Uploaded image for project: 'Commons CLI'
  1. Commons CLI
  2. CLI-183

Clear the selection from the groups before parsing

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.0, 1.1, 1.2
    • Fix Version/s: 1.3
    • Component/s: None
    • Labels:
      None

      Description

      OptionGroup stores the name of the option selected after the parsing. If the same Options is used again to parse another command line, an AlreadySelectedException is likely to occur since the selection state is never cleared from the option group.

      This case was already covered by testValidLongOnlyOptions() in OptionGroupTest, but it never failed due to CLI-182.

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            ebourg Emmanuel Bourg
            Reporter:
            ebourg Emmanuel Bourg
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development