| 1926 | collection.remove_with_event(value, initiator) |
| 1927 | |
| 1928 | def pop( |
| 1929 | self, |
| 1930 | state: InstanceState[Any], |
| 1931 | dict_: _InstanceDict, |
| 1932 | value: Any, |
| 1933 | initiator: Optional[AttributeEventToken], |
| 1934 | passive: PassiveFlag = PASSIVE_OFF, |
| 1935 | ) -> None: |
| 1936 | try: |
| 1937 | # TODO: better solution here would be to add |
| 1938 | # a "popper" role to collections.py to complement |
| 1939 | # "remover". |
| 1940 | self.remove(state, dict_, value, initiator, passive=passive) |
| 1941 | except (ValueError, KeyError, IndexError): |
| 1942 | pass |
| 1943 | |
| 1944 | def set( |
| 1945 | self, |