python platform.uname() - win11 的奇怪结果

发布于 01-16 19:50 字数 415 浏览 2 评论 0 原文

我期望当我运行 platform.uname() 时我会收到release == 11,但它是10。

有人能告诉我为什么吗?

其中,节点到底是什么?

在 win 11 中,python 3.7 执行:

import platform
x = platform.uname()

x == (
  system='Windows',
  node='w11fi',   # what is a node?
  release='10',   # Supposed to be 11?
  version='10.0.22000',
  machine='AMD64',
  processor='Intel64 Family 6 Model 94 Stepping 3, GenuineIntel')

I would expect when I run platform.uname() I would recieve release == 11, but it is 10.

Can someone tell, why?

within that, what actually is a node?

with win 11, python 3.7 executing:

import platform
x = platform.uname()

x == (
  system='Windows',
  node='w11fi',   # what is a node?
  release='10',   # Supposed to be 11?
  version='10.0.22000',
  machine='AMD64',
  processor='Intel64 Family 6 Model 94 Stepping 3, GenuineIntel')

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

过度放纵 2025-01-23 19:50:19

这很令人困惑,但是,根据 此评论 和 "="">此列表,什么你看到的是正确的:

Windows 11 的主要版本和次要版本是 10.0。 Windows 11 的内部版本号为 22000 及以上。

以下 cpython 问题中有更多详细信息:

It's confusing, but, according to this comment and this list, what you're seeing is correct:

The major.minor version of Windows 11 is 10.0. The build number for Windows 11 is 22000 and above.

Much more detail in the following cpython issues:

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文