MCPcopy Create free account
hub / github.com/RustPython/RustPython / _handle_conflict_resolve

Method _handle_conflict_resolve

Lib/argparse.py:1726–1738  ·  view source on GitHub ↗
(self, action, conflicting_actions)

Source from the content-addressed store, hash-verified

1724 raise ArgumentError(action, message % conflict_string)
1725
1726 def _handle_conflict_resolve(self, action, conflicting_actions):
1727
1728 # remove all conflicting options
1729 for option_string, action in conflicting_actions:
1730
1731 # remove the conflicting option
1732 action.option_strings.remove(option_string)
1733 self._option_string_actions.pop(option_string, None)
1734
1735 # if the option now has no option string, remove it from the
1736 # container holding it
1737 if not action.option_strings:
1738 action.container._remove_action(action)
1739
1740 def _check_help(self, action):
1741 if action.help and hasattr(self, "_get_validation_formatter"):

Callers

nothing calls this directly

Calls 3

removeMethod · 0.45
popMethod · 0.45
_remove_actionMethod · 0.45

Tested by

no test coverage detected