Closed tchaikov closed 3 months ago
@tchaikov It seems that this change is breaking tests. please check it as well https://github.com/scylladb/scylla-machine-image/actions/runs/8447372797/job/23137618753?pr=514
@tchaikov It seems that this change is breaking tests. please check it as well https://github.com/scylladb/scylla-machine-image/actions/runs/8447372797/job/23137618753?pr=514
it does. so we are testing w/ python 3.8.18
, while functools.cache
was introduced in 3.9! see https://docs.python.org/3/library/functools.html#functools.cache
@fruch hi Israel, do we need to support python 3.8? on RHEL8 python 3.6 is the default. so we are not likely to be stuck with RHEL8. in RHEL9, Python 3.9 is the default. Fedora 38, 3.11. ubuntu 22.04 3.10. but yeah, ubuntu 20.04, 3.8. so are we trying to be compatible with ubuntu 20.04?
@fruch hi Israel, do we need to support python 3.8? on RHEL8 python 3.6 is the default. so we are not likely to be stuck with RHEL8. in RHEL9, Python 3.9 is the default. Fedora 38, 3.11. ubuntu 22.04 3.10. but yeah, ubuntu 20.04, 3.8. so are we trying to be compatible with ubuntu 20.04?
None of the above, we are using our own python version from scylla-python3, and currently on master it's 3.11 (if I remember correctly)
@fruch thanks for confirmation. lemme bump the github workflow to use Python 3.11 then. that should match with the version we use in production.
pending on #515
@fruch good to merge?
@fruch good to merge?
I think yes
but leave it to @yaronkaikov to take it further (and if needed backport or not)
ack. it's more of a cleanup. so IMHO, no need to backport.
this change is a follow-up of d97e311130, which caches the result of
identify_cloud_async()
using a global variable. it would be more idiomatic to usefunctool.cache
for caching a costy function likeidentify_cloud_async()
, so in this change we use it for caching. simpler this way. and more importantly, it is more readable.