mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-19 18:31:14 +08:00
Support named attributes in os.uname() result (#1445)
`os.uname` changed in version 3.3: Return type changed from a tuple to a tuple-like object with named attributes.
This commit is contained in:
committed by
Jelle Zijlstra
parent
bc9b2f0d4d
commit
683c6e90a0
@@ -2,5 +2,11 @@
|
||||
|
||||
# NOTE: These are incomplete!
|
||||
|
||||
import sys
|
||||
import typing
|
||||
from os import stat_result
|
||||
from typing import NamedTuple
|
||||
|
||||
if sys.version_info >= (3, 3):
|
||||
uname_result = NamedTuple('uname_result', [('sysname', str), ('nodename', str),
|
||||
('release', str), ('version', str), ('machine', str)])
|
||||
|
||||
Reference in New Issue
Block a user