diff options
author | Ian Wienand <iwienand@redhat.com> | 2022-08-15 08:34:13 +1000 |
---|---|---|
committer | Ian Wienand <iwienand@redhat.com> | 2022-08-15 08:37:04 +1000 |
commit | 3037ce79a1d33595e3a6d72fe22eba027deba2ea (patch) | |
tree | 1be66e88f49a0a2d41c92f0d7165db8307f0bf4d | |
parent | 73a7d9c1459468298ca22b4ad8096893669c71ec (diff) | |
download | zuul-3037ce79a1d33595e3a6d72fe22eba027deba2ea.tar.gz |
zuul_console: do not use f-strings
In Ief366c092e05fb88351782f6d9cd280bfae96237 I missed that this runs
in the context of the remote node; meaning that it must support all
the Python versions that might run there. f-strings are not 3.5
compatible.
I'm thinking about how to lint this better (a syntax check run?)
Change-Id: Ia4133b061800791196cd631f2e6836cb77347664
-rwxr-xr-x | zuul/ansible/base/library/zuul_console.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/zuul/ansible/base/library/zuul_console.py b/zuul/ansible/base/library/zuul_console.py index bd23d5f49..bc35e47db 100755 --- a/zuul/ansible/base/library/zuul_console.py +++ b/zuul/ansible/base/library/zuul_console.py @@ -185,7 +185,8 @@ class Server(object): # NOTE(ianw) : remote sends its version. We currently # don't have anything to do with this value, so ignore # for now. - conn.send(f'{ZUUL_CONSOLE_PROTO_VERSION}\n'.encode('utf-8')) + cmd = '%s\n' % (ZUUL_CONSOLE_PROTO_VERSION) + conn.send(cmd.encode('utf-8')) continue elif command.startswith('s:'): log_uuid = command[2:] |