MCPcopy Create free account
hub / github.com/python-cmd2/cmd2 / remove_settable

Method remove_settable

cmd2/cmd2.py:1283–1292  ·  view source on GitHub ↗

Remove a settable parameter from ``self.settables``. :param name: name of the settable being removed :raises KeyError: if the Settable matches this name

(self, name: str)

Source from the content-addressed store, hash-verified

1281 self._settables[settable.name] = settable
1282
1283 def remove_settable(self, name: str) -> None:
1284 """Remove a settable parameter from ``self.settables``.
1285
1286 :param name: name of the settable being removed
1287 :raises KeyError: if the Settable matches this name
1288 """
1289 try:
1290 del self._settables[name]
1291 except KeyError as exc:
1292 raise KeyError(name + " is not a settable parameter") from exc
1293
1294 def build_settables(self) -> None:
1295 """Create the dictionary of user-settable parameters."""

Callers 4

test_debug_not_settableFunction · 0.45
__init__Method · 0.45

Calls

no outgoing calls

Tested by 3

test_debug_not_settableFunction · 0.36