def _receive_settings_frame(self, frame):
        events = self.state_machine.process_input(
            ConnectionInputs.RECV_SETTINGS
        )

        # This is an ack of the local settings.
        if 'ACK' in frame.flags:
            changed_settings = self._local_settings_acked()
            ack_event = SettingsAcknowledged()
            ack_event.changed_settings = changed_settings
            events.append(ack_event)
            return [], events

        # Add the new settings.
        self.remote_settings.update(frame.settings)
        events.append(
            RemoteSettingsChanged.from_settings(
                self.remote_settings, frame.settings
            )
        )
        frames = self._acknowledge_settings()

        return frames, events
:param etype: exit type
dataset/ETHPy150Open python-hyper/hyper-h2/h2/connection.py/H2Connection._receive_settings_frame--crossover with--dataset/ETHPy150Open andycasey/ads/ads/tests/mocks.py/HTTPrettyMock.__exit__