diff --git a/.gitignore b/.gitignore index 236fc37..86e9a68 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,5 @@ __pycache__ /.tox /build /pymysql/tests/databases.json + +/.idea diff --git a/pymysql/connections.py b/pymysql/connections.py index 3ab1082..d7d3644 100644 --- a/pymysql/connections.py +++ b/pymysql/connections.py @@ -1267,6 +1267,9 @@ class Connection(object): class MySQLResult(object): def __init__(self, connection): + """ + :type connection: Connection + """ self.connection = connection self.affected_rows = None self.insert_id = None @@ -1294,7 +1297,7 @@ class MySQLResult(object): else: self._read_result_packet(first_packet) finally: - self.connection = False + self.connection = None def init_unbuffered_query(self): self.unbuffered_active = True