Raised if an ambiguous option is seen on the command line.
| 134 | return _("no such option: %s") % self.opt_str |
| 135 | |
| 136 | class AmbiguousOptionError (BadOptionError): |
| 137 | """ |
| 138 | Raised if an ambiguous option is seen on the command line. |
| 139 | """ |
| 140 | def __init__(self, opt_str, possibilities): |
| 141 | BadOptionError.__init__(self, opt_str) |
| 142 | self.possibilities = possibilities |
| 143 | |
| 144 | def __str__(self): |
| 145 | return (_("ambiguous option: %s (%s?)") |
| 146 | % (self.opt_str, ", ".join(self.possibilities))) |
| 147 | |
| 148 | |
| 149 | class HelpFormatter: |