File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
neo4j/_async_compat/network Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -274,20 +274,20 @@ async def _handshake(self, resolved_address):
274274 # If no data is returned after a successful select
275275 # response, the server has closed the connection
276276 log .debug ("[#%04X] S: <CLOSE>" , local_port )
277- self .close ()
277+ await self .close ()
278278 raise ServiceUnavailable (
279279 "Connection to {address} closed without handshake response" .format (
280280 address = resolved_address ))
281281 if data_size != 4 :
282282 # Some garbled data has been received
283283 log .debug ("[#%04X] S: @*#!" , local_port )
284- self .close ()
284+ await self .close ()
285285 raise BoltProtocolError (
286286 "Expected four byte Bolt handshake response from %r, received %r instead; check for incorrect port number" % (
287287 resolved_address , data ), address = resolved_address )
288288 elif data == b"HTTP" :
289289 log .debug ("[#%04X] S: <CLOSE>" , local_port )
290- self .close ()
290+ await self .close ()
291291 raise ServiceUnavailable (
292292 "Cannot to connect to Bolt service on {!r} "
293293 "(looks like HTTP)" .format (resolved_address ))
You can’t perform that action at this time.
0 commit comments