basedpyright 1.1.389 → 1.1.392

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (679) hide show
  1. package/README.md +3 -3
  2. package/dist/pyright-langserver.js +1 -1
  3. package/dist/pyright-langserver.js.LICENSE.txt +42 -0
  4. package/dist/pyright-langserver.js.map +1 -1
  5. package/dist/pyright.js +1 -1
  6. package/dist/pyright.js.map +1 -1
  7. package/dist/typeshed-fallback/commit.txt +1 -1
  8. package/dist/typeshed-fallback/stdlib/VERSIONS +9 -0
  9. package/dist/typeshed-fallback/stdlib/__future__.pyi +36 -36
  10. package/dist/typeshed-fallback/stdlib/__main__.pyi +3 -3
  11. package/dist/typeshed-fallback/stdlib/_ast.pyi +149 -149
  12. package/dist/typeshed-fallback/stdlib/_asyncio.pyi +320 -342
  13. package/dist/typeshed-fallback/stdlib/_bisect.pyi +189 -229
  14. package/dist/typeshed-fallback/stdlib/_blake2.pyi +137 -137
  15. package/dist/typeshed-fallback/stdlib/_bootlocale.pyi +1 -1
  16. package/dist/typeshed-fallback/stdlib/_bz2.pyi +71 -71
  17. package/dist/typeshed-fallback/stdlib/_codecs.pyi +247 -244
  18. package/dist/typeshed-fallback/stdlib/_collections_abc.pyi +124 -115
  19. package/dist/typeshed-fallback/stdlib/_compat_pickle.pyi +8 -8
  20. package/dist/typeshed-fallback/stdlib/_compression.pyi +25 -25
  21. package/dist/typeshed-fallback/stdlib/_contextvars.pyi +146 -146
  22. package/dist/typeshed-fallback/stdlib/_csv.pyi +232 -172
  23. package/dist/typeshed-fallback/stdlib/_ctypes.pyi +435 -304
  24. package/dist/typeshed-fallback/stdlib/_curses.pyi +2 -6
  25. package/dist/typeshed-fallback/stdlib/_curses_panel.pyi +67 -0
  26. package/dist/typeshed-fallback/stdlib/_dbm.pyi +8 -19
  27. package/dist/typeshed-fallback/stdlib/_decimal.pyi +80 -94
  28. package/dist/typeshed-fallback/stdlib/_dummy_thread.pyi +33 -33
  29. package/dist/typeshed-fallback/stdlib/_dummy_threading.pyi +164 -180
  30. package/dist/typeshed-fallback/stdlib/_frozen_importlib.pyi +114 -114
  31. package/dist/typeshed-fallback/stdlib/_frozen_importlib_external.pyi +178 -178
  32. package/dist/typeshed-fallback/stdlib/_gdbm.pyi +2 -65
  33. package/dist/typeshed-fallback/stdlib/_hashlib.pyi +232 -0
  34. package/dist/typeshed-fallback/stdlib/_heapq.pyi +67 -67
  35. package/dist/typeshed-fallback/stdlib/_imp.pyi +81 -83
  36. package/dist/typeshed-fallback/stdlib/_io.pyi +719 -719
  37. package/dist/typeshed-fallback/stdlib/_json.pyi +99 -92
  38. package/dist/typeshed-fallback/stdlib/_locale.pyi +155 -155
  39. package/dist/typeshed-fallback/stdlib/_lsprof.pyi +94 -94
  40. package/dist/typeshed-fallback/stdlib/_lzma.pyi +158 -158
  41. package/dist/typeshed-fallback/stdlib/_markupbase.pyi +16 -16
  42. package/dist/typeshed-fallback/stdlib/_msi.pyi +92 -94
  43. package/dist/typeshed-fallback/stdlib/_multibytecodec.pyi +44 -0
  44. package/dist/typeshed-fallback/stdlib/_operator.pyi +261 -261
  45. package/dist/typeshed-fallback/stdlib/_osx_support.pyi +34 -34
  46. package/dist/typeshed-fallback/stdlib/_posixsubprocess.pyi +0 -1
  47. package/dist/typeshed-fallback/stdlib/_py_abc.pyi +14 -14
  48. package/dist/typeshed-fallback/stdlib/_pydecimal.pyi +43 -43
  49. package/dist/typeshed-fallback/stdlib/_queue.pyi +67 -67
  50. package/dist/typeshed-fallback/stdlib/_random.pyi +30 -30
  51. package/dist/typeshed-fallback/stdlib/_sitebuiltins.pyi +16 -16
  52. package/dist/typeshed-fallback/stdlib/_socket.pyi +1367 -1317
  53. package/dist/typeshed-fallback/stdlib/_sqlite3.pyi +360 -402
  54. package/dist/typeshed-fallback/stdlib/_ssl.pyi +399 -406
  55. package/dist/typeshed-fallback/stdlib/_stat.pyi +257 -257
  56. package/dist/typeshed-fallback/stdlib/_struct.pyi +147 -147
  57. package/dist/typeshed-fallback/stdlib/_thread.pyi +266 -257
  58. package/dist/typeshed-fallback/stdlib/_threading_local.pyi +22 -18
  59. package/dist/typeshed-fallback/stdlib/_tkinter.pyi +165 -165
  60. package/dist/typeshed-fallback/stdlib/_tracemalloc.pyi +78 -78
  61. package/dist/typeshed-fallback/stdlib/_warnings.pyi +98 -102
  62. package/dist/typeshed-fallback/stdlib/_weakref.pyi +35 -35
  63. package/dist/typeshed-fallback/stdlib/_weakrefset.pyi +57 -57
  64. package/dist/typeshed-fallback/stdlib/abc.pyi +59 -59
  65. package/dist/typeshed-fallback/stdlib/argparse.pyi +769 -769
  66. package/dist/typeshed-fallback/stdlib/array.pyi +267 -281
  67. package/dist/typeshed-fallback/stdlib/ast.pyi +2049 -2049
  68. package/dist/typeshed-fallback/stdlib/asynchat.pyi +21 -21
  69. package/dist/typeshed-fallback/stdlib/asyncio/__init__.pyi +41 -41
  70. package/dist/typeshed-fallback/stdlib/asyncio/base_events.pyi +488 -488
  71. package/dist/typeshed-fallback/stdlib/asyncio/base_futures.pyi +19 -19
  72. package/dist/typeshed-fallback/stdlib/asyncio/base_subprocess.pyi +63 -63
  73. package/dist/typeshed-fallback/stdlib/asyncio/base_tasks.pyi +9 -9
  74. package/dist/typeshed-fallback/stdlib/asyncio/constants.pyi +20 -20
  75. package/dist/typeshed-fallback/stdlib/asyncio/coroutines.pyi +26 -26
  76. package/dist/typeshed-fallback/stdlib/asyncio/events.pyi +653 -653
  77. package/dist/typeshed-fallback/stdlib/asyncio/exceptions.pyi +43 -43
  78. package/dist/typeshed-fallback/stdlib/asyncio/format_helpers.pyi +31 -31
  79. package/dist/typeshed-fallback/stdlib/asyncio/futures.pyi +16 -16
  80. package/dist/typeshed-fallback/stdlib/asyncio/locks.pyi +127 -127
  81. package/dist/typeshed-fallback/stdlib/asyncio/log.pyi +3 -3
  82. package/dist/typeshed-fallback/stdlib/asyncio/mixins.pyi +9 -9
  83. package/dist/typeshed-fallback/stdlib/asyncio/proactor_events.pyi +64 -64
  84. package/dist/typeshed-fallback/stdlib/asyncio/protocols.pyi +34 -34
  85. package/dist/typeshed-fallback/stdlib/asyncio/queues.pyi +64 -64
  86. package/dist/typeshed-fallback/stdlib/asyncio/runners.pyi +32 -32
  87. package/dist/typeshed-fallback/stdlib/asyncio/selector_events.pyi +8 -8
  88. package/dist/typeshed-fallback/stdlib/asyncio/sslproto.pyi +165 -184
  89. package/dist/typeshed-fallback/stdlib/asyncio/staggered.pyi +10 -10
  90. package/dist/typeshed-fallback/stdlib/asyncio/streams.pyi +157 -157
  91. package/dist/typeshed-fallback/stdlib/asyncio/subprocess.pyi +229 -229
  92. package/dist/typeshed-fallback/stdlib/asyncio/taskgroups.pyi +25 -25
  93. package/dist/typeshed-fallback/stdlib/asyncio/tasks.pyi +459 -459
  94. package/dist/typeshed-fallback/stdlib/asyncio/threads.pyi +9 -9
  95. package/dist/typeshed-fallback/stdlib/asyncio/timeouts.pyi +19 -19
  96. package/dist/typeshed-fallback/stdlib/asyncio/transports.pyi +47 -47
  97. package/dist/typeshed-fallback/stdlib/asyncio/trsock.pyi +94 -94
  98. package/dist/typeshed-fallback/stdlib/asyncore.pyi +90 -90
  99. package/dist/typeshed-fallback/stdlib/atexit.pyi +46 -46
  100. package/dist/typeshed-fallback/stdlib/audioop.pyi +26 -78
  101. package/dist/typeshed-fallback/stdlib/base64.pyi +65 -65
  102. package/dist/typeshed-fallback/stdlib/bdb.pyi +114 -114
  103. package/dist/typeshed-fallback/stdlib/binascii.pyi +113 -123
  104. package/dist/typeshed-fallback/stdlib/binhex.pyi +45 -45
  105. package/dist/typeshed-fallback/stdlib/bisect.pyi +4 -4
  106. package/dist/typeshed-fallback/stdlib/builtins.pyi +6481 -6560
  107. package/dist/typeshed-fallback/stdlib/bz2.pyi +132 -131
  108. package/dist/typeshed-fallback/stdlib/cProfile.pyi +31 -31
  109. package/dist/typeshed-fallback/stdlib/calendar.pyi +208 -208
  110. package/dist/typeshed-fallback/stdlib/cmath.pyi +112 -112
  111. package/dist/typeshed-fallback/stdlib/cmd.pyi +46 -46
  112. package/dist/typeshed-fallback/stdlib/code.pyi +56 -56
  113. package/dist/typeshed-fallback/stdlib/codecs.pyi +301 -297
  114. package/dist/typeshed-fallback/stdlib/codeop.pyi +13 -13
  115. package/dist/typeshed-fallback/stdlib/collections/__init__.pyi +650 -650
  116. package/dist/typeshed-fallback/stdlib/collections/abc.pyi +2 -2
  117. package/dist/typeshed-fallback/stdlib/colorsys.pyi +13 -13
  118. package/dist/typeshed-fallback/stdlib/compileall.pyi +111 -111
  119. package/dist/typeshed-fallback/stdlib/concurrent/futures/__init__.pyi +51 -51
  120. package/dist/typeshed-fallback/stdlib/concurrent/futures/_base.pyi +132 -132
  121. package/dist/typeshed-fallback/stdlib/concurrent/futures/process.pyi +234 -234
  122. package/dist/typeshed-fallback/stdlib/concurrent/futures/thread.pyi +86 -86
  123. package/dist/typeshed-fallback/stdlib/configparser.pyi +412 -404
  124. package/dist/typeshed-fallback/stdlib/contextlib.pyi +219 -213
  125. package/dist/typeshed-fallback/stdlib/contextvars.pyi +3 -3
  126. package/dist/typeshed-fallback/stdlib/copy.pyi +27 -27
  127. package/dist/typeshed-fallback/stdlib/copyreg.pyi +21 -21
  128. package/dist/typeshed-fallback/stdlib/crypt.pyi +9 -2
  129. package/dist/typeshed-fallback/stdlib/csv.pyi +169 -167
  130. package/dist/typeshed-fallback/stdlib/ctypes/__init__.pyi +218 -198
  131. package/dist/typeshed-fallback/stdlib/ctypes/_endian.pyi +16 -16
  132. package/dist/typeshed-fallback/stdlib/ctypes/macholib/__init__.pyi +1 -0
  133. package/dist/typeshed-fallback/stdlib/ctypes/macholib/dyld.pyi +8 -0
  134. package/dist/typeshed-fallback/stdlib/ctypes/macholib/dylib.pyi +14 -0
  135. package/dist/typeshed-fallback/stdlib/ctypes/macholib/framework.pyi +14 -0
  136. package/dist/typeshed-fallback/stdlib/ctypes/util.pyi +8 -6
  137. package/dist/typeshed-fallback/stdlib/ctypes/wintypes.pyi +304 -298
  138. package/dist/typeshed-fallback/stdlib/curses/__init__.pyi +19 -1
  139. package/dist/typeshed-fallback/stdlib/curses/panel.pyi +1 -34
  140. package/dist/typeshed-fallback/stdlib/dataclasses.pyi +322 -322
  141. package/dist/typeshed-fallback/stdlib/datetime.pyi +576 -575
  142. package/dist/typeshed-fallback/stdlib/dbm/__init__.pyi +104 -102
  143. package/dist/typeshed-fallback/stdlib/dbm/dumb.pyi +37 -37
  144. package/dist/typeshed-fallback/stdlib/decimal.pyi +849 -840
  145. package/dist/typeshed-fallback/stdlib/difflib.pyi +146 -146
  146. package/dist/typeshed-fallback/stdlib/dis.pyi +248 -248
  147. package/dist/typeshed-fallback/stdlib/distutils/__init__.pyi +5 -5
  148. package/dist/typeshed-fallback/stdlib/distutils/_msvccompiler.pyi +13 -13
  149. package/dist/typeshed-fallback/stdlib/distutils/archive_util.pyi +35 -35
  150. package/dist/typeshed-fallback/stdlib/distutils/bcppcompiler.pyi +3 -3
  151. package/dist/typeshed-fallback/stdlib/distutils/ccompiler.pyi +176 -176
  152. package/dist/typeshed-fallback/stdlib/distutils/cmd.pyi +229 -229
  153. package/dist/typeshed-fallback/stdlib/distutils/command/__init__.pyi +48 -48
  154. package/dist/typeshed-fallback/stdlib/distutils/command/bdist.pyi +27 -27
  155. package/dist/typeshed-fallback/stdlib/distutils/command/bdist_dumb.pyi +22 -22
  156. package/dist/typeshed-fallback/stdlib/distutils/command/bdist_msi.pyi +46 -46
  157. package/dist/typeshed-fallback/stdlib/distutils/command/bdist_rpm.pyi +53 -53
  158. package/dist/typeshed-fallback/stdlib/distutils/command/bdist_wininst.pyi +16 -16
  159. package/dist/typeshed-fallback/stdlib/distutils/command/build.pyi +34 -34
  160. package/dist/typeshed-fallback/stdlib/distutils/command/build_clib.pyi +29 -29
  161. package/dist/typeshed-fallback/stdlib/distutils/command/build_ext.pyi +52 -52
  162. package/dist/typeshed-fallback/stdlib/distutils/command/build_py.pyi +45 -45
  163. package/dist/typeshed-fallback/stdlib/distutils/command/build_scripts.pyi +25 -25
  164. package/dist/typeshed-fallback/stdlib/distutils/command/check.pyi +40 -40
  165. package/dist/typeshed-fallback/stdlib/distutils/command/clean.pyi +18 -18
  166. package/dist/typeshed-fallback/stdlib/distutils/command/config.pyi +84 -84
  167. package/dist/typeshed-fallback/stdlib/distutils/command/install.pyi +71 -71
  168. package/dist/typeshed-fallback/stdlib/distutils/command/install_data.pyi +20 -20
  169. package/dist/typeshed-fallback/stdlib/distutils/command/install_egg_info.pyi +19 -19
  170. package/dist/typeshed-fallback/stdlib/distutils/command/install_headers.pyi +17 -17
  171. package/dist/typeshed-fallback/stdlib/distutils/command/install_lib.pyi +26 -26
  172. package/dist/typeshed-fallback/stdlib/distutils/command/install_scripts.pyi +19 -19
  173. package/dist/typeshed-fallback/stdlib/distutils/command/register.pyi +21 -21
  174. package/dist/typeshed-fallback/stdlib/distutils/command/sdist.pyi +45 -45
  175. package/dist/typeshed-fallback/stdlib/distutils/command/upload.pyi +18 -18
  176. package/dist/typeshed-fallback/stdlib/distutils/config.pyi +17 -17
  177. package/dist/typeshed-fallback/stdlib/distutils/core.pyi +58 -58
  178. package/dist/typeshed-fallback/stdlib/distutils/cygwinccompiler.pyi +20 -20
  179. package/dist/typeshed-fallback/stdlib/distutils/debug.pyi +3 -3
  180. package/dist/typeshed-fallback/stdlib/distutils/dep_util.pyi +14 -14
  181. package/dist/typeshed-fallback/stdlib/distutils/dir_util.pyi +23 -23
  182. package/dist/typeshed-fallback/stdlib/distutils/dist.pyi +317 -317
  183. package/dist/typeshed-fallback/stdlib/distutils/errors.pyi +19 -19
  184. package/dist/typeshed-fallback/stdlib/distutils/extension.pyi +36 -36
  185. package/dist/typeshed-fallback/stdlib/distutils/fancy_getopt.pyi +34 -34
  186. package/dist/typeshed-fallback/stdlib/distutils/file_util.pyi +38 -38
  187. package/dist/typeshed-fallback/stdlib/distutils/filelist.pyi +58 -58
  188. package/dist/typeshed-fallback/stdlib/distutils/log.pyi +26 -26
  189. package/dist/typeshed-fallback/stdlib/distutils/msvccompiler.pyi +3 -3
  190. package/dist/typeshed-fallback/stdlib/distutils/spawn.pyi +10 -6
  191. package/dist/typeshed-fallback/stdlib/distutils/sysconfig.pyi +33 -33
  192. package/dist/typeshed-fallback/stdlib/distutils/text_file.pyi +21 -21
  193. package/dist/typeshed-fallback/stdlib/distutils/unixccompiler.pyi +3 -3
  194. package/dist/typeshed-fallback/stdlib/distutils/util.pyi +53 -53
  195. package/dist/typeshed-fallback/stdlib/distutils/version.pyi +36 -38
  196. package/dist/typeshed-fallback/stdlib/doctest.pyi +262 -264
  197. package/dist/typeshed-fallback/stdlib/dummy_threading.pyi +2 -2
  198. package/dist/typeshed-fallback/stdlib/email/__init__.pyi +37 -29
  199. package/dist/typeshed-fallback/stdlib/email/_header_value_parser.pyi +398 -398
  200. package/dist/typeshed-fallback/stdlib/email/_policybase.pyi +77 -75
  201. package/dist/typeshed-fallback/stdlib/email/base64mime.pyi +13 -13
  202. package/dist/typeshed-fallback/stdlib/email/charset.pyi +36 -36
  203. package/dist/typeshed-fallback/stdlib/email/contentmanager.pyi +11 -11
  204. package/dist/typeshed-fallback/stdlib/email/encoders.pyi +8 -8
  205. package/dist/typeshed-fallback/stdlib/email/errors.pyi +42 -42
  206. package/dist/typeshed-fallback/stdlib/email/feedparser.pyi +23 -23
  207. package/dist/typeshed-fallback/stdlib/email/generator.pyi +77 -77
  208. package/dist/typeshed-fallback/stdlib/email/header.pyi +33 -33
  209. package/dist/typeshed-fallback/stdlib/email/headerregistry.pyi +183 -183
  210. package/dist/typeshed-fallback/stdlib/email/iterators.pyi +12 -12
  211. package/dist/typeshed-fallback/stdlib/email/message.pyi +172 -172
  212. package/dist/typeshed-fallback/stdlib/email/mime/application.pyi +17 -17
  213. package/dist/typeshed-fallback/stdlib/email/mime/audio.pyi +17 -17
  214. package/dist/typeshed-fallback/stdlib/email/mime/base.pyi +8 -8
  215. package/dist/typeshed-fallback/stdlib/email/mime/image.pyi +17 -17
  216. package/dist/typeshed-fallback/stdlib/email/mime/message.pyi +8 -8
  217. package/dist/typeshed-fallback/stdlib/email/mime/multipart.pyi +18 -18
  218. package/dist/typeshed-fallback/stdlib/email/mime/nonmultipart.pyi +5 -5
  219. package/dist/typeshed-fallback/stdlib/email/mime/text.pyi +9 -9
  220. package/dist/typeshed-fallback/stdlib/email/parser.pyi +38 -38
  221. package/dist/typeshed-fallback/stdlib/email/policy.pyi +77 -77
  222. package/dist/typeshed-fallback/stdlib/email/quoprimime.pyi +28 -28
  223. package/dist/typeshed-fallback/stdlib/email/utils.pyi +78 -78
  224. package/dist/typeshed-fallback/stdlib/encodings/__init__.pyi +10 -10
  225. package/dist/typeshed-fallback/stdlib/encodings/aliases.pyi +1 -0
  226. package/dist/typeshed-fallback/stdlib/encodings/ascii.pyi +30 -0
  227. package/dist/typeshed-fallback/stdlib/encodings/base64_codec.pyi +26 -0
  228. package/dist/typeshed-fallback/stdlib/encodings/big5.pyi +23 -0
  229. package/dist/typeshed-fallback/stdlib/encodings/big5hkscs.pyi +23 -0
  230. package/dist/typeshed-fallback/stdlib/encodings/bz2_codec.pyi +26 -0
  231. package/dist/typeshed-fallback/stdlib/encodings/charmap.pyi +33 -0
  232. package/dist/typeshed-fallback/stdlib/encodings/cp037.pyi +21 -0
  233. package/dist/typeshed-fallback/stdlib/encodings/cp1006.pyi +21 -0
  234. package/dist/typeshed-fallback/stdlib/encodings/cp1026.pyi +21 -0
  235. package/dist/typeshed-fallback/stdlib/encodings/cp1125.pyi +21 -0
  236. package/dist/typeshed-fallback/stdlib/encodings/cp1140.pyi +21 -0
  237. package/dist/typeshed-fallback/stdlib/encodings/cp1250.pyi +21 -0
  238. package/dist/typeshed-fallback/stdlib/encodings/cp1251.pyi +21 -0
  239. package/dist/typeshed-fallback/stdlib/encodings/cp1252.pyi +21 -0
  240. package/dist/typeshed-fallback/stdlib/encodings/cp1253.pyi +21 -0
  241. package/dist/typeshed-fallback/stdlib/encodings/cp1254.pyi +21 -0
  242. package/dist/typeshed-fallback/stdlib/encodings/cp1255.pyi +21 -0
  243. package/dist/typeshed-fallback/stdlib/encodings/cp1256.pyi +21 -0
  244. package/dist/typeshed-fallback/stdlib/encodings/cp1257.pyi +21 -0
  245. package/dist/typeshed-fallback/stdlib/encodings/cp1258.pyi +21 -0
  246. package/dist/typeshed-fallback/stdlib/encodings/cp273.pyi +21 -0
  247. package/dist/typeshed-fallback/stdlib/encodings/cp424.pyi +21 -0
  248. package/dist/typeshed-fallback/stdlib/encodings/cp437.pyi +21 -0
  249. package/dist/typeshed-fallback/stdlib/encodings/cp500.pyi +21 -0
  250. package/dist/typeshed-fallback/stdlib/encodings/cp720.pyi +21 -0
  251. package/dist/typeshed-fallback/stdlib/encodings/cp737.pyi +21 -0
  252. package/dist/typeshed-fallback/stdlib/encodings/cp775.pyi +21 -0
  253. package/dist/typeshed-fallback/stdlib/encodings/cp850.pyi +21 -0
  254. package/dist/typeshed-fallback/stdlib/encodings/cp852.pyi +21 -0
  255. package/dist/typeshed-fallback/stdlib/encodings/cp855.pyi +21 -0
  256. package/dist/typeshed-fallback/stdlib/encodings/cp856.pyi +21 -0
  257. package/dist/typeshed-fallback/stdlib/encodings/cp857.pyi +21 -0
  258. package/dist/typeshed-fallback/stdlib/encodings/cp858.pyi +21 -0
  259. package/dist/typeshed-fallback/stdlib/encodings/cp860.pyi +21 -0
  260. package/dist/typeshed-fallback/stdlib/encodings/cp861.pyi +21 -0
  261. package/dist/typeshed-fallback/stdlib/encodings/cp862.pyi +21 -0
  262. package/dist/typeshed-fallback/stdlib/encodings/cp863.pyi +21 -0
  263. package/dist/typeshed-fallback/stdlib/encodings/cp864.pyi +21 -0
  264. package/dist/typeshed-fallback/stdlib/encodings/cp865.pyi +21 -0
  265. package/dist/typeshed-fallback/stdlib/encodings/cp866.pyi +21 -0
  266. package/dist/typeshed-fallback/stdlib/encodings/cp869.pyi +21 -0
  267. package/dist/typeshed-fallback/stdlib/encodings/cp874.pyi +21 -0
  268. package/dist/typeshed-fallback/stdlib/encodings/cp875.pyi +21 -0
  269. package/dist/typeshed-fallback/stdlib/encodings/cp932.pyi +23 -0
  270. package/dist/typeshed-fallback/stdlib/encodings/cp949.pyi +23 -0
  271. package/dist/typeshed-fallback/stdlib/encodings/cp950.pyi +23 -0
  272. package/dist/typeshed-fallback/stdlib/encodings/euc_jis_2004.pyi +23 -0
  273. package/dist/typeshed-fallback/stdlib/encodings/euc_jisx0213.pyi +23 -0
  274. package/dist/typeshed-fallback/stdlib/encodings/euc_jp.pyi +23 -0
  275. package/dist/typeshed-fallback/stdlib/encodings/euc_kr.pyi +23 -0
  276. package/dist/typeshed-fallback/stdlib/encodings/gb18030.pyi +23 -0
  277. package/dist/typeshed-fallback/stdlib/encodings/gb2312.pyi +23 -0
  278. package/dist/typeshed-fallback/stdlib/encodings/gbk.pyi +23 -0
  279. package/dist/typeshed-fallback/stdlib/encodings/hex_codec.pyi +26 -0
  280. package/dist/typeshed-fallback/stdlib/encodings/hp_roman8.pyi +21 -0
  281. package/dist/typeshed-fallback/stdlib/encodings/hz.pyi +23 -0
  282. package/dist/typeshed-fallback/stdlib/encodings/idna.pyi +26 -0
  283. package/dist/typeshed-fallback/stdlib/encodings/iso2022_jp.pyi +23 -0
  284. package/dist/typeshed-fallback/stdlib/encodings/iso2022_jp_1.pyi +23 -0
  285. package/dist/typeshed-fallback/stdlib/encodings/iso2022_jp_2.pyi +23 -0
  286. package/dist/typeshed-fallback/stdlib/encodings/iso2022_jp_2004.pyi +23 -0
  287. package/dist/typeshed-fallback/stdlib/encodings/iso2022_jp_3.pyi +23 -0
  288. package/dist/typeshed-fallback/stdlib/encodings/iso2022_jp_ext.pyi +23 -0
  289. package/dist/typeshed-fallback/stdlib/encodings/iso2022_kr.pyi +23 -0
  290. package/dist/typeshed-fallback/stdlib/encodings/iso8859_1.pyi +21 -0
  291. package/dist/typeshed-fallback/stdlib/encodings/iso8859_10.pyi +21 -0
  292. package/dist/typeshed-fallback/stdlib/encodings/iso8859_11.pyi +21 -0
  293. package/dist/typeshed-fallback/stdlib/encodings/iso8859_13.pyi +21 -0
  294. package/dist/typeshed-fallback/stdlib/encodings/iso8859_14.pyi +21 -0
  295. package/dist/typeshed-fallback/stdlib/encodings/iso8859_15.pyi +21 -0
  296. package/dist/typeshed-fallback/stdlib/encodings/iso8859_16.pyi +21 -0
  297. package/dist/typeshed-fallback/stdlib/encodings/iso8859_2.pyi +21 -0
  298. package/dist/typeshed-fallback/stdlib/encodings/iso8859_3.pyi +21 -0
  299. package/dist/typeshed-fallback/stdlib/encodings/iso8859_4.pyi +21 -0
  300. package/dist/typeshed-fallback/stdlib/encodings/iso8859_5.pyi +21 -0
  301. package/dist/typeshed-fallback/stdlib/encodings/iso8859_6.pyi +21 -0
  302. package/dist/typeshed-fallback/stdlib/encodings/iso8859_7.pyi +21 -0
  303. package/dist/typeshed-fallback/stdlib/encodings/iso8859_8.pyi +21 -0
  304. package/dist/typeshed-fallback/stdlib/encodings/iso8859_9.pyi +21 -0
  305. package/dist/typeshed-fallback/stdlib/encodings/johab.pyi +23 -0
  306. package/dist/typeshed-fallback/stdlib/encodings/koi8_r.pyi +21 -0
  307. package/dist/typeshed-fallback/stdlib/encodings/koi8_t.pyi +21 -0
  308. package/dist/typeshed-fallback/stdlib/encodings/koi8_u.pyi +21 -0
  309. package/dist/typeshed-fallback/stdlib/encodings/kz1048.pyi +21 -0
  310. package/dist/typeshed-fallback/stdlib/encodings/latin_1.pyi +30 -0
  311. package/dist/typeshed-fallback/stdlib/encodings/mac_arabic.pyi +21 -0
  312. package/dist/typeshed-fallback/stdlib/encodings/mac_centeuro.pyi +21 -0
  313. package/dist/typeshed-fallback/stdlib/encodings/mac_croatian.pyi +21 -0
  314. package/dist/typeshed-fallback/stdlib/encodings/mac_cyrillic.pyi +21 -0
  315. package/dist/typeshed-fallback/stdlib/encodings/mac_farsi.pyi +21 -0
  316. package/dist/typeshed-fallback/stdlib/encodings/mac_greek.pyi +21 -0
  317. package/dist/typeshed-fallback/stdlib/encodings/mac_iceland.pyi +21 -0
  318. package/dist/typeshed-fallback/stdlib/encodings/mac_latin2.pyi +21 -0
  319. package/dist/typeshed-fallback/stdlib/encodings/mac_roman.pyi +21 -0
  320. package/dist/typeshed-fallback/stdlib/encodings/mac_romanian.pyi +21 -0
  321. package/dist/typeshed-fallback/stdlib/encodings/mac_turkish.pyi +21 -0
  322. package/dist/typeshed-fallback/stdlib/encodings/mbcs.pyi +28 -0
  323. package/dist/typeshed-fallback/stdlib/encodings/oem.pyi +28 -0
  324. package/dist/typeshed-fallback/stdlib/encodings/palmos.pyi +21 -0
  325. package/dist/typeshed-fallback/stdlib/encodings/ptcp154.pyi +21 -0
  326. package/dist/typeshed-fallback/stdlib/encodings/punycode.pyi +33 -0
  327. package/dist/typeshed-fallback/stdlib/encodings/quopri_codec.pyi +26 -0
  328. package/dist/typeshed-fallback/stdlib/encodings/raw_unicode_escape.pyi +34 -0
  329. package/dist/typeshed-fallback/stdlib/encodings/rot_13.pyi +23 -0
  330. package/dist/typeshed-fallback/stdlib/encodings/shift_jis.pyi +23 -0
  331. package/dist/typeshed-fallback/stdlib/encodings/shift_jis_2004.pyi +23 -0
  332. package/dist/typeshed-fallback/stdlib/encodings/shift_jisx0213.pyi +23 -0
  333. package/dist/typeshed-fallback/stdlib/encodings/tis_620.pyi +21 -0
  334. package/dist/typeshed-fallback/stdlib/encodings/undefined.pyi +20 -0
  335. package/dist/typeshed-fallback/stdlib/encodings/unicode_escape.pyi +34 -0
  336. package/dist/typeshed-fallback/stdlib/encodings/utf_16.pyi +20 -0
  337. package/dist/typeshed-fallback/stdlib/encodings/utf_16_be.pyi +26 -0
  338. package/dist/typeshed-fallback/stdlib/encodings/utf_16_le.pyi +26 -0
  339. package/dist/typeshed-fallback/stdlib/encodings/utf_32.pyi +20 -0
  340. package/dist/typeshed-fallback/stdlib/encodings/utf_32_be.pyi +26 -0
  341. package/dist/typeshed-fallback/stdlib/encodings/utf_32_le.pyi +26 -0
  342. package/dist/typeshed-fallback/stdlib/encodings/utf_7.pyi +26 -0
  343. package/dist/typeshed-fallback/stdlib/encodings/utf_8.pyi +26 -21
  344. package/dist/typeshed-fallback/stdlib/encodings/utf_8_sig.pyi +22 -22
  345. package/dist/typeshed-fallback/stdlib/encodings/uu_codec.pyi +28 -0
  346. package/dist/typeshed-fallback/stdlib/encodings/zlib_codec.pyi +26 -0
  347. package/dist/typeshed-fallback/stdlib/ensurepip/__init__.pyi +12 -12
  348. package/dist/typeshed-fallback/stdlib/enum.pyi +348 -348
  349. package/dist/typeshed-fallback/stdlib/errno.pyi +237 -237
  350. package/dist/typeshed-fallback/stdlib/faulthandler.pyi +34 -34
  351. package/dist/typeshed-fallback/stdlib/fcntl.pyi +3 -1
  352. package/dist/typeshed-fallback/stdlib/filecmp.pyi +74 -74
  353. package/dist/typeshed-fallback/stdlib/fileinput.pyi +219 -219
  354. package/dist/typeshed-fallback/stdlib/fnmatch.pyi +9 -9
  355. package/dist/typeshed-fallback/stdlib/formatter.pyi +88 -88
  356. package/dist/typeshed-fallback/stdlib/fractions.pyi +162 -162
  357. package/dist/typeshed-fallback/stdlib/ftplib.pyi +178 -178
  358. package/dist/typeshed-fallback/stdlib/functools.pyi +270 -270
  359. package/dist/typeshed-fallback/stdlib/gc.pyi +144 -144
  360. package/dist/typeshed-fallback/stdlib/genericpath.pyi +59 -59
  361. package/dist/typeshed-fallback/stdlib/getopt.pyi +15 -15
  362. package/dist/typeshed-fallback/stdlib/getpass.pyi +8 -8
  363. package/dist/typeshed-fallback/stdlib/gettext.pyi +171 -169
  364. package/dist/typeshed-fallback/stdlib/glob.pyi +50 -50
  365. package/dist/typeshed-fallback/stdlib/graphlib.pyi +34 -34
  366. package/dist/typeshed-fallback/stdlib/gzip.pyi +162 -162
  367. package/dist/typeshed-fallback/stdlib/hashlib.pyi +104 -163
  368. package/dist/typeshed-fallback/stdlib/heapq.pyi +19 -19
  369. package/dist/typeshed-fallback/stdlib/hmac.pyi +42 -65
  370. package/dist/typeshed-fallback/stdlib/html/__init__.pyi +6 -6
  371. package/dist/typeshed-fallback/stdlib/html/entities.pyi +6 -6
  372. package/dist/typeshed-fallback/stdlib/html/parser.pyi +34 -34
  373. package/dist/typeshed-fallback/stdlib/http/__init__.pyi +112 -112
  374. package/dist/typeshed-fallback/stdlib/http/client.pyi +246 -246
  375. package/dist/typeshed-fallback/stdlib/http/cookiejar.pyi +159 -159
  376. package/dist/typeshed-fallback/stdlib/http/cookies.pyi +66 -66
  377. package/dist/typeshed-fallback/stdlib/http/server.pyi +83 -83
  378. package/dist/typeshed-fallback/stdlib/imaplib.pyi +168 -168
  379. package/dist/typeshed-fallback/stdlib/imp.pyi +62 -62
  380. package/dist/typeshed-fallback/stdlib/importlib/__init__.pyi +15 -15
  381. package/dist/typeshed-fallback/stdlib/importlib/_abc.pyi +15 -15
  382. package/dist/typeshed-fallback/stdlib/importlib/_bootstrap.pyi +2 -2
  383. package/dist/typeshed-fallback/stdlib/importlib/_bootstrap_external.pyi +2 -2
  384. package/dist/typeshed-fallback/stdlib/importlib/abc.pyi +175 -175
  385. package/dist/typeshed-fallback/stdlib/importlib/machinery.pyi +20 -20
  386. package/dist/typeshed-fallback/stdlib/importlib/metadata/__init__.pyi +342 -371
  387. package/dist/typeshed-fallback/stdlib/importlib/metadata/_meta.pyi +65 -65
  388. package/dist/typeshed-fallback/stdlib/importlib/readers.pyi +68 -68
  389. package/dist/typeshed-fallback/stdlib/importlib/resources/__init__.pyi +70 -70
  390. package/dist/typeshed-fallback/stdlib/importlib/resources/_common.pyi +42 -42
  391. package/dist/typeshed-fallback/stdlib/importlib/resources/abc.pyi +14 -12
  392. package/dist/typeshed-fallback/stdlib/importlib/resources/readers.pyi +14 -14
  393. package/dist/typeshed-fallback/stdlib/importlib/resources/simple.pyi +58 -58
  394. package/dist/typeshed-fallback/stdlib/importlib/simple.pyi +11 -11
  395. package/dist/typeshed-fallback/stdlib/importlib/util.pyi +33 -33
  396. package/dist/typeshed-fallback/stdlib/inspect.pyi +642 -642
  397. package/dist/typeshed-fallback/stdlib/io.pyi +60 -60
  398. package/dist/typeshed-fallback/stdlib/ipaddress.pyi +509 -355
  399. package/dist/typeshed-fallback/stdlib/itertools.pyi +574 -574
  400. package/dist/typeshed-fallback/stdlib/json/__init__.pyi +61 -61
  401. package/dist/typeshed-fallback/stdlib/json/decoder.pyi +32 -32
  402. package/dist/typeshed-fallback/stdlib/json/encoder.pyi +52 -52
  403. package/dist/typeshed-fallback/stdlib/json/scanner.pyi +3 -0
  404. package/dist/typeshed-fallback/stdlib/json/tool.pyi +1 -1
  405. package/dist/typeshed-fallback/stdlib/keyword.pyi +25 -25
  406. package/dist/typeshed-fallback/stdlib/lib2to3/pytree.pyi +2 -12
  407. package/dist/typeshed-fallback/stdlib/linecache.pyi +23 -23
  408. package/dist/typeshed-fallback/stdlib/locale.pyi +156 -156
  409. package/dist/typeshed-fallback/stdlib/logging/__init__.pyi +698 -698
  410. package/dist/typeshed-fallback/stdlib/logging/config.pyi +134 -134
  411. package/dist/typeshed-fallback/stdlib/logging/handlers.pyi +277 -277
  412. package/dist/typeshed-fallback/stdlib/lzma.pyi +174 -174
  413. package/dist/typeshed-fallback/stdlib/mailbox.pyi +276 -276
  414. package/dist/typeshed-fallback/stdlib/marshal.pyi +128 -176
  415. package/dist/typeshed-fallback/stdlib/math.pyi +438 -442
  416. package/dist/typeshed-fallback/stdlib/mimetypes.pyi +56 -56
  417. package/dist/typeshed-fallback/stdlib/mmap.pyi +185 -185
  418. package/dist/typeshed-fallback/stdlib/modulefinder.pyi +68 -66
  419. package/dist/typeshed-fallback/stdlib/msilib/__init__.pyi +177 -177
  420. package/dist/typeshed-fallback/stdlib/msilib/schema.pyi +94 -94
  421. package/dist/typeshed-fallback/stdlib/msilib/sequence.pyi +13 -13
  422. package/dist/typeshed-fallback/stdlib/msilib/text.pyi +7 -7
  423. package/dist/typeshed-fallback/stdlib/multiprocessing/__init__.pyi +90 -90
  424. package/dist/typeshed-fallback/stdlib/multiprocessing/connection.pyi +89 -89
  425. package/dist/typeshed-fallback/stdlib/multiprocessing/context.pyi +216 -215
  426. package/dist/typeshed-fallback/stdlib/multiprocessing/dummy/__init__.pyi +79 -79
  427. package/dist/typeshed-fallback/stdlib/multiprocessing/dummy/connection.pyi +39 -39
  428. package/dist/typeshed-fallback/stdlib/multiprocessing/forkserver.pyi +31 -31
  429. package/dist/typeshed-fallback/stdlib/multiprocessing/heap.pyi +36 -36
  430. package/dist/typeshed-fallback/stdlib/multiprocessing/managers.pyi +266 -266
  431. package/dist/typeshed-fallback/stdlib/multiprocessing/pool.pyi +109 -109
  432. package/dist/typeshed-fallback/stdlib/multiprocessing/process.pyi +50 -50
  433. package/dist/typeshed-fallback/stdlib/multiprocessing/queues.pyi +53 -53
  434. package/dist/typeshed-fallback/stdlib/multiprocessing/reduction.pyi +87 -87
  435. package/dist/typeshed-fallback/stdlib/multiprocessing/resource_sharer.pyi +20 -20
  436. package/dist/typeshed-fallback/stdlib/multiprocessing/resource_tracker.pyi +18 -18
  437. package/dist/typeshed-fallback/stdlib/multiprocessing/shared_memory.pyi +58 -58
  438. package/dist/typeshed-fallback/stdlib/multiprocessing/sharedctypes.pyi +129 -128
  439. package/dist/typeshed-fallback/stdlib/multiprocessing/spawn.pyi +32 -32
  440. package/dist/typeshed-fallback/stdlib/multiprocessing/synchronize.pyi +59 -55
  441. package/dist/typeshed-fallback/stdlib/multiprocessing/util.pyi +98 -98
  442. package/dist/typeshed-fallback/stdlib/netrc.pyi +23 -23
  443. package/dist/typeshed-fallback/stdlib/nis.pyi +4 -31
  444. package/dist/typeshed-fallback/stdlib/ntpath.pyi +126 -126
  445. package/dist/typeshed-fallback/stdlib/nturl2path.pyi +2 -2
  446. package/dist/typeshed-fallback/stdlib/numbers.pyi +229 -229
  447. package/dist/typeshed-fallback/stdlib/opcode.pyi +65 -65
  448. package/dist/typeshed-fallback/stdlib/operator.pyi +221 -221
  449. package/dist/typeshed-fallback/stdlib/optparse.pyi +257 -257
  450. package/dist/typeshed-fallback/stdlib/os/__init__.pyi +2946 -2491
  451. package/dist/typeshed-fallback/stdlib/os/path.pyi +8 -8
  452. package/dist/typeshed-fallback/stdlib/parser.pyi +24 -55
  453. package/dist/typeshed-fallback/stdlib/pathlib.pyi +329 -329
  454. package/dist/typeshed-fallback/stdlib/pdb.pyi +206 -206
  455. package/dist/typeshed-fallback/stdlib/pickle.pyi +459 -459
  456. package/dist/typeshed-fallback/stdlib/pickletools.pyi +167 -167
  457. package/dist/typeshed-fallback/stdlib/pkgutil.pyi +53 -53
  458. package/dist/typeshed-fallback/stdlib/platform.pyi +97 -67
  459. package/dist/typeshed-fallback/stdlib/plistlib.pyi +113 -113
  460. package/dist/typeshed-fallback/stdlib/poplib.pyi +72 -72
  461. package/dist/typeshed-fallback/stdlib/posix.pyi +30 -10
  462. package/dist/typeshed-fallback/stdlib/posixpath.pyi +182 -182
  463. package/dist/typeshed-fallback/stdlib/pprint.pyi +112 -112
  464. package/dist/typeshed-fallback/stdlib/profile.pyi +31 -31
  465. package/dist/typeshed-fallback/stdlib/pstats.pyi +98 -80
  466. package/dist/typeshed-fallback/stdlib/py_compile.pyi +34 -34
  467. package/dist/typeshed-fallback/stdlib/pyclbr.pyi +74 -74
  468. package/dist/typeshed-fallback/stdlib/pydoc.pyi +333 -333
  469. package/dist/typeshed-fallback/stdlib/pydoc_data/topics.pyi +1 -1
  470. package/dist/typeshed-fallback/stdlib/pyexpat/__init__.pyi +131 -129
  471. package/dist/typeshed-fallback/stdlib/pyexpat/errors.pyi +53 -53
  472. package/dist/typeshed-fallback/stdlib/pyexpat/model.pyi +15 -15
  473. package/dist/typeshed-fallback/stdlib/queue.pyi +63 -63
  474. package/dist/typeshed-fallback/stdlib/quopri.pyi +11 -11
  475. package/dist/typeshed-fallback/stdlib/random.pyi +141 -141
  476. package/dist/typeshed-fallback/stdlib/re.pyi +476 -476
  477. package/dist/typeshed-fallback/stdlib/readline.pyi +1 -7
  478. package/dist/typeshed-fallback/stdlib/reprlib.pyi +65 -65
  479. package/dist/typeshed-fallback/stdlib/rlcompleter.pyi +9 -9
  480. package/dist/typeshed-fallback/stdlib/runpy.pyi +24 -24
  481. package/dist/typeshed-fallback/stdlib/sched.pyi +52 -49
  482. package/dist/typeshed-fallback/stdlib/secrets.pyi +15 -15
  483. package/dist/typeshed-fallback/stdlib/select.pyi +247 -247
  484. package/dist/typeshed-fallback/stdlib/selectors.pyi +67 -67
  485. package/dist/typeshed-fallback/stdlib/shelve.pyi +59 -59
  486. package/dist/typeshed-fallback/stdlib/shlex.pyi +63 -63
  487. package/dist/typeshed-fallback/stdlib/shutil.pyi +230 -230
  488. package/dist/typeshed-fallback/stdlib/signal.pyi +263 -263
  489. package/dist/typeshed-fallback/stdlib/site.pyi +36 -36
  490. package/dist/typeshed-fallback/stdlib/smtpd.pyi +91 -91
  491. package/dist/typeshed-fallback/stdlib/smtplib.pyi +204 -204
  492. package/dist/typeshed-fallback/stdlib/socket.pyi +1413 -856
  493. package/dist/typeshed-fallback/stdlib/socketserver.pyi +169 -169
  494. package/dist/typeshed-fallback/stdlib/spwd.pyi +13 -66
  495. package/dist/typeshed-fallback/stdlib/sqlite3/__init__.pyi +785 -787
  496. package/dist/typeshed-fallback/stdlib/sqlite3/dbapi2.pyi +241 -241
  497. package/dist/typeshed-fallback/stdlib/sqlite3/dump.pyi +2 -0
  498. package/dist/typeshed-fallback/stdlib/sre_compile.pyi +11 -11
  499. package/dist/typeshed-fallback/stdlib/sre_constants.pyi +124 -124
  500. package/dist/typeshed-fallback/stdlib/sre_parse.pyi +104 -104
  501. package/dist/typeshed-fallback/stdlib/ssl.pyi +558 -560
  502. package/dist/typeshed-fallback/stdlib/stat.pyi +7 -7
  503. package/dist/typeshed-fallback/stdlib/statistics.pyi +176 -176
  504. package/dist/typeshed-fallback/stdlib/string.pyi +83 -83
  505. package/dist/typeshed-fallback/stdlib/stringprep.pyi +27 -27
  506. package/dist/typeshed-fallback/stdlib/struct.pyi +5 -5
  507. package/dist/typeshed-fallback/stdlib/subprocess.pyi +2640 -2640
  508. package/dist/typeshed-fallback/stdlib/symbol.pyi +93 -93
  509. package/dist/typeshed-fallback/stdlib/symtable.pyi +90 -90
  510. package/dist/typeshed-fallback/stdlib/sys/__init__.pyi +773 -707
  511. package/dist/typeshed-fallback/stdlib/sysconfig.pyi +48 -48
  512. package/dist/typeshed-fallback/stdlib/tabnanny.pyi +16 -16
  513. package/dist/typeshed-fallback/stdlib/tarfile.pyi +593 -593
  514. package/dist/typeshed-fallback/stdlib/tempfile.pyi +497 -497
  515. package/dist/typeshed-fallback/stdlib/termios.pyi +108 -72
  516. package/dist/typeshed-fallback/stdlib/textwrap.pyi +103 -103
  517. package/dist/typeshed-fallback/stdlib/threading.pyi +279 -279
  518. package/dist/typeshed-fallback/stdlib/time.pyi +380 -380
  519. package/dist/typeshed-fallback/stdlib/timeit.pyi +32 -32
  520. package/dist/typeshed-fallback/stdlib/tkinter/__init__.pyi +3900 -3847
  521. package/dist/typeshed-fallback/stdlib/tkinter/colorchooser.pyi +20 -20
  522. package/dist/typeshed-fallback/stdlib/tkinter/commondialog.pyi +14 -14
  523. package/dist/typeshed-fallback/stdlib/tkinter/constants.pyi +80 -80
  524. package/dist/typeshed-fallback/stdlib/tkinter/dialog.pyi +16 -16
  525. package/dist/typeshed-fallback/stdlib/tkinter/dnd.pyi +20 -20
  526. package/dist/typeshed-fallback/stdlib/tkinter/filedialog.pyi +151 -151
  527. package/dist/typeshed-fallback/stdlib/tkinter/font.pyi +118 -116
  528. package/dist/typeshed-fallback/stdlib/tkinter/messagebox.pyi +44 -44
  529. package/dist/typeshed-fallback/stdlib/tkinter/scrolledtext.pyi +9 -9
  530. package/dist/typeshed-fallback/stdlib/tkinter/simpledialog.pyi +54 -54
  531. package/dist/typeshed-fallback/stdlib/tkinter/ttk.pyi +1207 -1207
  532. package/dist/typeshed-fallback/stdlib/token.pyi +160 -160
  533. package/dist/typeshed-fallback/stdlib/tokenize.pyi +186 -184
  534. package/dist/typeshed-fallback/stdlib/tomllib.pyi +10 -10
  535. package/dist/typeshed-fallback/stdlib/trace.pyi +90 -90
  536. package/dist/typeshed-fallback/stdlib/traceback.pyi +300 -300
  537. package/dist/typeshed-fallback/stdlib/tracemalloc.pyi +124 -124
  538. package/dist/typeshed-fallback/stdlib/turtle.pyi +732 -721
  539. package/dist/typeshed-fallback/stdlib/types.pyi +909 -913
  540. package/dist/typeshed-fallback/stdlib/typing.pyi +1145 -1147
  541. package/dist/typeshed-fallback/stdlib/typing_extensions.pyi +19 -47
  542. package/dist/typeshed-fallback/stdlib/unicodedata.pyi +303 -303
  543. package/dist/typeshed-fallback/stdlib/unittest/__init__.pyi +63 -68
  544. package/dist/typeshed-fallback/stdlib/unittest/_log.pyi +27 -27
  545. package/dist/typeshed-fallback/stdlib/unittest/async_case.pyi +25 -25
  546. package/dist/typeshed-fallback/stdlib/unittest/case.pyi +361 -361
  547. package/dist/typeshed-fallback/stdlib/unittest/loader.pyi +55 -55
  548. package/dist/typeshed-fallback/stdlib/unittest/main.pyi +73 -73
  549. package/dist/typeshed-fallback/stdlib/unittest/mock.pyi +468 -468
  550. package/dist/typeshed-fallback/stdlib/unittest/result.pyi +47 -47
  551. package/dist/typeshed-fallback/stdlib/unittest/runner.pyi +92 -92
  552. package/dist/typeshed-fallback/stdlib/unittest/signals.pyi +15 -15
  553. package/dist/typeshed-fallback/stdlib/unittest/suite.pyi +22 -22
  554. package/dist/typeshed-fallback/stdlib/unittest/util.pyi +23 -23
  555. package/dist/typeshed-fallback/stdlib/urllib/error.pyi +23 -23
  556. package/dist/typeshed-fallback/stdlib/urllib/parse.pyi +258 -258
  557. package/dist/typeshed-fallback/stdlib/urllib/request.pyi +408 -408
  558. package/dist/typeshed-fallback/stdlib/urllib/response.pyi +43 -43
  559. package/dist/typeshed-fallback/stdlib/urllib/robotparser.pyi +20 -20
  560. package/dist/typeshed-fallback/stdlib/uuid.pyi +100 -100
  561. package/dist/typeshed-fallback/stdlib/venv/__init__.pyi +107 -107
  562. package/dist/typeshed-fallback/stdlib/warnings.pyi +127 -127
  563. package/dist/typeshed-fallback/stdlib/wave.pyi +85 -85
  564. package/dist/typeshed-fallback/stdlib/weakref.pyi +198 -198
  565. package/dist/typeshed-fallback/stdlib/webbrowser.pyi +78 -77
  566. package/dist/typeshed-fallback/stdlib/wsgiref/handlers.pyi +91 -91
  567. package/dist/typeshed-fallback/stdlib/wsgiref/headers.pyi +26 -26
  568. package/dist/typeshed-fallback/stdlib/wsgiref/simple_server.pyi +37 -37
  569. package/dist/typeshed-fallback/stdlib/wsgiref/types.pyi +32 -32
  570. package/dist/typeshed-fallback/stdlib/wsgiref/util.pyi +26 -26
  571. package/dist/typeshed-fallback/stdlib/wsgiref/validate.pyi +50 -50
  572. package/dist/typeshed-fallback/stdlib/xml/__init__.pyi +3 -1
  573. package/dist/typeshed-fallback/stdlib/xml/dom/NodeFilter.pyi +19 -19
  574. package/dist/typeshed-fallback/stdlib/xml/dom/__init__.pyi +69 -69
  575. package/dist/typeshed-fallback/stdlib/xml/dom/domreg.pyi +8 -8
  576. package/dist/typeshed-fallback/stdlib/xml/dom/expatbuilder.pyi +100 -100
  577. package/dist/typeshed-fallback/stdlib/xml/dom/minicompat.pyi +26 -26
  578. package/dist/typeshed-fallback/stdlib/xml/dom/minidom.pyi +426 -426
  579. package/dist/typeshed-fallback/stdlib/xml/dom/pulldom.pyi +94 -94
  580. package/dist/typeshed-fallback/stdlib/xml/dom/xmlbuilder.pyi +108 -108
  581. package/dist/typeshed-fallback/stdlib/xml/etree/ElementInclude.pyi +29 -29
  582. package/dist/typeshed-fallback/stdlib/xml/etree/ElementPath.pyi +34 -34
  583. package/dist/typeshed-fallback/stdlib/xml/etree/ElementTree.pyi +347 -347
  584. package/dist/typeshed-fallback/stdlib/xml/etree/cElementTree.pyi +1 -1
  585. package/dist/typeshed-fallback/stdlib/xml/parsers/__init__.pyi +1 -1
  586. package/dist/typeshed-fallback/stdlib/xml/parsers/expat/__init__.pyi +7 -7
  587. package/dist/typeshed-fallback/stdlib/xml/parsers/expat/errors.pyi +3 -3
  588. package/dist/typeshed-fallback/stdlib/xml/parsers/expat/model.pyi +3 -3
  589. package/dist/typeshed-fallback/stdlib/xml/sax/__init__.pyi +25 -25
  590. package/dist/typeshed-fallback/stdlib/xml/sax/_exceptions.pyi +19 -19
  591. package/dist/typeshed-fallback/stdlib/xml/sax/handler.pyi +55 -55
  592. package/dist/typeshed-fallback/stdlib/xml/sax/saxutils.pyi +60 -60
  593. package/dist/typeshed-fallback/stdlib/xml/sax/xmlreader.pyi +87 -87
  594. package/dist/typeshed-fallback/stdlib/xmlrpc/client.pyi +296 -296
  595. package/dist/typeshed-fallback/stdlib/xmlrpc/server.pyi +144 -144
  596. package/dist/typeshed-fallback/stdlib/xxlimited.pyi +1 -3
  597. package/dist/typeshed-fallback/stdlib/zipapp.pyi +20 -20
  598. package/dist/typeshed-fallback/stdlib/zipfile/__init__.pyi +384 -384
  599. package/dist/typeshed-fallback/stdlib/zipfile/_path.pyi +103 -101
  600. package/dist/typeshed-fallback/stdlib/zipimport.pyi +41 -70
  601. package/dist/typeshed-fallback/stdlib/zlib.pyi +162 -157
  602. package/dist/typeshed-fallback/stdlib/zoneinfo/__init__.pyi +41 -47
  603. package/dist/typeshed-fallback/stdlib/zoneinfo/_common.pyi +13 -13
  604. package/dist/typeshed-fallback/stdlib/zoneinfo/_tzpath.pyi +13 -13
  605. package/dist/typeshed-fallback/stubs/Deprecated/METADATA.toml +1 -1
  606. package/dist/typeshed-fallback/stubs/Deprecated/deprecated/classic.pyi +6 -1
  607. package/dist/typeshed-fallback/stubs/Deprecated/deprecated/sphinx.pyi +1 -0
  608. package/dist/typeshed-fallback/stubs/bleach/METADATA.toml +1 -1
  609. package/dist/typeshed-fallback/stubs/docutils/docutils/core.pyi +216 -1
  610. package/dist/typeshed-fallback/stubs/docutils/docutils/writers/__init__.pyi +60 -2
  611. package/dist/typeshed-fallback/stubs/gevent/METADATA.toml +1 -1
  612. package/dist/typeshed-fallback/stubs/gevent/gevent/events.pyi +3 -1
  613. package/dist/typeshed-fallback/stubs/icalendar/METADATA.toml +6 -2
  614. package/dist/typeshed-fallback/stubs/icalendar/icalendar/__init__.pyi +14 -0
  615. package/dist/typeshed-fallback/stubs/icalendar/icalendar/alarms.pyi +54 -0
  616. package/dist/typeshed-fallback/stubs/icalendar/icalendar/cal.pyi +137 -11
  617. package/dist/typeshed-fallback/stubs/icalendar/icalendar/prop.pyi +8 -7
  618. package/dist/typeshed-fallback/stubs/icalendar/icalendar/timezone/__init__.pyi +3 -2
  619. package/dist/typeshed-fallback/stubs/icalendar/icalendar/timezone/equivalent_timezone_ids.pyi +15 -0
  620. package/dist/typeshed-fallback/stubs/icalendar/icalendar/timezone/equivalent_timezone_ids_result.pyi +6 -0
  621. package/dist/typeshed-fallback/stubs/icalendar/icalendar/timezone/tzid.pyi +8 -0
  622. package/dist/typeshed-fallback/stubs/icalendar/icalendar/timezone/tzp.pyi +2 -2
  623. package/dist/typeshed-fallback/stubs/icalendar/icalendar/tools.pyi +12 -1
  624. package/dist/typeshed-fallback/stubs/networkx/METADATA.toml +1 -1
  625. package/dist/typeshed-fallback/stubs/networkx/networkx/algorithms/components/strongly_connected.pyi +0 -2
  626. package/dist/typeshed-fallback/stubs/networkx/networkx/algorithms/tree/branchings.pyi +0 -31
  627. package/dist/typeshed-fallback/stubs/networkx/networkx/algorithms/tree/operations.pyi +1 -1
  628. package/dist/typeshed-fallback/stubs/networkx/networkx/classes/reportviews.pyi +3 -1
  629. package/dist/typeshed-fallback/stubs/networkx/networkx/drawing/layout.pyi +4 -0
  630. package/dist/typeshed-fallback/stubs/networkx/networkx/generators/trees.pyi +0 -4
  631. package/dist/typeshed-fallback/stubs/networkx/networkx/readwrite/json_graph/node_link.pyi +12 -2
  632. package/dist/typeshed-fallback/stubs/networkx/networkx/readwrite/text.pyi +1 -4
  633. package/dist/typeshed-fallback/stubs/networkx/networkx/utils/configs.pyi +20 -2
  634. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/__init__.pyi +2 -1
  635. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/cell/__init__.pyi +2 -0
  636. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/cell/_writer.pyi +4 -2
  637. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/cell/cell.pyi +2 -2
  638. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/comments/comment_sheet.pyi +2 -1
  639. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/workbook/workbook.pyi +2 -2
  640. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/worksheet/_read_only.pyi +5 -14
  641. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/worksheet/_reader.pyi +2 -3
  642. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/worksheet/_writer.pyi +4 -3
  643. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/worksheet/merge.pyi +2 -1
  644. package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/worksheet/worksheet.pyi +30 -19
  645. package/dist/typeshed-fallback/stubs/peewee/METADATA.toml +1 -1
  646. package/dist/typeshed-fallback/stubs/peewee/peewee.pyi +3 -1
  647. package/dist/typeshed-fallback/stubs/pynput/pynput/_util.pyi +2 -2
  648. package/dist/typeshed-fallback/stubs/pysftp/pysftp/__init__.pyi +2 -2
  649. package/dist/typeshed-fallback/stubs/pywin32/isapi/install.pyi +98 -0
  650. package/dist/typeshed-fallback/stubs/pywin32/win32/win32clipboard.pyi +26 -24
  651. package/dist/typeshed-fallback/stubs/setuptools/METADATA.toml +1 -1
  652. package/dist/typeshed-fallback/stubs/setuptools/distutils/spawn.pyi +1 -0
  653. package/dist/typeshed-fallback/stubs/setuptools/setuptools/__init__.pyi +6 -7
  654. package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/ccompiler.pyi +2 -2
  655. package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/cmd.pyi +2 -2
  656. package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/spawn.pyi +7 -0
  657. package/dist/typeshed-fallback/stubs/setuptools/setuptools/build_meta.pyi +4 -2
  658. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/bdist_egg.pyi +9 -8
  659. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/bdist_wheel.pyi +3 -5
  660. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/build_ext.pyi +2 -1
  661. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/build_py.pyi +6 -7
  662. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/easy_install.pyi +12 -17
  663. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/editable_wheel.pyi +1 -1
  664. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/egg_info.pyi +1 -1
  665. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/install_egg_info.pyi +1 -1
  666. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/sdist.pyi +2 -1
  667. package/dist/typeshed-fallback/stubs/setuptools/setuptools/command/test.pyi +2 -2
  668. package/dist/typeshed-fallback/stubs/setuptools/setuptools/config/__init__.pyi +1 -14
  669. package/dist/typeshed-fallback/stubs/setuptools/setuptools/config/expand.pyi +1 -1
  670. package/dist/typeshed-fallback/stubs/setuptools/setuptools/config/setupcfg.pyi +7 -5
  671. package/dist/typeshed-fallback/stubs/setuptools/setuptools/depends.pyi +8 -4
  672. package/dist/typeshed-fallback/stubs/setuptools/setuptools/dist.pyi +1 -1
  673. package/dist/typeshed-fallback/stubs/setuptools/setuptools/msvc.pyi +7 -8
  674. package/dist/typeshed-fallback/stubs/setuptools/setuptools/package_index.pyi +7 -3
  675. package/dist/typeshed-fallback/stubs/setuptools/setuptools/sandbox.pyi +2 -4
  676. package/dist/typeshed-fallback/stubs/tqdm/METADATA.toml +2 -1
  677. package/dist/typeshed-fallback/stubs/tqdm/tqdm/contrib/discord.pyi +14 -3
  678. package/dist/typeshed-fallback/stubs/waitress/waitress/runner.pyi +1 -5
  679. package/package.json +5 -3
