'What are the potential results for platform.system()

What are the possible return values from the following command?

import platform
print platform.system()

I've seen the SO question here, which is not the same question. And I've looked at the docs here but they only list: 'Linux', 'Windows', or 'Java'. What else is there? Do macs return "Mac"?



Solution 1:[1]

platform.system() retrieves its information from the uname system call if available, or synthesizes a result if uname is not available. That means that there is no fixed set of possible returns—it gets it directly from the operating system, and the operating system can return whatever it wants there. For what it’s worth, Mac OS X will return Darwin. (If you’re interested, check the source.)

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 darthbith