MCPcopy Create free account
hub / github.com/PyMySQL/PyMySQL / _read_ok_packet

Method _read_ok_packet

pymysql/connections.py:476–485  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

474 return bool(self.server_status & SERVER_STATUS.SERVER_STATUS_AUTOCOMMIT)
475
476 def _read_ok_packet(self):
477 pkt = self._read_packet()
478 if not pkt.is_ok_packet():
479 raise err.OperationalError(
480 CR.CR_COMMANDS_OUT_OF_SYNC,
481 "Command Out of Sync",
482 )
483 ok = OKPacketWrapper(pkt)
484 self.server_status = ok.server_status
485 return ok
486
487 def _send_autocommit_mode(self):
488 """Set whether or not to commit after every execute()."""

Callers 6

_send_autocommit_modeMethod · 0.95
beginMethod · 0.95
commitMethod · 0.95
rollbackMethod · 0.95
select_dbMethod · 0.95
pingMethod · 0.95

Calls 3

_read_packetMethod · 0.95
OKPacketWrapperClass · 0.85
is_ok_packetMethod · 0.80

Tested by

no test coverage detected