@@ -1,913 +1,909 @@
1
- import sys
2
- from _typeshed import MaybeNone, SupportsKeysAndGetItem
3
- from _typeshed.importlib import LoaderProtocol
4
- from collections.abc import (
5
- AsyncGenerator,
6
- Awaitable,
7
- Callable,
8
- Coroutine,
9
- Generator,
10
- ItemsView,
11
- Iterable,
12
- Iterator,
13
- KeysView,
14
- MutableSequence,
15
- ValuesView,
16
- )
17
- from importlib.machinery import ModuleSpec
18
-
19
- # pytype crashes if types.MappingProxyType inherits from collections.abc.Mapping instead of typing.Mapping
20
- from typing import Any, ClassVar, Literal, Mapping, TypeVar, final, overload # noqa: Y022
21
- from typing_extensions import ParamSpec, Self, TypeVarTuple, deprecated
22
-
23
- __all__ = [
24
- "FunctionType",
25
- "LambdaType",
26
- "CodeType",
27
- "MappingProxyType",
28
- "SimpleNamespace",
29
- "GeneratorType",
30
- "CoroutineType",
31
- "AsyncGeneratorType",
32
- "MethodType",
33
- "BuiltinFunctionType",
34
- "ModuleType",
35
- "TracebackType",
36
- "FrameType",
37
- "GetSetDescriptorType",
38
- "MemberDescriptorType",
39
- "new_class",
40
- "prepare_class",
41
- "DynamicClassAttribute",
42
- "coroutine",
43
- "BuiltinMethodType",
44
- "ClassMethodDescriptorType",
45
- "MethodDescriptorType",
46
- "MethodWrapperType",
47
- "WrapperDescriptorType",
48
- "resolve_bases",
49
- "CellType",
50
- ]
51
-
52
- if sys.version_info >= (3, 9):
53
- __all__ += ["GenericAlias"]
54
-
55
- if sys.version_info >= (3, 10):
56
- __all__ += ["EllipsisType", "NoneType", "NotImplementedType", "UnionType"]
57
-
58
- if sys.version_info >= (3, 12):
59
- __all__ += ["get_original_bases"]
60
-
61
- if sys.version_info >= (3, 13):
62
- __all__ += ["CapsuleType"]
63
-
64
- # Note, all classes "defined" here require special handling.
65
-
66
- _T1 = TypeVar("_T1")
67
- _T2 = TypeVar("_T2")
68
- _KT = TypeVar("_KT")
69
- _VT_co = TypeVar("_VT_co", covariant=True)
70
-
71
- # Make sure this class definition stays roughly in line with `builtins.function`
72
- @final
73
- class FunctionType:
74
- """
75
- Create a function object.
76
-
77
- code
78
- a code object
79
- globals
80
- the globals dictionary
81
- name
82
- a string that overrides the name from the code object
83
- argdefs
84
- a tuple that specifies the default argument values
85
- closure
86
- a tuple that supplies the bindings for free variables
87
- kwdefaults
88
- a dictionary that specifies the default keyword argument values
89
- """
90
- @property
91
- def __closure__(self) -> tuple[CellType, ...] | None: ...
92
- __code__: CodeType
93
- __defaults__: tuple[Any, ...] | None
94
- __dict__: dict[str, Any]
95
- @property
96
- def __globals__(self) -> dict[str, Any]: ...
97
- __name__: str
98
- __qualname__: str
99
- __annotations__: dict[str, Any]
100
- __kwdefaults__: dict[str, Any] | None
101
- if sys.version_info >= (3, 10):
102
- @property
103
- def __builtins__(self) -> dict[str, Any]: ...
104
- if sys.version_info >= (3, 12):
105
- __type_params__: tuple[TypeVar | ParamSpec | TypeVarTuple, ...]
106
-
107
- __module__: str
108
- def __new__(
109
- cls,
110
- code: CodeType,
111
- globals: dict[str, Any],
112
- name: str | None = ...,
113
- argdefs: tuple[object, ...] | None = ...,
114
- closure: tuple[CellType, ...] | None = ...,
115
- ) -> Self: ...
116
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
117
- """Call self as a function."""
118
- ...
119
- @overload
120
- def __get__(self, instance: None, owner: type, /) -> FunctionType:
121
- """Return an attribute of instance, which is of type owner."""
122
- ...
123
- @overload
124
- def __get__(self, instance: object, owner: type | None = None, /) -> MethodType:
125
- """Return an attribute of instance, which is of type owner."""
126
- ...
127
-
128
- LambdaType = FunctionType
129
-
130
- @final
131
- class CodeType:
132
- """Create a code object. Not for the faint of heart."""
133
- def __eq__(self, value: object, /) -> bool:
134
- """Return self==value."""
135
- ...
136
- def __hash__(self) -> int:
137
- """Return hash(self)."""
138
- ...
139
- @property
140
- def co_argcount(self) -> int: ...
141
- @property
142
- def co_posonlyargcount(self) -> int: ...
143
- @property
144
- def co_kwonlyargcount(self) -> int: ...
145
- @property
146
- def co_nlocals(self) -> int: ...
147
- @property
148
- def co_stacksize(self) -> int: ...
149
- @property
150
- def co_flags(self) -> int: ...
151
- @property
152
- def co_code(self) -> bytes: ...
153
- @property
154
- def co_consts(self) -> tuple[Any, ...]: ...
155
- @property
156
- def co_names(self) -> tuple[str, ...]: ...
157
- @property
158
- def co_varnames(self) -> tuple[str, ...]: ...
159
- @property
160
- def co_filename(self) -> str: ...
161
- @property
162
- def co_name(self) -> str: ...
163
- @property
164
- def co_firstlineno(self) -> int: ...
165
- if sys.version_info >= (3, 10):
166
- @property
167
- @deprecated("Will be removed in Python 3.14. Use the co_lines() method instead.")
168
- def co_lnotab(self) -> bytes: ...
169
- else:
170
- @property
171
- def co_lnotab(self) -> bytes: ...
172
-
173
- @property
174
- def co_freevars(self) -> tuple[str, ...]: ...
175
- @property
176
- def co_cellvars(self) -> tuple[str, ...]: ...
177
- if sys.version_info >= (3, 10):
178
- @property
179
- def co_linetable(self) -> bytes: ...
180
- def co_lines(self) -> Iterator[tuple[int, int, int | None]]: ...
181
- if sys.version_info >= (3, 11):
182
- @property
183
- def co_exceptiontable(self) -> bytes: ...
184
- @property
185
- def co_qualname(self) -> str: ...
186
- def co_positions(self) -> Iterable[tuple[int | None, int | None, int | None, int | None]]: ...
187
-
188
- if sys.version_info >= (3, 11):
189
- def __new__(
190
- cls,
191
- argcount: int,
192
- posonlyargcount: int,
193
- kwonlyargcount: int,
194
- nlocals: int,
195
- stacksize: int,
196
- flags: int,
197
- codestring: bytes,
198
- constants: tuple[object, ...],
199
- names: tuple[str, ...],
200
- varnames: tuple[str, ...],
201
- filename: str,
202
- name: str,
203
- qualname: str,
204
- firstlineno: int,
205
- linetable: bytes,
206
- exceptiontable: bytes,
207
- freevars: tuple[str, ...] = ...,
208
- cellvars: tuple[str, ...] = ...,
209
- /,
210
- ) -> Self: ...
211
- elif sys.version_info >= (3, 10):
212
- def __new__(
213
- cls,
214
- argcount: int,
215
- posonlyargcount: int,
216
- kwonlyargcount: int,
217
- nlocals: int,
218
- stacksize: int,
219
- flags: int,
220
- codestring: bytes,
221
- constants: tuple[object, ...],
222
- names: tuple[str, ...],
223
- varnames: tuple[str, ...],
224
- filename: str,
225
- name: str,
226
- firstlineno: int,
227
- linetable: bytes,
228
- freevars: tuple[str, ...] = ...,
229
- cellvars: tuple[str, ...] = ...,
230
- /,
231
- ) -> Self: ...
232
- else:
233
- def __new__(
234
- cls,
235
- argcount: int,
236
- posonlyargcount: int,
237
- kwonlyargcount: int,
238
- nlocals: int,
239
- stacksize: int,
240
- flags: int,
241
- codestring: bytes,
242
- constants: tuple[object, ...],
243
- names: tuple[str, ...],
244
- varnames: tuple[str, ...],
245
- filename: str,
246
- name: str,
247
- firstlineno: int,
248
- lnotab: bytes,
249
- freevars: tuple[str, ...] = ...,
250
- cellvars: tuple[str, ...] = ...,
251
- /,
252
- ) -> Self: ...
253
- if sys.version_info >= (3, 11):
254
- def replace(
255
- self,
256
- *,
257
- co_argcount: int = -1,
258
- co_posonlyargcount: int = -1,
259
- co_kwonlyargcount: int = -1,
260
- co_nlocals: int = -1,
261
- co_stacksize: int = -1,
262
- co_flags: int = -1,
263
- co_firstlineno: int = -1,
264
- co_code: bytes = ...,
265
- co_consts: tuple[object, ...] = ...,
266
- co_names: tuple[str, ...] = ...,
267
- co_varnames: tuple[str, ...] = ...,
268
- co_freevars: tuple[str, ...] = ...,
269
- co_cellvars: tuple[str, ...] = ...,
270
- co_filename: str = ...,
271
- co_name: str = ...,
272
- co_qualname: str = ...,
273
- co_linetable: bytes = ...,
274
- co_exceptiontable: bytes = ...,
275
- ) -> Self:
276
- """Return a copy of the code object with new values for the specified fields."""
277
- ...
278
- elif sys.version_info >= (3, 10):
279
- def replace(
280
- self,
281
- *,
282
- co_argcount: int = -1,
283
- co_posonlyargcount: int = -1,
284
- co_kwonlyargcount: int = -1,
285
- co_nlocals: int = -1,
286
- co_stacksize: int = -1,
287
- co_flags: int = -1,
288
- co_firstlineno: int = -1,
289
- co_code: bytes = ...,
290
- co_consts: tuple[object, ...] = ...,
291
- co_names: tuple[str, ...] = ...,
292
- co_varnames: tuple[str, ...] = ...,
293
- co_freevars: tuple[str, ...] = ...,
294
- co_cellvars: tuple[str, ...] = ...,
295
- co_filename: str = ...,
296
- co_name: str = ...,
297
- co_linetable: bytes = ...,
298
- ) -> Self:
299
- """Return a copy of the code object with new values for the specified fields."""
300
- ...
301
- else:
302
- def replace(
303
- self,
304
- *,
305
- co_argcount: int = -1,
306
- co_posonlyargcount: int = -1,
307
- co_kwonlyargcount: int = -1,
308
- co_nlocals: int = -1,
309
- co_stacksize: int = -1,
310
- co_flags: int = -1,
311
- co_firstlineno: int = -1,
312
- co_code: bytes = ...,
313
- co_consts: tuple[object, ...] = ...,
314
- co_names: tuple[str, ...] = ...,
315
- co_varnames: tuple[str, ...] = ...,
316
- co_freevars: tuple[str, ...] = ...,
317
- co_cellvars: tuple[str, ...] = ...,
318
- co_filename: str = ...,
319
- co_name: str = ...,
320
- co_lnotab: bytes = ...,
321
- ) -> Self:
322
- """Return a copy of the code object with new values for the specified fields."""
323
- ...
324
-
325
- if sys.version_info >= (3, 13):
326
- __replace__ = replace
327
-
328
- @final
329
- class MappingProxyType(Mapping[_KT, _VT_co]):
330
- """Read-only proxy of a mapping."""
331
- __hash__: ClassVar[None] # type: ignore[assignment]
332
- def __new__(cls, mapping: SupportsKeysAndGetItem[_KT, _VT_co]) -> Self: ...
333
- def __getitem__(self, key: _KT, /) -> _VT_co:
334
- """Return self[key]."""
335
- ...
336
- def __iter__(self) -> Iterator[_KT]:
337
- """Implement iter(self)."""
338
- ...
339
- def __len__(self) -> int:
340
- """Return len(self)."""
341
- ...
342
- def __eq__(self, value: object, /) -> bool:
343
- """Return self==value."""
344
- ...
345
- def copy(self) -> dict[_KT, _VT_co]:
346
- """D.copy() -> a shallow copy of D"""
347
- ...
348
- def keys(self) -> KeysView[_KT]:
349
- """D.keys() -> a set-like object providing a view on D's keys"""
350
- ...
351
- def values(self) -> ValuesView[_VT_co]:
352
- """D.values() -> an object providing a view on D's values"""
353
- ...
354
- def items(self) -> ItemsView[_KT, _VT_co]:
355
- """D.items() -> a set-like object providing a view on D's items"""
356
- ...
357
- @overload
358
- def get(self, key: _KT, /) -> _VT_co | None:
359
- """Return the value for key if key is in the mapping, else default."""
360
- ...
361
- @overload
362
- def get(self, key: _KT, default: _VT_co | _T2, /) -> _VT_co | _T2:
363
- """Return the value for key if key is in the mapping, else default."""
364
- ...
365
- if sys.version_info >= (3, 9):
366
- def __class_getitem__(cls, item: Any, /) -> GenericAlias:
367
- """See PEP 585"""
368
- ...
369
- def __reversed__(self) -> Iterator[_KT]:
370
- """D.__reversed__() -> reverse iterator"""
371
- ...
372
- def __or__(self, value: Mapping[_T1, _T2], /) -> dict[_KT | _T1, _VT_co | _T2]:
373
- """Return self|value."""
374
- ...
375
- def __ror__(self, value: Mapping[_T1, _T2], /) -> dict[_KT | _T1, _VT_co | _T2]:
376
- """Return value|self."""
377
- ...
378
-
379
- class SimpleNamespace:
380
- __hash__: ClassVar[None] # type: ignore[assignment]
381
- if sys.version_info >= (3, 13):
382
- def __init__(self, mapping_or_iterable: Mapping[str, Any] | Iterable[tuple[str, Any]] = (), /, **kwargs: Any) -> None: ...
383
- else:
384
- def __init__(self, **kwargs: Any) -> None: ...
385
-
386
- def __eq__(self, value: object, /) -> bool:
387
- """Return self==value."""
388
- ...
389
- def __getattribute__(self, name: str, /) -> Any:
390
- """Return getattr(self, name)."""
391
- ...
392
- def __setattr__(self, name: str, value: Any, /) -> None:
393
- """Implement setattr(self, name, value)."""
394
- ...
395
- def __delattr__(self, name: str, /) -> None:
396
- """Implement delattr(self, name)."""
397
- ...
398
- if sys.version_info >= (3, 13):
399
- def __replace__(self, **kwargs: Any) -> Self:
400
- """Return a copy of the namespace object with new values for the specified attributes."""
401
- ...
402
-
403
- class ModuleType:
404
- """
405
- Create a module object.
406
-
407
- The name must be a string; the optional doc argument can have any type.
408
- """
409
- __name__: str
410
- __file__: str | None
411
- @property
412
- def __dict__(self) -> dict[str, Any]: ... # type: ignore[override]
413
- __loader__: LoaderProtocol | None
414
- __package__: str | None
415
- __path__: MutableSequence[str]
416
- __spec__: ModuleSpec | None
417
- # N.B. Although this is the same type as `builtins.object.__doc__`,
418
- # it is deliberately redeclared here. Most symbols declared in the namespace
419
- # of `types.ModuleType` are available as "implicit globals" within a module's
420
- # namespace, but this is not true for symbols declared in the namespace of `builtins.object`.
421
- # Redeclaring `__doc__` here helps some type checkers understand that `__doc__` is available
422
- # as an implicit global in all modules, similar to `__name__`, `__file__`, `__spec__`, etc.
423
- __doc__: str | None
424
- def __init__(self, name: str, doc: str | None = ...) -> None: ...
425
- # __getattr__ doesn't exist at runtime,
426
- # but having it here in typeshed makes dynamic imports
427
- # using `builtins.__import__` or `importlib.import_module` less painful
428
- def __getattr__(self, name: str) -> Any: ...
429
-
430
- @final
431
- class CellType:
432
- """
433
- Create a new cell object.
434
-
435
- contents
436
- the contents of the cell. If not specified, the cell will be empty,
437
- and
438
- further attempts to access its cell_contents attribute will
439
- raise a ValueError.
440
- """
441
- def __new__(cls, contents: object = ..., /) -> Self: ...
442
- __hash__: ClassVar[None] # type: ignore[assignment]
443
- cell_contents: Any
444
-
445
- _YieldT_co = TypeVar("_YieldT_co", covariant=True)
446
- _SendT_contra = TypeVar("_SendT_contra", contravariant=True)
447
- _ReturnT_co = TypeVar("_ReturnT_co", covariant=True)
448
-
449
- @final
450
- class GeneratorType(Generator[_YieldT_co, _SendT_contra, _ReturnT_co]):
451
- @property
452
- def gi_yieldfrom(self) -> GeneratorType[_YieldT_co, _SendT_contra, Any] | None:
453
- """object being iterated by yield from, or None"""
454
- ...
455
- if sys.version_info >= (3, 11):
456
- @property
457
- def gi_suspended(self) -> bool: ...
458
- __name__: str
459
- __qualname__: str
460
- def __iter__(self) -> Self:
461
- """Implement iter(self)."""
462
- ...
463
- def __next__(self) -> _YieldT_co:
464
- """Implement next(self)."""
465
- ...
466
- def send(self, arg: _SendT_contra, /) -> _YieldT_co:
467
- """
468
- send(arg) -> send 'arg' into generator,
469
- return next yielded value or raise StopIteration.
470
- """
471
- ...
472
- @overload
473
- def throw(
474
- self, typ: type[BaseException], val: BaseException | object = ..., tb: TracebackType | None = ..., /
475
- ) -> _YieldT_co:
476
- """
477
- throw(value)
478
- throw(type[,value[,tb]])
479
-
480
- Raise exception in generator, return next yielded value or raise
481
- StopIteration.
482
- the (type, val, tb) signature is deprecated,
483
- and may be removed in a future version of Python.
484
- """
485
- ...
486
- @overload
487
- def throw(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co:
488
- """
489
- throw(value)
490
- throw(type[,value[,tb]])
491
-
492
- Raise exception in generator, return next yielded value or raise
493
- StopIteration.
494
- the (type, val, tb) signature is deprecated,
495
- and may be removed in a future version of Python.
496
- """
497
- ...
498
- if sys.version_info >= (3, 13):
499
- def __class_getitem__(cls, item: Any, /) -> Any:
500
- """See PEP 585"""
501
- ...
502
-
503
- @final
504
- class AsyncGeneratorType(AsyncGenerator[_YieldT_co, _SendT_contra]):
505
- @property
506
- def ag_await(self) -> Awaitable[Any] | None:
507
- """object being awaited on, or None"""
508
- ...
509
- __name__: str
510
- __qualname__: str
511
- if sys.version_info >= (3, 12):
512
- @property
513
- def ag_suspended(self) -> bool: ...
514
-
515
- def __aiter__(self) -> Self:
516
- """Return an awaitable, that resolves in asynchronous iterator."""
517
- ...
518
- def __anext__(self) -> Coroutine[Any, Any, _YieldT_co]:
519
- """Return a value or raise StopAsyncIteration."""
520
- ...
521
- def asend(self, val: _SendT_contra, /) -> Coroutine[Any, Any, _YieldT_co]:
522
- """asend(v) -> send 'v' in generator."""
523
- ...
524
- @overload
525
- async def athrow(
526
- self, typ: type[BaseException], val: BaseException | object = ..., tb: TracebackType | None = ..., /
527
- ) -> _YieldT_co:
528
- """
529
- athrow(value)
530
- athrow(type[,value[,tb]])
531
-
532
- raise exception in generator.
533
- the (type, val, tb) signature is deprecated,
534
- and may be removed in a future version of Python.
535
- """
536
- ...
537
- @overload
538
- async def athrow(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co:
539
- """
540
- athrow(value)
541
- athrow(type[,value[,tb]])
542
-
543
- raise exception in generator.
544
- the (type, val, tb) signature is deprecated,
545
- and may be removed in a future version of Python.
546
- """
547
- ...
548
- def aclose(self) -> Coroutine[Any, Any, None]:
549
- """aclose() -> raise GeneratorExit inside generator."""
550
- ...
551
- if sys.version_info >= (3, 9):
552
- def __class_getitem__(cls, item: Any, /) -> GenericAlias:
553
- """See PEP 585"""
554
- ...
555
-
556
- @final
557
- class CoroutineType(Coroutine[_YieldT_co, _SendT_contra, _ReturnT_co]):
558
- __name__: str
559
- __qualname__: str
560
- @property
561
- def cr_origin(self) -> tuple[tuple[str, int, str], ...] | None: ...
562
- if sys.version_info >= (3, 11):
563
- @property
564
- def cr_suspended(self) -> bool: ...
565
-
566
- def close(self) -> None:
567
- """close() -> raise GeneratorExit inside coroutine."""
568
- ...
569
- def __await__(self) -> Generator[Any, None, _ReturnT_co]:
570
- """Return an iterator to be used in await expression."""
571
- ...
572
- def send(self, arg: _SendT_contra, /) -> _YieldT_co:
573
- """
574
- send(arg) -> send 'arg' into coroutine,
575
- return next iterated value or raise StopIteration.
576
- """
577
- ...
578
- @overload
579
- def throw(
580
- self, typ: type[BaseException], val: BaseException | object = ..., tb: TracebackType | None = ..., /
581
- ) -> _YieldT_co:
582
- """
583
- throw(value)
584
- throw(type[,value[,traceback]])
585
-
586
- Raise exception in coroutine, return next iterated value or raise
587
- StopIteration.
588
- the (type, val, tb) signature is deprecated,
589
- and may be removed in a future version of Python.
590
- """
591
- ...
592
- @overload
593
- def throw(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co:
594
- """
595
- throw(value)
596
- throw(type[,value[,traceback]])
597
-
598
- Raise exception in coroutine, return next iterated value or raise
599
- StopIteration.
600
- the (type, val, tb) signature is deprecated,
601
- and may be removed in a future version of Python.
602
- """
603
- ...
604
- if sys.version_info >= (3, 13):
605
- def __class_getitem__(cls, item: Any, /) -> Any:
606
- """See PEP 585"""
607
- ...
608
-
609
- @final
610
- class MethodType:
611
- """Create a bound instance method object."""
612
- @property
613
- def __closure__(self) -> tuple[CellType, ...] | None: ... # inherited from the added function
614
- @property
615
- def __code__(self) -> CodeType: ... # inherited from the added function
616
- @property
617
- def __defaults__(self) -> tuple[Any, ...] | None: ... # inherited from the added function
618
- @property
619
- def __func__(self) -> Callable[..., Any]:
620
- """the function (or other callable) implementing a method"""
621
- ...
622
- @property
623
- def __self__(self) -> object:
624
- """the instance to which a method is bound"""
625
- ...
626
- @property
627
- def __name__(self) -> str: ... # inherited from the added function
628
- @property
629
- def __qualname__(self) -> str: ... # inherited from the added function
630
- def __new__(cls, func: Callable[..., Any], obj: object, /) -> Self: ...
631
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
632
- """Call self as a function."""
633
- ...
634
- def __eq__(self, value: object, /) -> bool:
635
- """Return self==value."""
636
- ...
637
- def __hash__(self) -> int:
638
- """Return hash(self)."""
639
- ...
640
-
641
- @final
642
- class BuiltinFunctionType:
643
- @property
644
- def __self__(self) -> object | ModuleType: ...
645
- @property
646
- def __name__(self) -> str: ...
647
- @property
648
- def __qualname__(self) -> str: ...
649
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
650
- """Call self as a function."""
651
- ...
652
- def __eq__(self, value: object, /) -> bool:
653
- """Return self==value."""
654
- ...
655
- def __hash__(self) -> int:
656
- """Return hash(self)."""
657
- ...
658
-
659
- BuiltinMethodType = BuiltinFunctionType
660
-
661
- @final
662
- class WrapperDescriptorType:
663
- @property
664
- def __name__(self) -> str: ...
665
- @property
666
- def __qualname__(self) -> str: ...
667
- @property
668
- def __objclass__(self) -> type: ...
669
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
670
- """Call self as a function."""
671
- ...
672
- def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
673
- """Return an attribute of instance, which is of type owner."""
674
- ...
675
-
676
- @final
677
- class MethodWrapperType:
678
- @property
679
- def __self__(self) -> object: ...
680
- @property
681
- def __name__(self) -> str: ...
682
- @property
683
- def __qualname__(self) -> str: ...
684
- @property
685
- def __objclass__(self) -> type: ...
686
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
687
- """Call self as a function."""
688
- ...
689
- def __eq__(self, value: object, /) -> bool:
690
- """Return self==value."""
691
- ...
692
- def __ne__(self, value: object, /) -> bool:
693
- """Return self!=value."""
694
- ...
695
- def __hash__(self) -> int:
696
- """Return hash(self)."""
697
- ...
698
-
699
- @final
700
- class MethodDescriptorType:
701
- @property
702
- def __name__(self) -> str: ...
703
- @property
704
- def __qualname__(self) -> str: ...
705
- @property
706
- def __objclass__(self) -> type: ...
707
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
708
- """Call self as a function."""
709
- ...
710
- def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
711
- """Return an attribute of instance, which is of type owner."""
712
- ...
713
-
714
- @final
715
- class ClassMethodDescriptorType:
716
- @property
717
- def __name__(self) -> str: ...
718
- @property
719
- def __qualname__(self) -> str: ...
720
- @property
721
- def __objclass__(self) -> type: ...
722
- def __call__(self, *args: Any, **kwargs: Any) -> Any:
723
- """Call self as a function."""
724
- ...
725
- def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
726
- """Return an attribute of instance, which is of type owner."""
727
- ...
728
-
729
- @final
730
- class TracebackType:
731
- """Create a new traceback object."""
732
- def __new__(cls, tb_next: TracebackType | None, tb_frame: FrameType, tb_lasti: int, tb_lineno: int) -> Self: ...
733
- tb_next: TracebackType | None
734
- # the rest are read-only
735
- @property
736
- def tb_frame(self) -> FrameType: ...
737
- @property
738
- def tb_lasti(self) -> int: ...
739
- @property
740
- def tb_lineno(self) -> int: ...
741
-
742
- @final
743
- class FrameType:
744
- @property
745
- def f_back(self) -> FrameType | None: ...
746
- @property
747
- def f_builtins(self) -> dict[str, Any]: ...
748
- @property
749
- def f_code(self) -> CodeType: ...
750
- @property
751
- def f_globals(self) -> dict[str, Any]: ...
752
- @property
753
- def f_lasti(self) -> int: ...
754
- # see discussion in #6769: f_lineno *can* sometimes be None,
755
- # but you should probably file a bug report with CPython if you encounter it being None in the wild.
756
- # An `int | None` annotation here causes too many false-positive errors, so applying `int | Any`.
757
- @property
758
- def f_lineno(self) -> int | MaybeNone: ...
759
- @property
760
- def f_locals(self) -> dict[str, Any]: ...
761
- f_trace: Callable[[FrameType, str, Any], Any] | None
762
- f_trace_lines: bool
763
- f_trace_opcodes: bool
764
- def clear(self) -> None:
765
- """F.clear(): clear most references held by the frame"""
766
- ...
767
-
768
- @final
769
- class GetSetDescriptorType:
770
- @property
771
- def __name__(self) -> str: ...
772
- @property
773
- def __qualname__(self) -> str: ...
774
- @property
775
- def __objclass__(self) -> type: ...
776
- def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
777
- """Return an attribute of instance, which is of type owner."""
778
- ...
779
- def __set__(self, instance: Any, value: Any, /) -> None:
780
- """Set an attribute of instance to value."""
781
- ...
782
- def __delete__(self, instance: Any, /) -> None:
783
- """Delete an attribute of instance."""
784
- ...
785
-
786
- @final
787
- class MemberDescriptorType:
788
- @property
789
- def __name__(self) -> str: ...
790
- @property
791
- def __qualname__(self) -> str: ...
792
- @property
793
- def __objclass__(self) -> type: ...
794
- def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
795
- """Return an attribute of instance, which is of type owner."""
796
- ...
797
- def __set__(self, instance: Any, value: Any, /) -> None:
798
- """Set an attribute of instance to value."""
799
- ...
800
- def __delete__(self, instance: Any, /) -> None:
801
- """Delete an attribute of instance."""
802
- ...
803
-
804
- def new_class(
805
- name: str,
806
- bases: Iterable[object] = (),
807
- kwds: dict[str, Any] | None = None,
808
- exec_body: Callable[[dict[str, Any]], object] | None = None,
809
- ) -> type: ...
810
- def resolve_bases(bases: Iterable[object]) -> tuple[Any, ...]: ...
811
- def prepare_class(
812
- name: str, bases: tuple[type, ...] = (), kwds: dict[str, Any] | None = None
813
- ) -> tuple[type, dict[str, Any], dict[str, Any]]: ...
814
-
815
- if sys.version_info >= (3, 12):
816
- def get_original_bases(cls: type, /) -> tuple[Any, ...]: ...
817
-
818
- # Actually a different type, but `property` is special and we want that too.
819
- DynamicClassAttribute = property
820
-
821
- _Fn = TypeVar("_Fn", bound=Callable[..., object])
822
- _R = TypeVar("_R")
823
- _P = ParamSpec("_P")
824
-
825
- # it's not really an Awaitable, but can be used in an await expression. Real type: Generator & Awaitable
826
- @overload
827
- def coroutine(func: Callable[_P, Generator[Any, Any, _R]]) -> Callable[_P, Awaitable[_R]]: ...
828
- @overload
829
- def coroutine(func: _Fn) -> _Fn: ...
830
-
831
- if sys.version_info >= (3, 9):
832
- class GenericAlias:
833
- @property
834
- def __origin__(self) -> type: ...
835
- @property
836
- def __args__(self) -> tuple[Any, ...]: ...
837
- @property
838
- def __parameters__(self) -> tuple[Any, ...]:
839
- """Type variables in the GenericAlias."""
840
- ...
841
- def __new__(cls, origin: type, args: Any) -> Self: ...
842
- def __getitem__(self, typeargs: Any, /) -> GenericAlias:
843
- """Return self[key]."""
844
- ...
845
- def __eq__(self, value: object, /) -> bool:
846
- """Return self==value."""
847
- ...
848
- def __hash__(self) -> int:
849
- """Return hash(self)."""
850
- ...
851
- if sys.version_info >= (3, 11):
852
- @property
853
- def __unpacked__(self) -> bool: ...
854
- @property
855
- def __typing_unpacked_tuple_args__(self) -> tuple[Any, ...] | None: ...
856
- if sys.version_info >= (3, 10):
857
- def __or__(self, value: Any, /) -> UnionType:
858
- """Return self|value."""
859
- ...
860
- def __ror__(self, value: Any, /) -> UnionType:
861
- """Return value|self."""
862
- ...
863
-
864
- # GenericAlias delegates attr access to `__origin__`
865
- def __getattr__(self, name: str) -> Any: ...
866
-
867
- if sys.version_info >= (3, 10):
868
- @final
869
- class NoneType:
870
- """The type of the None singleton."""
871
- def __bool__(self) -> Literal[False]:
872
- """True if self else False"""
873
- ...
874
-
875
- @final
876
- class EllipsisType:
877
- """The type of the Ellipsis singleton."""
878
- ...
879
-
880
- from builtins import _NotImplementedType
881
-
882
- NotImplementedType = _NotImplementedType
883
- @final
884
- class UnionType:
885
- @property
886
- def __args__(self) -> tuple[Any, ...]: ...
887
- def __or__(self, value: Any, /) -> UnionType:
888
- """Return self|value."""
889
- ...
890
- def __ror__(self, value: Any, /) -> UnionType:
891
- """Return value|self."""
892
- ...
893
- def __eq__(self, value: object, /) -> bool:
894
- """Return self==value."""
895
- ...
896
- def __hash__(self) -> int:
897
- """Return hash(self)."""
898
- ...
899
-
900
- if sys.version_info >= (3, 13):
901
- @final
902
- class CapsuleType:
903
- """
904
- Capsule objects let you wrap a C "void *" pointer in a Python
905
- object. They're a way of passing data through the Python interpreter
906
- without creating your own custom type.
907
-
908
- Capsules are used for communication between extension modules.
909
- They provide a way for an extension module to export a C interface
910
- to other extension modules, so that extension modules can use the
911
- Python import mechanism to link to one another.
912
- """
913
- ...
1
+ import sys
2
+ from _typeshed import MaybeNone, SupportsKeysAndGetItem
3
+ from _typeshed.importlib import LoaderProtocol
4
+ from collections.abc import (
5
+ AsyncGenerator,
6
+ Awaitable,
7
+ Callable,
8
+ Coroutine,
9
+ Generator,
10
+ ItemsView,
11
+ Iterable,
12
+ Iterator,
13
+ KeysView,
14
+ MutableSequence,
15
+ ValuesView,
16
+ )
17
+ from importlib.machinery import ModuleSpec
18
+
19
+ # pytype crashes if types.MappingProxyType inherits from collections.abc.Mapping instead of typing.Mapping
20
+ from typing import Any, ClassVar, Literal, Mapping, TypeVar, final, overload # noqa: Y022
21
+ from typing_extensions import ParamSpec, Self, TypeVarTuple, deprecated
22
+
23
+ __all__ = [
24
+ "FunctionType",
25
+ "LambdaType",
26
+ "CodeType",
27
+ "MappingProxyType",
28
+ "SimpleNamespace",
29
+ "GeneratorType",
30
+ "CoroutineType",
31
+ "AsyncGeneratorType",
32
+ "MethodType",
33
+ "BuiltinFunctionType",
34
+ "ModuleType",
35
+ "TracebackType",
36
+ "FrameType",
37
+ "GetSetDescriptorType",
38
+ "MemberDescriptorType",
39
+ "new_class",
40
+ "prepare_class",
41
+ "DynamicClassAttribute",
42
+ "coroutine",
43
+ "BuiltinMethodType",
44
+ "ClassMethodDescriptorType",
45
+ "MethodDescriptorType",
46
+ "MethodWrapperType",
47
+ "WrapperDescriptorType",
48
+ "resolve_bases",
49
+ "CellType",
50
+ ]
51
+
52
+ if sys.version_info >= (3, 9):
53
+ __all__ += ["GenericAlias"]
54
+
55
+ if sys.version_info >= (3, 10):
56
+ __all__ += ["EllipsisType", "NoneType", "NotImplementedType", "UnionType"]
57
+
58
+ if sys.version_info >= (3, 12):
59
+ __all__ += ["get_original_bases"]
60
+
61
+ if sys.version_info >= (3, 13):
62
+ __all__ += ["CapsuleType"]
63
+
64
+ # Note, all classes "defined" here require special handling.
65
+
66
+ _T1 = TypeVar("_T1")
67
+ _T2 = TypeVar("_T2")
68
+ _KT = TypeVar("_KT")
69
+ _VT_co = TypeVar("_VT_co", covariant=True)
70
+
71
+ # Make sure this class definition stays roughly in line with `builtins.function`
72
+ @final
73
+ class FunctionType:
74
+ """
75
+ Create a function object.
76
+
77
+ code
78
+ a code object
79
+ globals
80
+ the globals dictionary
81
+ name
82
+ a string that overrides the name from the code object
83
+ argdefs
84
+ a tuple that specifies the default argument values
85
+ closure
86
+ a tuple that supplies the bindings for free variables
87
+ kwdefaults
88
+ a dictionary that specifies the default keyword argument values
89
+ """
90
+ @property
91
+ def __closure__(self) -> tuple[CellType, ...] | None: ...
92
+ __code__: CodeType
93
+ __defaults__: tuple[Any, ...] | None
94
+ __dict__: dict[str, Any]
95
+ @property
96
+ def __globals__(self) -> dict[str, Any]: ...
97
+ __name__: str
98
+ __qualname__: str
99
+ __annotations__: dict[str, Any]
100
+ __kwdefaults__: dict[str, Any] | None
101
+ if sys.version_info >= (3, 10):
102
+ @property
103
+ def __builtins__(self) -> dict[str, Any]: ...
104
+ if sys.version_info >= (3, 12):
105
+ __type_params__: tuple[TypeVar | ParamSpec | TypeVarTuple, ...]
106
+
107
+ __module__: str
108
+ def __new__(
109
+ cls,
110
+ code: CodeType,
111
+ globals: dict[str, Any],
112
+ name: str | None = ...,
113
+ argdefs: tuple[object, ...] | None = ...,
114
+ closure: tuple[CellType, ...] | None = ...,
115
+ ) -> Self: ...
116
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
117
+ """Call self as a function."""
118
+ ...
119
+ @overload
120
+ def __get__(self, instance: None, owner: type, /) -> FunctionType:
121
+ """Return an attribute of instance, which is of type owner."""
122
+ ...
123
+ @overload
124
+ def __get__(self, instance: object, owner: type | None = None, /) -> MethodType:
125
+ """Return an attribute of instance, which is of type owner."""
126
+ ...
127
+
128
+ LambdaType = FunctionType
129
+
130
+ @final
131
+ class CodeType:
132
+ """Create a code object. Not for the faint of heart."""
133
+ def __eq__(self, value: object, /) -> bool:
134
+ """Return self==value."""
135
+ ...
136
+ def __hash__(self) -> int:
137
+ """Return hash(self)."""
138
+ ...
139
+ @property
140
+ def co_argcount(self) -> int: ...
141
+ @property
142
+ def co_posonlyargcount(self) -> int: ...
143
+ @property
144
+ def co_kwonlyargcount(self) -> int: ...
145
+ @property
146
+ def co_nlocals(self) -> int: ...
147
+ @property
148
+ def co_stacksize(self) -> int: ...
149
+ @property
150
+ def co_flags(self) -> int: ...
151
+ @property
152
+ def co_code(self) -> bytes: ...
153
+ @property
154
+ def co_consts(self) -> tuple[Any, ...]: ...
155
+ @property
156
+ def co_names(self) -> tuple[str, ...]: ...
157
+ @property
158
+ def co_varnames(self) -> tuple[str, ...]: ...
159
+ @property
160
+ def co_filename(self) -> str: ...
161
+ @property
162
+ def co_name(self) -> str: ...
163
+ @property
164
+ def co_firstlineno(self) -> int: ...
165
+ if sys.version_info >= (3, 10):
166
+ @property
167
+ @deprecated("Will be removed in Python 3.14. Use the co_lines() method instead.")
168
+ def co_lnotab(self) -> bytes: ...
169
+ else:
170
+ @property
171
+ def co_lnotab(self) -> bytes: ...
172
+
173
+ @property
174
+ def co_freevars(self) -> tuple[str, ...]: ...
175
+ @property
176
+ def co_cellvars(self) -> tuple[str, ...]: ...
177
+ if sys.version_info >= (3, 10):
178
+ @property
179
+ def co_linetable(self) -> bytes: ...
180
+ def co_lines(self) -> Iterator[tuple[int, int, int | None]]: ...
181
+ if sys.version_info >= (3, 11):
182
+ @property
183
+ def co_exceptiontable(self) -> bytes: ...
184
+ @property
185
+ def co_qualname(self) -> str: ...
186
+ def co_positions(self) -> Iterable[tuple[int | None, int | None, int | None, int | None]]: ...
187
+
188
+ if sys.version_info >= (3, 11):
189
+ def __new__(
190
+ cls,
191
+ argcount: int,
192
+ posonlyargcount: int,
193
+ kwonlyargcount: int,
194
+ nlocals: int,
195
+ stacksize: int,
196
+ flags: int,
197
+ codestring: bytes,
198
+ constants: tuple[object, ...],
199
+ names: tuple[str, ...],
200
+ varnames: tuple[str, ...],
201
+ filename: str,
202
+ name: str,
203
+ qualname: str,
204
+ firstlineno: int,
205
+ linetable: bytes,
206
+ exceptiontable: bytes,
207
+ freevars: tuple[str, ...] = ...,
208
+ cellvars: tuple[str, ...] = ...,
209
+ /,
210
+ ) -> Self: ...
211
+ elif sys.version_info >= (3, 10):
212
+ def __new__(
213
+ cls,
214
+ argcount: int,
215
+ posonlyargcount: int,
216
+ kwonlyargcount: int,
217
+ nlocals: int,
218
+ stacksize: int,
219
+ flags: int,
220
+ codestring: bytes,
221
+ constants: tuple[object, ...],
222
+ names: tuple[str, ...],
223
+ varnames: tuple[str, ...],
224
+ filename: str,
225
+ name: str,
226
+ firstlineno: int,
227
+ linetable: bytes,
228
+ freevars: tuple[str, ...] = ...,
229
+ cellvars: tuple[str, ...] = ...,
230
+ /,
231
+ ) -> Self: ...
232
+ else:
233
+ def __new__(
234
+ cls,
235
+ argcount: int,
236
+ posonlyargcount: int,
237
+ kwonlyargcount: int,
238
+ nlocals: int,
239
+ stacksize: int,
240
+ flags: int,
241
+ codestring: bytes,
242
+ constants: tuple[object, ...],
243
+ names: tuple[str, ...],
244
+ varnames: tuple[str, ...],
245
+ filename: str,
246
+ name: str,
247
+ firstlineno: int,
248
+ lnotab: bytes,
249
+ freevars: tuple[str, ...] = ...,
250
+ cellvars: tuple[str, ...] = ...,
251
+ /,
252
+ ) -> Self: ...
253
+ if sys.version_info >= (3, 11):
254
+ def replace(
255
+ self,
256
+ *,
257
+ co_argcount: int = -1,
258
+ co_posonlyargcount: int = -1,
259
+ co_kwonlyargcount: int = -1,
260
+ co_nlocals: int = -1,
261
+ co_stacksize: int = -1,
262
+ co_flags: int = -1,
263
+ co_firstlineno: int = -1,
264
+ co_code: bytes = ...,
265
+ co_consts: tuple[object, ...] = ...,
266
+ co_names: tuple[str, ...] = ...,
267
+ co_varnames: tuple[str, ...] = ...,
268
+ co_freevars: tuple[str, ...] = ...,
269
+ co_cellvars: tuple[str, ...] = ...,
270
+ co_filename: str = ...,
271
+ co_name: str = ...,
272
+ co_qualname: str = ...,
273
+ co_linetable: bytes = ...,
274
+ co_exceptiontable: bytes = ...,
275
+ ) -> Self:
276
+ """Return a copy of the code object with new values for the specified fields."""
277
+ ...
278
+ elif sys.version_info >= (3, 10):
279
+ def replace(
280
+ self,
281
+ *,
282
+ co_argcount: int = -1,
283
+ co_posonlyargcount: int = -1,
284
+ co_kwonlyargcount: int = -1,
285
+ co_nlocals: int = -1,
286
+ co_stacksize: int = -1,
287
+ co_flags: int = -1,
288
+ co_firstlineno: int = -1,
289
+ co_code: bytes = ...,
290
+ co_consts: tuple[object, ...] = ...,
291
+ co_names: tuple[str, ...] = ...,
292
+ co_varnames: tuple[str, ...] = ...,
293
+ co_freevars: tuple[str, ...] = ...,
294
+ co_cellvars: tuple[str, ...] = ...,
295
+ co_filename: str = ...,
296
+ co_name: str = ...,
297
+ co_linetable: bytes = ...,
298
+ ) -> Self: ...
299
+ else:
300
+ def replace(
301
+ self,
302
+ *,
303
+ co_argcount: int = -1,
304
+ co_posonlyargcount: int = -1,
305
+ co_kwonlyargcount: int = -1,
306
+ co_nlocals: int = -1,
307
+ co_stacksize: int = -1,
308
+ co_flags: int = -1,
309
+ co_firstlineno: int = -1,
310
+ co_code: bytes = ...,
311
+ co_consts: tuple[object, ...] = ...,
312
+ co_names: tuple[str, ...] = ...,
313
+ co_varnames: tuple[str, ...] = ...,
314
+ co_freevars: tuple[str, ...] = ...,
315
+ co_cellvars: tuple[str, ...] = ...,
316
+ co_filename: str = ...,
317
+ co_name: str = ...,
318
+ co_lnotab: bytes = ...,
319
+ ) -> Self: ...
320
+
321
+ if sys.version_info >= (3, 13):
322
+ __replace__ = replace
323
+
324
+ @final
325
+ class MappingProxyType(Mapping[_KT, _VT_co]):
326
+ """Read-only proxy of a mapping."""
327
+ __hash__: ClassVar[None] # type: ignore[assignment]
328
+ def __new__(cls, mapping: SupportsKeysAndGetItem[_KT, _VT_co]) -> Self: ...
329
+ def __getitem__(self, key: _KT, /) -> _VT_co:
330
+ """Return self[key]."""
331
+ ...
332
+ def __iter__(self) -> Iterator[_KT]:
333
+ """Implement iter(self)."""
334
+ ...
335
+ def __len__(self) -> int:
336
+ """Return len(self)."""
337
+ ...
338
+ def __eq__(self, value: object, /) -> bool:
339
+ """Return self==value."""
340
+ ...
341
+ def copy(self) -> dict[_KT, _VT_co]:
342
+ """D.copy() -> a shallow copy of D"""
343
+ ...
344
+ def keys(self) -> KeysView[_KT]:
345
+ """D.keys() -> a set-like object providing a view on D's keys"""
346
+ ...
347
+ def values(self) -> ValuesView[_VT_co]:
348
+ """D.values() -> an object providing a view on D's values"""
349
+ ...
350
+ def items(self) -> ItemsView[_KT, _VT_co]:
351
+ """D.items() -> a set-like object providing a view on D's items"""
352
+ ...
353
+ @overload
354
+ def get(self, key: _KT, /) -> _VT_co | None:
355
+ """Return the value for key if key is in the mapping, else default."""
356
+ ...
357
+ @overload
358
+ def get(self, key: _KT, default: _VT_co | _T2, /) -> _VT_co | _T2:
359
+ """Return the value for key if key is in the mapping, else default."""
360
+ ...
361
+ if sys.version_info >= (3, 9):
362
+ def __class_getitem__(cls, item: Any, /) -> GenericAlias:
363
+ """See PEP 585"""
364
+ ...
365
+ def __reversed__(self) -> Iterator[_KT]:
366
+ """D.__reversed__() -> reverse iterator"""
367
+ ...
368
+ def __or__(self, value: Mapping[_T1, _T2], /) -> dict[_KT | _T1, _VT_co | _T2]:
369
+ """Return self|value."""
370
+ ...
371
+ def __ror__(self, value: Mapping[_T1, _T2], /) -> dict[_KT | _T1, _VT_co | _T2]:
372
+ """Return value|self."""
373
+ ...
374
+
375
+ class SimpleNamespace:
376
+ __hash__: ClassVar[None] # type: ignore[assignment]
377
+ if sys.version_info >= (3, 13):
378
+ def __init__(self, mapping_or_iterable: Mapping[str, Any] | Iterable[tuple[str, Any]] = (), /, **kwargs: Any) -> None: ...
379
+ else:
380
+ def __init__(self, **kwargs: Any) -> None: ...
381
+
382
+ def __eq__(self, value: object, /) -> bool:
383
+ """Return self==value."""
384
+ ...
385
+ def __getattribute__(self, name: str, /) -> Any:
386
+ """Return getattr(self, name)."""
387
+ ...
388
+ def __setattr__(self, name: str, value: Any, /) -> None:
389
+ """Implement setattr(self, name, value)."""
390
+ ...
391
+ def __delattr__(self, name: str, /) -> None:
392
+ """Implement delattr(self, name)."""
393
+ ...
394
+ if sys.version_info >= (3, 13):
395
+ def __replace__(self, **kwargs: Any) -> Self:
396
+ """Return a copy of the namespace object with new values for the specified attributes."""
397
+ ...
398
+
399
+ class ModuleType:
400
+ """
401
+ Create a module object.
402
+
403
+ The name must be a string; the optional doc argument can have any type.
404
+ """
405
+ __name__: str
406
+ __file__: str | None
407
+ @property
408
+ def __dict__(self) -> dict[str, Any]: ... # type: ignore[override]
409
+ __loader__: LoaderProtocol | None
410
+ __package__: str | None
411
+ __path__: MutableSequence[str]
412
+ __spec__: ModuleSpec | None
413
+ # N.B. Although this is the same type as `builtins.object.__doc__`,
414
+ # it is deliberately redeclared here. Most symbols declared in the namespace
415
+ # of `types.ModuleType` are available as "implicit globals" within a module's
416
+ # namespace, but this is not true for symbols declared in the namespace of `builtins.object`.
417
+ # Redeclaring `__doc__` here helps some type checkers understand that `__doc__` is available
418
+ # as an implicit global in all modules, similar to `__name__`, `__file__`, `__spec__`, etc.
419
+ __doc__: str | None
420
+ def __init__(self, name: str, doc: str | None = ...) -> None: ...
421
+ # __getattr__ doesn't exist at runtime,
422
+ # but having it here in typeshed makes dynamic imports
423
+ # using `builtins.__import__` or `importlib.import_module` less painful
424
+ def __getattr__(self, name: str) -> Any: ...
425
+
426
+ @final
427
+ class CellType:
428
+ """
429
+ Create a new cell object.
430
+
431
+ contents
432
+ the contents of the cell. If not specified, the cell will be empty,
433
+ and
434
+ further attempts to access its cell_contents attribute will
435
+ raise a ValueError.
436
+ """
437
+ def __new__(cls, contents: object = ..., /) -> Self: ...
438
+ __hash__: ClassVar[None] # type: ignore[assignment]
439
+ cell_contents: Any
440
+
441
+ _YieldT_co = TypeVar("_YieldT_co", covariant=True)
442
+ _SendT_contra = TypeVar("_SendT_contra", contravariant=True)
443
+ _ReturnT_co = TypeVar("_ReturnT_co", covariant=True)
444
+
445
+ @final
446
+ class GeneratorType(Generator[_YieldT_co, _SendT_contra, _ReturnT_co]):
447
+ @property
448
+ def gi_yieldfrom(self) -> GeneratorType[_YieldT_co, _SendT_contra, Any] | None:
449
+ """object being iterated by yield from, or None"""
450
+ ...
451
+ if sys.version_info >= (3, 11):
452
+ @property
453
+ def gi_suspended(self) -> bool: ...
454
+ __name__: str
455
+ __qualname__: str
456
+ def __iter__(self) -> Self:
457
+ """Implement iter(self)."""
458
+ ...
459
+ def __next__(self) -> _YieldT_co:
460
+ """Implement next(self)."""
461
+ ...
462
+ def send(self, arg: _SendT_contra, /) -> _YieldT_co:
463
+ """
464
+ send(arg) -> send 'arg' into generator,
465
+ return next yielded value or raise StopIteration.
466
+ """
467
+ ...
468
+ @overload
469
+ def throw(
470
+ self, typ: type[BaseException], val: BaseException | object = ..., tb: TracebackType | None = ..., /
471
+ ) -> _YieldT_co:
472
+ """
473
+ throw(value)
474
+ throw(type[,value[,tb]])
475
+
476
+ Raise exception in generator, return next yielded value or raise
477
+ StopIteration.
478
+ the (type, val, tb) signature is deprecated,
479
+ and may be removed in a future version of Python.
480
+ """
481
+ ...
482
+ @overload
483
+ def throw(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co:
484
+ """
485
+ throw(value)
486
+ throw(type[,value[,tb]])
487
+
488
+ Raise exception in generator, return next yielded value or raise
489
+ StopIteration.
490
+ the (type, val, tb) signature is deprecated,
491
+ and may be removed in a future version of Python.
492
+ """
493
+ ...
494
+ if sys.version_info >= (3, 13):
495
+ def __class_getitem__(cls, item: Any, /) -> Any:
496
+ """See PEP 585"""
497
+ ...
498
+
499
+ @final
500
+ class AsyncGeneratorType(AsyncGenerator[_YieldT_co, _SendT_contra]):
501
+ @property
502
+ def ag_await(self) -> Awaitable[Any] | None:
503
+ """object being awaited on, or None"""
504
+ ...
505
+ __name__: str
506
+ __qualname__: str
507
+ if sys.version_info >= (3, 12):
508
+ @property
509
+ def ag_suspended(self) -> bool: ...
510
+
511
+ def __aiter__(self) -> Self:
512
+ """Return an awaitable, that resolves in asynchronous iterator."""
513
+ ...
514
+ def __anext__(self) -> Coroutine[Any, Any, _YieldT_co]:
515
+ """Return a value or raise StopAsyncIteration."""
516
+ ...
517
+ def asend(self, val: _SendT_contra, /) -> Coroutine[Any, Any, _YieldT_co]:
518
+ """asend(v) -> send 'v' in generator."""
519
+ ...
520
+ @overload
521
+ async def athrow(
522
+ self, typ: type[BaseException], val: BaseException | object = ..., tb: TracebackType | None = ..., /
523
+ ) -> _YieldT_co:
524
+ """
525
+ athrow(value)
526
+ athrow(type[,value[,tb]])
527
+
528
+ raise exception in generator.
529
+ the (type, val, tb) signature is deprecated,
530
+ and may be removed in a future version of Python.
531
+ """
532
+ ...
533
+ @overload
534
+ async def athrow(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co:
535
+ """
536
+ athrow(value)
537
+ athrow(type[,value[,tb]])
538
+
539
+ raise exception in generator.
540
+ the (type, val, tb) signature is deprecated,
541
+ and may be removed in a future version of Python.
542
+ """
543
+ ...
544
+ def aclose(self) -> Coroutine[Any, Any, None]:
545
+ """aclose() -> raise GeneratorExit inside generator."""
546
+ ...
547
+ if sys.version_info >= (3, 9):
548
+ def __class_getitem__(cls, item: Any, /) -> GenericAlias:
549
+ """See PEP 585"""
550
+ ...
551
+
552
+ @final
553
+ class CoroutineType(Coroutine[_YieldT_co, _SendT_contra, _ReturnT_co]):
554
+ __name__: str
555
+ __qualname__: str
556
+ @property
557
+ def cr_origin(self) -> tuple[tuple[str, int, str], ...] | None: ...
558
+ if sys.version_info >= (3, 11):
559
+ @property
560
+ def cr_suspended(self) -> bool: ...
561
+
562
+ def close(self) -> None:
563
+ """close() -> raise GeneratorExit inside coroutine."""
564
+ ...
565
+ def __await__(self) -> Generator[Any, None, _ReturnT_co]:
566
+ """Return an iterator to be used in await expression."""
567
+ ...
568
+ def send(self, arg: _SendT_contra, /) -> _YieldT_co:
569
+ """
570
+ send(arg) -> send 'arg' into coroutine,
571
+ return next iterated value or raise StopIteration.
572
+ """
573
+ ...
574
+ @overload
575
+ def throw(
576
+ self, typ: type[BaseException], val: BaseException | object = ..., tb: TracebackType | None = ..., /
577
+ ) -> _YieldT_co:
578
+ """
579
+ throw(value)
580
+ throw(type[,value[,traceback]])
581
+
582
+ Raise exception in coroutine, return next iterated value or raise
583
+ StopIteration.
584
+ the (type, val, tb) signature is deprecated,
585
+ and may be removed in a future version of Python.
586
+ """
587
+ ...
588
+ @overload
589
+ def throw(self, typ: BaseException, val: None = None, tb: TracebackType | None = ..., /) -> _YieldT_co:
590
+ """
591
+ throw(value)
592
+ throw(type[,value[,traceback]])
593
+
594
+ Raise exception in coroutine, return next iterated value or raise
595
+ StopIteration.
596
+ the (type, val, tb) signature is deprecated,
597
+ and may be removed in a future version of Python.
598
+ """
599
+ ...
600
+ if sys.version_info >= (3, 13):
601
+ def __class_getitem__(cls, item: Any, /) -> Any:
602
+ """See PEP 585"""
603
+ ...
604
+
605
+ @final
606
+ class MethodType:
607
+ """Create a bound instance method object."""
608
+ @property
609
+ def __closure__(self) -> tuple[CellType, ...] | None: ... # inherited from the added function
610
+ @property
611
+ def __code__(self) -> CodeType: ... # inherited from the added function
612
+ @property
613
+ def __defaults__(self) -> tuple[Any, ...] | None: ... # inherited from the added function
614
+ @property
615
+ def __func__(self) -> Callable[..., Any]:
616
+ """the function (or other callable) implementing a method"""
617
+ ...
618
+ @property
619
+ def __self__(self) -> object:
620
+ """the instance to which a method is bound"""
621
+ ...
622
+ @property
623
+ def __name__(self) -> str: ... # inherited from the added function
624
+ @property
625
+ def __qualname__(self) -> str: ... # inherited from the added function
626
+ def __new__(cls, func: Callable[..., Any], obj: object, /) -> Self: ...
627
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
628
+ """Call self as a function."""
629
+ ...
630
+ def __eq__(self, value: object, /) -> bool:
631
+ """Return self==value."""
632
+ ...
633
+ def __hash__(self) -> int:
634
+ """Return hash(self)."""
635
+ ...
636
+
637
+ @final
638
+ class BuiltinFunctionType:
639
+ @property
640
+ def __self__(self) -> object | ModuleType: ...
641
+ @property
642
+ def __name__(self) -> str: ...
643
+ @property
644
+ def __qualname__(self) -> str: ...
645
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
646
+ """Call self as a function."""
647
+ ...
648
+ def __eq__(self, value: object, /) -> bool:
649
+ """Return self==value."""
650
+ ...
651
+ def __hash__(self) -> int:
652
+ """Return hash(self)."""
653
+ ...
654
+
655
+ BuiltinMethodType = BuiltinFunctionType
656
+
657
+ @final
658
+ class WrapperDescriptorType:
659
+ @property
660
+ def __name__(self) -> str: ...
661
+ @property
662
+ def __qualname__(self) -> str: ...
663
+ @property
664
+ def __objclass__(self) -> type: ...
665
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
666
+ """Call self as a function."""
667
+ ...
668
+ def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
669
+ """Return an attribute of instance, which is of type owner."""
670
+ ...
671
+
672
+ @final
673
+ class MethodWrapperType:
674
+ @property
675
+ def __self__(self) -> object: ...
676
+ @property
677
+ def __name__(self) -> str: ...
678
+ @property
679
+ def __qualname__(self) -> str: ...
680
+ @property
681
+ def __objclass__(self) -> type: ...
682
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
683
+ """Call self as a function."""
684
+ ...
685
+ def __eq__(self, value: object, /) -> bool:
686
+ """Return self==value."""
687
+ ...
688
+ def __ne__(self, value: object, /) -> bool:
689
+ """Return self!=value."""
690
+ ...
691
+ def __hash__(self) -> int:
692
+ """Return hash(self)."""
693
+ ...
694
+
695
+ @final
696
+ class MethodDescriptorType:
697
+ @property
698
+ def __name__(self) -> str: ...
699
+ @property
700
+ def __qualname__(self) -> str: ...
701
+ @property
702
+ def __objclass__(self) -> type: ...
703
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
704
+ """Call self as a function."""
705
+ ...
706
+ def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
707
+ """Return an attribute of instance, which is of type owner."""
708
+ ...
709
+
710
+ @final
711
+ class ClassMethodDescriptorType:
712
+ @property
713
+ def __name__(self) -> str: ...
714
+ @property
715
+ def __qualname__(self) -> str: ...
716
+ @property
717
+ def __objclass__(self) -> type: ...
718
+ def __call__(self, *args: Any, **kwargs: Any) -> Any:
719
+ """Call self as a function."""
720
+ ...
721
+ def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
722
+ """Return an attribute of instance, which is of type owner."""
723
+ ...
724
+
725
+ @final
726
+ class TracebackType:
727
+ """Create a new traceback object."""
728
+ def __new__(cls, tb_next: TracebackType | None, tb_frame: FrameType, tb_lasti: int, tb_lineno: int) -> Self: ...
729
+ tb_next: TracebackType | None
730
+ # the rest are read-only
731
+ @property
732
+ def tb_frame(self) -> FrameType: ...
733
+ @property
734
+ def tb_lasti(self) -> int: ...
735
+ @property
736
+ def tb_lineno(self) -> int: ...
737
+
738
+ @final
739
+ class FrameType:
740
+ @property
741
+ def f_back(self) -> FrameType | None: ...
742
+ @property
743
+ def f_builtins(self) -> dict[str, Any]: ...
744
+ @property
745
+ def f_code(self) -> CodeType: ...
746
+ @property
747
+ def f_globals(self) -> dict[str, Any]: ...
748
+ @property
749
+ def f_lasti(self) -> int: ...
750
+ # see discussion in #6769: f_lineno *can* sometimes be None,
751
+ # but you should probably file a bug report with CPython if you encounter it being None in the wild.
752
+ # An `int | None` annotation here causes too many false-positive errors, so applying `int | Any`.
753
+ @property
754
+ def f_lineno(self) -> int | MaybeNone: ...
755
+ @property
756
+ def f_locals(self) -> dict[str, Any]: ...
757
+ f_trace: Callable[[FrameType, str, Any], Any] | None
758
+ f_trace_lines: bool
759
+ f_trace_opcodes: bool
760
+ def clear(self) -> None:
761
+ """F.clear(): clear most references held by the frame"""
762
+ ...
763
+
764
+ @final
765
+ class GetSetDescriptorType:
766
+ @property
767
+ def __name__(self) -> str: ...
768
+ @property
769
+ def __qualname__(self) -> str: ...
770
+ @property
771
+ def __objclass__(self) -> type: ...
772
+ def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
773
+ """Return an attribute of instance, which is of type owner."""
774
+ ...
775
+ def __set__(self, instance: Any, value: Any, /) -> None:
776
+ """Set an attribute of instance to value."""
777
+ ...
778
+ def __delete__(self, instance: Any, /) -> None:
779
+ """Delete an attribute of instance."""
780
+ ...
781
+
782
+ @final
783
+ class MemberDescriptorType:
784
+ @property
785
+ def __name__(self) -> str: ...
786
+ @property
787
+ def __qualname__(self) -> str: ...
788
+ @property
789
+ def __objclass__(self) -> type: ...
790
+ def __get__(self, instance: Any, owner: type | None = None, /) -> Any:
791
+ """Return an attribute of instance, which is of type owner."""
792
+ ...
793
+ def __set__(self, instance: Any, value: Any, /) -> None:
794
+ """Set an attribute of instance to value."""
795
+ ...
796
+ def __delete__(self, instance: Any, /) -> None:
797
+ """Delete an attribute of instance."""
798
+ ...
799
+
800
+ def new_class(
801
+ name: str,
802
+ bases: Iterable[object] = (),
803
+ kwds: dict[str, Any] | None = None,
804
+ exec_body: Callable[[dict[str, Any]], object] | None = None,
805
+ ) -> type: ...
806
+ def resolve_bases(bases: Iterable[object]) -> tuple[Any, ...]: ...
807
+ def prepare_class(
808
+ name: str, bases: tuple[type, ...] = (), kwds: dict[str, Any] | None = None
809
+ ) -> tuple[type, dict[str, Any], dict[str, Any]]: ...
810
+
811
+ if sys.version_info >= (3, 12):
812
+ def get_original_bases(cls: type, /) -> tuple[Any, ...]: ...
813
+
814
+ # Actually a different type, but `property` is special and we want that too.
815
+ DynamicClassAttribute = property
816
+
817
+ _Fn = TypeVar("_Fn", bound=Callable[..., object])
818
+ _R = TypeVar("_R")
819
+ _P = ParamSpec("_P")
820
+
821
+ # it's not really an Awaitable, but can be used in an await expression. Real type: Generator & Awaitable
822
+ @overload
823
+ def coroutine(func: Callable[_P, Generator[Any, Any, _R]]) -> Callable[_P, Awaitable[_R]]: ...
824
+ @overload
825
+ def coroutine(func: _Fn) -> _Fn: ...
826
+
827
+ if sys.version_info >= (3, 9):
828
+ class GenericAlias:
829
+ @property
830
+ def __origin__(self) -> type: ...
831
+ @property
832
+ def __args__(self) -> tuple[Any, ...]: ...
833
+ @property
834
+ def __parameters__(self) -> tuple[Any, ...]:
835
+ """Type variables in the GenericAlias."""
836
+ ...
837
+ def __new__(cls, origin: type, args: Any) -> Self: ...
838
+ def __getitem__(self, typeargs: Any, /) -> GenericAlias:
839
+ """Return self[key]."""
840
+ ...
841
+ def __eq__(self, value: object, /) -> bool:
842
+ """Return self==value."""
843
+ ...
844
+ def __hash__(self) -> int:
845
+ """Return hash(self)."""
846
+ ...
847
+ if sys.version_info >= (3, 11):
848
+ @property
849
+ def __unpacked__(self) -> bool: ...
850
+ @property
851
+ def __typing_unpacked_tuple_args__(self) -> tuple[Any, ...] | None: ...
852
+ if sys.version_info >= (3, 10):
853
+ def __or__(self, value: Any, /) -> UnionType:
854
+ """Return self|value."""
855
+ ...
856
+ def __ror__(self, value: Any, /) -> UnionType:
857
+ """Return value|self."""
858
+ ...
859
+
860
+ # GenericAlias delegates attr access to `__origin__`
861
+ def __getattr__(self, name: str) -> Any: ...
862
+
863
+ if sys.version_info >= (3, 10):
864
+ @final
865
+ class NoneType:
866
+ """The type of the None singleton."""
867
+ def __bool__(self) -> Literal[False]:
868
+ """True if self else False"""
869
+ ...
870
+
871
+ @final
872
+ class EllipsisType:
873
+ """The type of the Ellipsis singleton."""
874
+ ...
875
+
876
+ from builtins import _NotImplementedType
877
+
878
+ NotImplementedType = _NotImplementedType
879
+ @final
880
+ class UnionType:
881
+ @property
882
+ def __args__(self) -> tuple[Any, ...]: ...
883
+ def __or__(self, value: Any, /) -> UnionType:
884
+ """Return self|value."""
885
+ ...
886
+ def __ror__(self, value: Any, /) -> UnionType:
887
+ """Return value|self."""
888
+ ...
889
+ def __eq__(self, value: object, /) -> bool:
890
+ """Return self==value."""
891
+ ...
892
+ def __hash__(self) -> int:
893
+ """Return hash(self)."""
894
+ ...
895
+
896
+ if sys.version_info >= (3, 13):
897
+ @final
898
+ class CapsuleType:
899
+ """
900
+ Capsule objects let you wrap a C "void *" pointer in a Python
901
+ object. They're a way of passing data through the Python interpreter
902
+ without creating your own custom type.
903
+
904
+ Capsules are used for communication between extension modules.
905
+ They provide a way for an extension module to export a C interface
906
+ to other extension modules, so that extension modules can use the
907
+ Python import mechanism to link to one another.
908
+ """
909
+ ...