This is an archive of the discontinued LLVM Phabricator instance.

[libcxx] Support Python 3.8 in the test suite
ClosedPublic

Authored by broadwaylamb on Jan 10 2020, 4:54 AM.

Details

Summary

platform.linux_distribution() has been deprecated in Python 3.5 and removed in Python 3.8.

Event Timeline

broadwaylamb created this revision.Jan 10 2020, 4:54 AM

Could anyone verify this patch, please?

jroelofs accepted this revision.Jan 21 2020, 7:01 AM

Either way, LGTM.

libcxx/utils/libcxx/test/target_info.py
216

Did you consider using this instead? One downside is that it brings in one more dependency.

import distro
return distro.linux_distribution(full_distribution_name=False)
This revision is now accepted and ready to land.Jan 21 2020, 7:01 AM
broadwaylamb marked an inline comment as done.Jan 21 2020, 7:13 AM
broadwaylamb added inline comments.
libcxx/utils/libcxx/test/target_info.py
216

I did, but as far as I understand, the community doesn't really want any dependencies.

I've also been answered on the mailing lists that bringing it it wouldn't really worth it.

This revision was automatically updated to reflect the committed changes.
mgorny added a subscriber: mgorny.Feb 14 2020, 2:23 AM

@broadwaylamb, I've requested backporting this to 10.x: https://bugs.llvm.org/show_bug.cgi?id=44905. However, i wasn't able to find to find you on Bugzilla and CC you. Could you confirm whether it's fine to backport, please?

@broadwaylamb, I've requested backporting this to 10.x: https://bugs.llvm.org/show_bug.cgi?id=44905. However, i wasn't able to find to find you on Bugzilla and CC you. Could you confirm whether it's fine to backport, please?

I don't see any reason for not backporting it, so I guess it's fine by me.