Commit Graph

10 Commits

Author SHA1 Message Date
Shantanu
6ff5b88ca7 typeshed: remove crufty comments (#4699)
Co-authored-by: hauntsaninja <>
2020-10-23 09:40:06 +02:00
Shantanu
f23ce60668 stubtest: fix on windows (#4455)
Co-authored-by: Akuli
2020-08-17 14:55:58 -07:00
Jelle Zijlstra
5d553c9584 apply black and isort (#4287)
* apply black and isort

* move some type ignores
2020-06-28 13:31:00 -07:00
Milap Sheth
14af8790f3 Added missing properties to struct_time (#4256) 2020-06-22 20:43:53 -07:00
Rune Tynan
d310a16e7c Fix stubtest failures for time on windows (#4104) 2020-05-27 09:51:37 +02:00
Sebastian Rittau
ec7960a8cb Convert namedtuples to class syntax (#3321) 2019-10-20 10:37:33 +02:00
Sebastian Rittau
0501e2b329 Annotations for remaining Python 3.8 additions (#3358)
* Add os.add_dll_directory()
* Add memfd_create() and flags
* Add type annotation to flags
* Add stat_result.st_reparse_tag and flags
* Add ncurses_version
* Add Path.link_to()
* Add Picker.reducer_override()
* Add plistlib.UID
* Add has_dualstack_ipv6() and create_server()
* Add shlex.join()
* Add SSL methods and fields
* Add Python 3.8 statistics functions and classes
* Remove obsolete sys.subversion
* Add sys.unraisablehook
* Add threading.excepthook
* Add get_native_id() and Thread.native_id
* Add Python 3.8 tkinter methods
* Add CLOCK_UPTIME_RAW
* Add SupportsIndex
* Add typing.get_origin() and get_args()
* Add unicodedata.is_normalized
* Add unittest.mock.AsyncMock

Currently this is just an alias for Any like Mock and MagicMock. All of
these classes should probably be sub-classing Any and add their own
methods. See also #3224.

* Add unittest cleanup methods
* Add IsolatedAsyncioTestCase
* Add ElementTree.canonicalize() and C14NWriterTarget
* cProfile.Profile can be used as a context manager
* Add asyncio task name handling
* mmap.flush() now always returns None
* Add posonlyargcount to CodeType
2019-10-14 09:53:48 +02:00
Sebastian Rittau
6507875f28 Annotate Python 3.8 removals (#3359)
* macpath
* time.clock()
* Some cgi functions
* XMLParser(html) and doctype()
* unicode_internal
* Two sqlite3 classes hidden
* fileinput bufsize arg
* Treeview.selection no longer takes arguments
2019-10-14 09:51:39 +02:00
Jelle Zijlstra
7cfbc7d17f more 3.7 features (#2015) 2018-04-06 11:09:11 -07:00
Sebastian Rittau
38aea73b4b Merge Python 2 and 3 versions of time.pyi (#1909)
* Use variable annotations
* Replace default values by ellipses
* Remove exceptions from function bodies
* Remove superfluous comments
* Remove superfluous newlines
* Use Optional instead of Union[..., None]
* Replace Union[int, float] by just float

* Make time.pyi (Python 2) more closely resemble the Python 3 stub

* Replace _TIME_TUPLE by TimeTuple
* Reorder imports

* time.pyi: Mark two arguments as optional, mark Unix-only function

* time.pyi (Python 2): Use TimeTuple in NamedTuple and reformat

This makes time.pyi more closely match the Python3 version.

* Merge Python 2 and 3 versions of time.pyi

* Only import SimpleNamespace on Python >= 3.3

* Remove default values from module properties

* Remove Optional from strftime() and asctime()

* accept2dyear was removed in Python 3.3

* Rename TimeTuple to _TimeTuple
2018-02-24 11:49:37 -08:00