Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FreeBSD is missing in pyTooling/Common/Platform.py #84

Closed
yurivict opened this issue Feb 23, 2023 · 6 comments
Closed

FreeBSD is missing in pyTooling/Common/Platform.py #84

yurivict opened this issue Feb 23, 2023 · 6 comments
Labels
Enhancement New feature or request Platform pyTooling.Common.Platform - Detecting current platform.

Comments

@yurivict
Copy link

No description provided.

@Paebbels
Copy link
Member

@yurivict this issue has no description ...


Can you provide the values for Python's internal APIs for platform, architecture, etc.?

This article https://stackoverflow.com/questions/1854/how-to-identify-which-os-python-is-running-on/54837707#54837707 doesn't cover FreeBSD.

import os
import sys
import platform
import sysconfig

print("os.name                      ",  os.name)
print("sys.platform                 ",  sys.platform)
print("platform.system()            ",  platform.system())
print("sysconfig.get_platform()     ",  sysconfig.get_platform())
print("platform.machine()           ",  platform.machine())
print("platform.architecture()      ",  platform.architecture())

@Paebbels Paebbels added Platform pyTooling.Common.Platform - Detecting current platform. Enhancement New feature or request labels Feb 23, 2023
@yurivict
Copy link
Author

$ python3.9 x.py
os.name                       posix
sys.platform                  freebsd13
platform.system()             FreeBSD
sysconfig.get_platform()      freebsd-13.1-STABLE-amd64
platform.machine()            amd64
platform.architecture()       ('64bit', 'ELF')

@Paebbels
Copy link
Member

Thanks.

I assume freebsd13 is the OS name on one side, but also a version number, right? Is it more like a category number like Windows 7, 10, 11 with several sub versions. Or a real version like Debian 11 or Ubuntu 2023.04?

If I remember correctly, macOS is also part of the BSD family. Or do you consider FreeBSD (and maybe any other BSD) been far a way from macOS? My question is: should Platform reflect the common root to the old days of BSD?

Are there other BSD variants it should reflect too?

@yurivict
Copy link
Author

freebsd13 is OS name concatenated with OS version number.

If I remember correctly, macOS is also part of the BSD family. Or do you consider FreeBSD (and maybe any other BSD) been far a way from macOS? My question is: should Platform reflect the common root to the old days of BSD?

They are very far away these days. macOS should be in a separate category.

Are there other BSD variants it should reflect too?

The other variants are OpenBSD and NetBSD. But I don't know what are these identified as in Python - I have no access to these systems.

@Paebbels Paebbels mentioned this issue Feb 23, 2023
@Paebbels
Copy link
Member

This is addressed in #85.

I have no option in checking it. Should I just release or do you want to try it locally on your machine?

@Paebbels
Copy link
Member

It's merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New feature or request Platform pyTooling.Common.Platform - Detecting current platform.
Projects
None yet
Development

No branches or pull requests

2 participants