mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
fix ruff cases UP024,UP041 (#11391)
* fix ruff cases UP024,UP041 * add changelog frag
This commit is contained in:
@@ -312,7 +312,6 @@ import io
|
||||
import os
|
||||
import pathlib
|
||||
import shlex
|
||||
import socket
|
||||
import tempfile
|
||||
import traceback
|
||||
import typing as t
|
||||
@@ -667,7 +666,7 @@ class Connection(ConnectionBase):
|
||||
elif in_data == b"":
|
||||
chan.shutdown_write()
|
||||
|
||||
except socket.timeout as e:
|
||||
except TimeoutError as e:
|
||||
raise AnsibleError(f"ssh timed out waiting for privilege escalation.\n{to_text(become_output)}") from e
|
||||
|
||||
stdout = b"".join(chan.makefile("rb", bufsize))
|
||||
|
||||
Reference in New Issue
Block a user