Skip to content

Commit 8e3d39b

Browse files
kushalbakshiclaude
andcommitted
style: fix line length in Connection.__repr__
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 78a94fb commit 8e3d39b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/datajoint/connection.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,9 +234,12 @@ def __eq__(self, other):
234234

235235
def __repr__(self):
236236
connected = "connected" if self.is_connected else "disconnected"
237+
user = self.conn_info["user"]
238+
host = self.conn_info["host"]
239+
port = self.conn_info["port"]
237240
db = self.conn_info.get("database_name")
238241
db_str = f"/{db}" if db else ""
239-
return f"DataJoint connection ({connected}) {self.conn_info['user']}@{self.conn_info['host']}:{self.conn_info['port']}{db_str}"
242+
return f"DataJoint connection ({connected}) {user}@{host}:{port}{db_str}"
240243

241244
def _build_connect_kwargs(self, use_tls=None):
242245
"""Build kwargs dict for adapter.connect()."""

0 commit comments

Comments
 (0)