Update _core.py

Was recving the close frame from the websocket