-
-
Notifications
You must be signed in to change notification settings - Fork 30.9k
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
Replace 'default' with 'main' as default in sys.version #89695
Comments
sys.version returns '3.10.0 (default, Oct 5 2021, 23:49:26) [GCC 10.2.1 20210110]' 'default' is supposed to represent the name of the branch, and it's been there since the HG days: cpython/Modules/getbuildinfo.c Line 44 in fc64c35
When the code was updated for Git in bpo-27593, the default remained the same: cpython/Modules/getbuildinfo.c Line 44 in bb3e0c2
The default should be updated to 'main'. Note that _Py_gitidentifier is supposed to return meaningful values while building from within a git checkout -- when it fails to do so the default value is used. This can also be tested through sys._git (which returns ('CPython', '', '')), but at the moment I can't build from a git checkout and verify that _Py_gitidentifier returns the correct branch. If not, a separate issue should be created. |
+1 |
Do you want to take a look? |
Thanks! I will look in it |
'3.11.0a1+ (heads/main:3163e68c34, Oct 20 2021, 18:39:18) [Clang 12.0.0 (clang-1200.0.32.29)] FYI, it retrieves branch information well |
Thank you Ezio and youknowone :) |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: