Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix python sys.platform check for Linux (elastic#15727)
On Linux, sys.platform doesn’t contain the major version anymore. It is now always ‘linux’, instead of ‘linux2’ or ‘linux3’ depending on the Linux version used to build Python. Replace sys.platform == ‘linux2’ with sys.platform.startswith(‘linux’), or directly sys.platform == ‘linux’ if you don’t need to support older Python versions. Ref: https://docs.python.org/3.3/whatsnew/3.3.html#porting-python-code
- Loading branch information