basedpyright 1.25.0 → 1.26.0
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.
- package/dist/pyright-langserver.js +1 -1
- package/dist/pyright-langserver.js.map +1 -1
- package/dist/pyright.js +1 -1
- package/dist/pyright.js.map +1 -1
- package/dist/typeshed-fallback/README.md +1 -1
- package/dist/typeshed-fallback/commit.txt +1 -1
- package/dist/typeshed-fallback/stdlib/VERSIONS +1 -0
- package/dist/typeshed-fallback/stdlib/_asyncio.pyi +3 -3
- package/dist/typeshed-fallback/stdlib/_blake2.pyi +12 -12
- package/dist/typeshed-fallback/stdlib/_bz2.pyi +7 -1
- package/dist/typeshed-fallback/stdlib/_collections_abc.pyi +3 -0
- package/dist/typeshed-fallback/stdlib/_contextvars.pyi +5 -3
- package/dist/typeshed-fallback/stdlib/_csv.pyi +4 -4
- package/dist/typeshed-fallback/stdlib/_ctypes.pyi +7 -7
- package/dist/typeshed-fallback/stdlib/_curses.pyi +3 -3
- package/dist/typeshed-fallback/stdlib/_dummy_threading.pyi +19 -127
- package/dist/typeshed-fallback/stdlib/_frozen_importlib.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/_interpqueues.pyi +9 -6
- package/dist/typeshed-fallback/stdlib/_interpreters.pyi +3 -1
- package/dist/typeshed-fallback/stdlib/_io.pyi +1 -1
- package/dist/typeshed-fallback/stdlib/_json.pyi +5 -4
- package/dist/typeshed-fallback/stdlib/_lzma.pyi +16 -5
- package/dist/typeshed-fallback/stdlib/_pickle.pyi +286 -0
- package/dist/typeshed-fallback/stdlib/_sitebuiltins.pyi +3 -2
- package/dist/typeshed-fallback/stdlib/_socket.pyi +3 -1
- package/dist/typeshed-fallback/stdlib/_ssl.pyi +3 -4
- package/dist/typeshed-fallback/stdlib/_thread.pyi +87 -39
- package/dist/typeshed-fallback/stdlib/_tkinter.pyi +35 -20
- package/dist/typeshed-fallback/stdlib/_weakrefset.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/argparse.pyi +27 -20
- package/dist/typeshed-fallback/stdlib/array.pyi +13 -10
- package/dist/typeshed-fallback/stdlib/ast.pyi +24 -7
- package/dist/typeshed-fallback/stdlib/asyncio/__init__.pyi +1300 -0
- package/dist/typeshed-fallback/stdlib/asyncio/base_events.pyi +2 -0
- package/dist/typeshed-fallback/stdlib/asyncio/coroutines.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/events.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/exceptions.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/futures.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/locks.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/proactor_events.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/protocols.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/queues.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/runners.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/selector_events.pyi +2 -0
- package/dist/typeshed-fallback/stdlib/asyncio/streams.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/subprocess.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/taskgroups.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/tasks.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/threads.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/timeouts.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/transports.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/asyncio/unix_events.pyi +3 -0
- package/dist/typeshed-fallback/stdlib/asyncio/windows_events.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/builtins.pyi +21 -15
- package/dist/typeshed-fallback/stdlib/codecs.pyi +2 -0
- package/dist/typeshed-fallback/stdlib/codeop.pyi +5 -1
- package/dist/typeshed-fallback/stdlib/collections/__init__.pyi +3 -1
- package/dist/typeshed-fallback/stdlib/concurrent/futures/process.pyi +12 -2
- package/dist/typeshed-fallback/stdlib/contextlib.pyi +21 -22
- package/dist/typeshed-fallback/stdlib/ctypes/__init__.pyi +69 -18
- package/dist/typeshed-fallback/stdlib/dataclasses.pyi +11 -3
- package/dist/typeshed-fallback/stdlib/datetime.pyi +1 -1
- package/dist/typeshed-fallback/stdlib/decimal.pyi +0 -1
- package/dist/typeshed-fallback/stdlib/email/charset.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/email/header.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/email/headerregistry.pyi +2 -0
- package/dist/typeshed-fallback/stdlib/fractions.pyi +3 -3
- package/dist/typeshed-fallback/stdlib/gzip.pyi +5 -5
- package/dist/typeshed-fallback/stdlib/http/__init__.pyi +15 -6
- package/dist/typeshed-fallback/stdlib/http/client.pyi +80 -58
- package/dist/typeshed-fallback/stdlib/inspect.pyi +5 -5
- package/dist/typeshed-fallback/stdlib/ipaddress.pyi +5 -3
- package/dist/typeshed-fallback/stdlib/itertools.pyi +12 -12
- package/dist/typeshed-fallback/stdlib/json/scanner.pyi +4 -0
- package/dist/typeshed-fallback/stdlib/lib2to3/pgen2/pgen.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/lib2to3/pytree.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/mmap.pyi +6 -6
- package/dist/typeshed-fallback/stdlib/multiprocessing/managers.pyi +63 -17
- package/dist/typeshed-fallback/stdlib/multiprocessing/pool.pyi +3 -0
- package/dist/typeshed-fallback/stdlib/multiprocessing/reduction.pyi +1 -1
- package/dist/typeshed-fallback/stdlib/multiprocessing/synchronize.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/numbers.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/operator.pyi +2 -2
- package/dist/typeshed-fallback/stdlib/optparse.pyi +89 -32
- package/dist/typeshed-fallback/stdlib/os/__init__.pyi +1 -0
- package/dist/typeshed-fallback/stdlib/parser.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/pickle.pyi +51 -266
- package/dist/typeshed-fallback/stdlib/pickletools.pyi +8 -1
- package/dist/typeshed-fallback/stdlib/plistlib.pyi +2 -1
- package/dist/typeshed-fallback/stdlib/sched.pyi +3 -2
- package/dist/typeshed-fallback/stdlib/select.pyi +19 -13
- package/dist/typeshed-fallback/stdlib/selectors.pyi +5 -3
- package/dist/typeshed-fallback/stdlib/signal.pyi +47 -47
- package/dist/typeshed-fallback/stdlib/socket.pyi +8 -6
- package/dist/typeshed-fallback/stdlib/sqlite3/__init__.pyi +1 -1
- package/dist/typeshed-fallback/stdlib/ssl.pyi +4 -0
- package/dist/typeshed-fallback/stdlib/sys/__init__.pyi +9 -3
- package/dist/typeshed-fallback/stdlib/tarfile.pyi +24 -10
- package/dist/typeshed-fallback/stdlib/telnetlib.pyi +2 -2
- package/dist/typeshed-fallback/stdlib/threading.pyi +6 -53
- package/dist/typeshed-fallback/stdlib/tkinter/__init__.pyi +193 -3
- package/dist/typeshed-fallback/stdlib/tkinter/filedialog.pyi +9 -9
- package/dist/typeshed-fallback/stdlib/tkinter/font.pyi +5 -4
- package/dist/typeshed-fallback/stdlib/token.pyi +1 -1
- package/dist/typeshed-fallback/stdlib/tokenize.pyi +3 -4
- package/dist/typeshed-fallback/stdlib/traceback.pyi +17 -4
- package/dist/typeshed-fallback/stdlib/types.pyi +45 -10
- package/dist/typeshed-fallback/stdlib/typing.pyi +45 -47
- package/dist/typeshed-fallback/stdlib/typing_extensions.pyi +53 -12
- package/dist/typeshed-fallback/stdlib/unittest/mock.pyi +3 -1
- package/dist/typeshed-fallback/stdlib/unittest/runner.pyi +11 -12
- package/dist/typeshed-fallback/stdlib/unittest/suite.pyi +2 -0
- package/dist/typeshed-fallback/stdlib/weakref.pyi +19 -5
- package/dist/typeshed-fallback/stdlib/xml/dom/minidom.pyi +5 -4
- package/dist/typeshed-fallback/stdlib/xml/sax/expatreader.pyi +53 -0
- package/dist/typeshed-fallback/stdlib/xmlrpc/client.pyi +4 -3
- package/dist/typeshed-fallback/stdlib/xxlimited.pyi +4 -2
- package/dist/typeshed-fallback/stdlib/zipfile/_path/glob.pyi +22 -0
- package/dist/typeshed-fallback/stdlib/zoneinfo/__init__.pyi +1 -1
- package/dist/typeshed-fallback/stubs/Authlib/METADATA.toml +7 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/common/encoding.pyi +10 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/common/errors.pyi +26 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/common/security.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/common/urls.pyi +19 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/consts.pyi +8 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/deprecate.pyi +7 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/__init__.pyi +0 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/__init__.pyi +29 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/async_app.pyi +16 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/async_openid.pyi +8 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/errors.pyi +23 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/framework_integration.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/registry.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/sync_app.pyi +93 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/integrations/base_client/sync_openid.pyi +7 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/__init__.pyi +44 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/drafts/__init__.pyi +3 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/drafts/_jwe_algorithms.pyi +27 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/drafts/_jwe_enc_cryptodome.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/drafts/_jwe_enc_cryptography.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/errors.pyi +72 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/jwk.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7515/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7515/jws.pyi +14 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7515/models.pyi +25 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7516/__init__.pyi +9 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7516/jwe.pyi +23 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7516/models.pyi +56 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7517/__init__.pyi +7 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7517/_cryptography_key.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7517/asymmetric_key.pyi +39 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7517/base_key.pyi +28 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7517/jwk.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7517/key_set.pyi +10 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/__init__.pyi +20 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/ec_key.pyi +24 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/jwe_algs.pyi +64 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/jwe_encs.pyi +27 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/jwe_zips.pyi +9 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/jws_algs.pyi +63 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/oct_key.pyi +23 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/rsa_key.pyi +23 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7518/util.pyi +2 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7519/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7519/claims.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc7519/jwt.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc8037/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc8037/jws_eddsa.pyi +10 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/rfc8037/okp_key.pyi +24 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/jose/util.pyi +3 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/__init__.pyi +33 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/client.pyi +39 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/errors.pyi +1 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/__init__.pyi +35 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/authorization_server.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/base_server.pyi +12 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/client_auth.pyi +41 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/errors.pyi +56 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/models.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/parameters.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/resource_protector.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/rsa.pyi +2 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/signature.pyi +22 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/util.pyi +2 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth1/rfc5849/wrapper.pyi +33 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/__init__.pyi +22 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/auth.pyi +24 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/base.pyi +20 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/client.pyi +96 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/__init__.pyi +76 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/authenticate_client.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/authorization_server.pyi +46 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/errors.pyi +92 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/__init__.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/authorization_code.pyi +24 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/base.pyi +55 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/client_credentials.pyi +6 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/implicit.pyi +12 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/refresh_token.pyi +15 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/grants/resource_owner_password_credentials.pyi +7 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/models.pyi +22 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/parameters.pyi +14 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/requests.pyi +48 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/resource_protector.pyi +19 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/token_endpoint.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/util.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6749/wrappers.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6750/__init__.pyi +15 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6750/errors.pyi +27 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6750/parameters.pyi +6 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6750/token.pyi +41 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc6750/validator.pyi +6 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7009/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7009/parameters.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7009/revocation.pyi +9 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7521/__init__.pyi +3 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7521/client.pyi +39 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/__init__.pyi +18 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/assertion.pyi +19 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/auth.pyi +22 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/client.pyi +16 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/jwt_bearer.pyi +28 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/token.pyi +30 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7523/validator.pyi +24 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7591/__init__.pyi +17 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7591/claims.pyi +22 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7591/endpoint.pyi +24 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7591/errors.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7592/__init__.pyi +3 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7592/endpoint.pyi +26 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7636/__init__.pyi +3 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7636/challenge.pyi +20 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7662/__init__.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7662/introspection.pyi +11 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7662/models.pyi +8 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc7662/token_validator.pyi +7 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8414/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8414/models.pyi +40 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8414/well_known.pyi +1 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8628/__init__.pyi +19 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8628/device_code.pyi +15 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8628/endpoint.pyi +21 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8628/errors.pyi +10 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8628/models.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc8693/__init__.pyi +0 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc9068/__init__.pyi +6 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc9068/claims.pyi +16 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc9068/introspection.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc9068/revocation.pyi +9 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc9068/token.pyi +23 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oauth2/rfc9068/token_validator.pyi +20 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/__init__.pyi +0 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/__init__.pyi +29 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/claims.pyi +37 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/errors.pyi +28 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/grants/__init__.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/grants/code.pyi +17 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/grants/hybrid.pyi +13 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/grants/implicit.pyi +16 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/grants/util.pyi +18 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/models.pyi +5 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/core/util.pyi +1 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/discovery/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/discovery/models.pyi +36 -0
- package/dist/typeshed-fallback/stubs/Authlib/authlib/oidc/discovery/well_known.pyi +1 -0
- package/dist/typeshed-fallback/stubs/Flask-Migrate/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/Flask-Migrate/flask_migrate/__init__.pyi +2 -4
- package/dist/typeshed-fallback/stubs/Flask-SocketIO/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/Flask-SocketIO/flask_socketio/__init__.pyi +30 -4
- package/dist/typeshed-fallback/stubs/Markdown/markdown/core.pyi +2 -13
- package/dist/typeshed-fallback/stubs/PyAutoGUI/pyautogui/__init__.pyi +2 -2
- package/dist/typeshed-fallback/stubs/PyYAML/yaml/constructor.pyi +1 -1
- package/dist/typeshed-fallback/stubs/Pygments/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/WebOb/webob/exc.pyi +1 -1
- package/dist/typeshed-fallback/stubs/click-log/METADATA.toml +3 -0
- package/dist/typeshed-fallback/stubs/click-log/click_log/__init__.pyi +4 -0
- package/dist/typeshed-fallback/stubs/click-log/click_log/core.pyi +15 -0
- package/dist/typeshed-fallback/stubs/click-log/click_log/options.pyi +12 -0
- package/dist/typeshed-fallback/stubs/click-web/METADATA.toml +3 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/__init__.pyi +16 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/exceptions.pyi +2 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/resources/cmd_exec.pyi +79 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/resources/cmd_form.pyi +6 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/resources/index.pyi +6 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/resources/input_fields.pyi +49 -0
- package/dist/typeshed-fallback/stubs/click-web/click_web/web_click_types.pyi +18 -0
- package/dist/typeshed-fallback/stubs/croniter/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/croniter/croniter/croniter.pyi +7 -0
- package/dist/typeshed-fallback/stubs/django-import-export/METADATA.toml +6 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/__init__.pyi +1 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/admin.pyi +114 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/exceptions.pyi +2 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/fields.pyi +34 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/formats/__init__.pyi +0 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/formats/base_formats.pyi +57 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/forms.pyi +31 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/instance_loaders.pyi +23 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/mixins.pyi +66 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/resources.pyi +232 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/results.pyi +73 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/signals.pyi +4 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/templatetags/__init__.pyi +0 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/templatetags/import_export_tags.pyi +8 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/tmp_storages.pyi +34 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/utils.pyi +18 -0
- package/dist/typeshed-fallback/stubs/django-import-export/import_export/widgets.pyi +66 -0
- package/dist/typeshed-fallback/stubs/docker/docker/models/containers.pyi +2 -2
- package/dist/typeshed-fallback/stubs/flake8-bugbear/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/fpdf2/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/__init__.pyi +2 -0
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/annotations.pyi +2 -2
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/enums.pyi +50 -4
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/fonts.pyi +3 -3
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/fpdf.pyi +53 -18
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/html.pyi +2 -0
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/image_parsing.pyi +10 -2
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/line_break.pyi +9 -3
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/outline.pyi +21 -0
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/output.pyi +19 -0
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/prefs.pyi +38 -4
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/table.pyi +13 -1
- package/dist/typeshed-fallback/stubs/fpdf2/fpdf/util.pyi +1 -0
- package/dist/typeshed-fallback/stubs/gdb/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/gdb/gdb/__init__.pyi +126 -9
- package/dist/typeshed-fallback/stubs/gdb/gdb/unwinder.pyi +2 -3
- package/dist/typeshed-fallback/stubs/gevent/gevent/select.pyi +7 -2
- package/dist/typeshed-fallback/stubs/hdbcli/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/ibm-db/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/ibm-db/ibm_db.pyi +11 -1
- package/dist/typeshed-fallback/stubs/icalendar/METADATA.toml +1 -5
- package/dist/typeshed-fallback/stubs/icalendar/icalendar/timezone/tzp.pyi +1 -1
- package/dist/typeshed-fallback/stubs/jsonschema/METADATA.toml +0 -2
- package/dist/typeshed-fallback/stubs/jwcrypto/jwcrypto/jwk.pyi +4 -4
- package/dist/typeshed-fallback/stubs/lupa/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/m3u8/m3u8/httpclient.pyi +1 -1
- package/dist/typeshed-fallback/stubs/nanoleafapi/METADATA.toml +2 -0
- package/dist/typeshed-fallback/stubs/nanoleafapi/nanoleafapi/__init__.pyi +16 -0
- package/dist/typeshed-fallback/stubs/nanoleafapi/nanoleafapi/digital_twin.pyi +12 -0
- package/dist/typeshed-fallback/stubs/nanoleafapi/nanoleafapi/discovery.pyi +1 -0
- package/dist/typeshed-fallback/stubs/nanoleafapi/nanoleafapi/nanoleaf.pyi +68 -0
- package/dist/typeshed-fallback/stubs/networkx/networkx/classes/multidigraph.pyi +1 -1
- package/dist/typeshed-fallback/stubs/openpyxl/openpyxl/styles/cell_style.pyi +1 -1
- package/dist/typeshed-fallback/stubs/peewee/peewee.pyi +4 -4
- package/dist/typeshed-fallback/stubs/pexpect/pexpect/pty_spawn.pyi +1 -1
- package/dist/typeshed-fallback/stubs/pika/pika/credentials.pyi +10 -7
- package/dist/typeshed-fallback/stubs/polib/polib.pyi +3 -2
- package/dist/typeshed-fallback/stubs/protobuf/METADATA.toml +2 -2
- package/dist/typeshed-fallback/stubs/protobuf/google/protobuf/api_pb2.pyi +1 -1
- package/dist/typeshed-fallback/stubs/protobuf/google/protobuf/descriptor_pb2.pyi +4 -8
- package/dist/typeshed-fallback/stubs/protobuf/google/protobuf/runtime_version.pyi +23 -0
- package/dist/typeshed-fallback/stubs/pycocotools/METADATA.toml +1 -0
- package/dist/typeshed-fallback/stubs/pycocotools/pycocotools/coco.pyi +6 -11
- package/dist/typeshed-fallback/stubs/pycocotools/pycocotools/cocoeval.pyi +16 -30
- package/dist/typeshed-fallback/stubs/pycocotools/pycocotools/mask.pyi +7 -9
- package/dist/typeshed-fallback/stubs/pycurl/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/pycurl/pycurl.pyi +33 -32
- package/dist/typeshed-fallback/stubs/pynput/pynput/keyboard/_base.pyi +65 -65
- package/dist/typeshed-fallback/stubs/python-dateutil/dateutil/relativedelta.pyi +3 -11
- package/dist/typeshed-fallback/stubs/pywin32/_win32typing.pyi +3 -3
- package/dist/typeshed-fallback/stubs/qrbill/qrbill/bill.pyi +2 -2
- package/dist/typeshed-fallback/stubs/requests-oauthlib/requests_oauthlib/oauth1_auth.pyi +1 -1
- package/dist/typeshed-fallback/stubs/seaborn/METADATA.toml +1 -11
- package/dist/typeshed-fallback/stubs/seaborn/seaborn/algorithms.pyi +13 -13
- package/dist/typeshed-fallback/stubs/setuptools/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/cmd.pyi +5 -0
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/command/bdist.pyi +1 -1
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/command/install_data.pyi +2 -1
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/dist.pyi +21 -21
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/_distutils/extension.pyi +3 -4
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/extension.pyi +2 -3
- package/dist/typeshed-fallback/stubs/shapely/shapely/_enum.pyi +1 -1
- package/dist/typeshed-fallback/stubs/six/METADATA.toml +1 -1
- package/dist/typeshed-fallback/stubs/tabulate/tabulate/__init__.pyi +2 -1
- package/dist/typeshed-fallback/stubs/tqdm/tqdm/asyncio.pyi +2 -2
- package/dist/typeshed-fallback/stubs/vobject/METADATA.toml +2 -2
- package/dist/typeshed-fallback/stubs/vobject/vobject/__init__.pyi +2 -4
- package/dist/typeshed-fallback/stubs/vobject/vobject/base.pyi +26 -24
- package/dist/typeshed-fallback/stubs/vobject/vobject/behavior.pyi +5 -4
- package/dist/typeshed-fallback/stubs/vobject/vobject/icalendar.pyi +28 -37
- package/dist/typeshed-fallback/stubs/vobject/vobject/vcard.pyi +20 -20
- package/dist/typeshed-fallback/stubs/vobject/vobject/win32tz.pyi +22 -22
- package/package.json +1 -1
- package/dist/typeshed-fallback/stubs/python-gflags/METADATA.toml +0 -2
- package/dist/typeshed-fallback/stubs/python-gflags/gflags.pyi +0 -309
- package/dist/typeshed-fallback/stubs/redis/METADATA.toml +0 -12
- package/dist/typeshed-fallback/stubs/redis/redis/__init__.pyi +0 -72
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/__init__.pyi +0 -64
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/client.pyi +0 -1091
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/cluster.pyi +0 -229
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/connection.pyi +0 -363
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/lock.pyi +0 -51
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/parser.pyi +0 -9
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/retry.pyi +0 -12
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/sentinel.pyi +0 -162
- package/dist/typeshed-fallback/stubs/redis/redis/asyncio/utils.pyi +0 -15
- package/dist/typeshed-fallback/stubs/redis/redis/backoff.pyi +0 -31
- package/dist/typeshed-fallback/stubs/redis/redis/client.pyi +0 -817
- package/dist/typeshed-fallback/stubs/redis/redis/cluster.pyi +0 -265
- package/dist/typeshed-fallback/stubs/redis/redis/commands/__init__.pyi +0 -17
- package/dist/typeshed-fallback/stubs/redis/redis/commands/bf/__init__.pyi +0 -58
- package/dist/typeshed-fallback/stubs/redis/redis/commands/bf/commands.pyi +0 -112
- package/dist/typeshed-fallback/stubs/redis/redis/commands/bf/info.pyi +0 -43
- package/dist/typeshed-fallback/stubs/redis/redis/commands/cluster.pyi +0 -60
- package/dist/typeshed-fallback/stubs/redis/redis/commands/core.pyi +0 -1743
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/__init__.pyi +0 -26
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/commands.pyi +0 -25
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/edge.pyi +0 -14
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/exceptions.pyi +0 -5
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/node.pyi +0 -18
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/path.pyi +0 -18
- package/dist/typeshed-fallback/stubs/redis/redis/commands/graph/query_result.pyi +0 -74
- package/dist/typeshed-fallback/stubs/redis/redis/commands/helpers.pyi +0 -10
- package/dist/typeshed-fallback/stubs/redis/redis/commands/json/__init__.pyi +0 -15
- package/dist/typeshed-fallback/stubs/redis/redis/commands/json/commands.pyi +0 -32
- package/dist/typeshed-fallback/stubs/redis/redis/commands/json/decoders.pyi +0 -4
- package/dist/typeshed-fallback/stubs/redis/redis/commands/json/path.pyi +0 -5
- package/dist/typeshed-fallback/stubs/redis/redis/commands/parser.pyi +0 -8
- package/dist/typeshed-fallback/stubs/redis/redis/commands/redismodules.pyi +0 -14
- package/dist/typeshed-fallback/stubs/redis/redis/commands/search/__init__.pyi +0 -22
- package/dist/typeshed-fallback/stubs/redis/redis/commands/search/aggregation.pyi +0 -53
- package/dist/typeshed-fallback/stubs/redis/redis/commands/search/commands.pyi +0 -111
- package/dist/typeshed-fallback/stubs/redis/redis/commands/search/query.pyi +0 -52
- package/dist/typeshed-fallback/stubs/redis/redis/commands/search/result.pyi +0 -7
- package/dist/typeshed-fallback/stubs/redis/redis/commands/sentinel.pyi +0 -17
- package/dist/typeshed-fallback/stubs/redis/redis/commands/timeseries/__init__.pyi +0 -14
- package/dist/typeshed-fallback/stubs/redis/redis/commands/timeseries/commands.pyi +0 -160
- package/dist/typeshed-fallback/stubs/redis/redis/commands/timeseries/info.pyi +0 -18
- package/dist/typeshed-fallback/stubs/redis/redis/commands/timeseries/utils.pyi +0 -5
- package/dist/typeshed-fallback/stubs/redis/redis/connection.pyi +0 -289
- package/dist/typeshed-fallback/stubs/redis/redis/crc.pyi +0 -5
- package/dist/typeshed-fallback/stubs/redis/redis/credentials.pyi +0 -11
- package/dist/typeshed-fallback/stubs/redis/redis/exceptions.pyi +0 -42
- package/dist/typeshed-fallback/stubs/redis/redis/lock.pyi +0 -56
- package/dist/typeshed-fallback/stubs/redis/redis/ocsp.pyi +0 -21
- package/dist/typeshed-fallback/stubs/redis/redis/retry.pyi +0 -11
- package/dist/typeshed-fallback/stubs/redis/redis/sentinel.pyi +0 -62
- package/dist/typeshed-fallback/stubs/redis/redis/typing.pyi +0 -34
- package/dist/typeshed-fallback/stubs/redis/redis/utils.pyi +0 -22
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/compat/py310.pyi +0 -9
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/compat/py311.pyi +0 -4
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/compat/py312.pyi +0 -3
- package/dist/typeshed-fallback/stubs/setuptools/setuptools/compat/py39.pyi +0 -7
- /package/dist/typeshed-fallback/stdlib/zipfile/{_path.pyi → _path/__init__.pyi} +0 -0
- /package/dist/typeshed-fallback/stubs/{setuptools/setuptools/compat → Authlib/authlib/common}/__init__.pyi +0 -0
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
"""Optimized C implementation for the Python pickle module."""
|
|
2
|
+
|
|
3
|
+
import sys
|
|
4
|
+
from _typeshed import ReadableBuffer, SupportsWrite
|
|
5
|
+
from collections.abc import Callable, Iterable, Iterator, Mapping
|
|
6
|
+
from pickle import PickleBuffer as PickleBuffer
|
|
7
|
+
from typing import Any, Protocol, type_check_only
|
|
8
|
+
from typing_extensions import TypeAlias
|
|
9
|
+
|
|
10
|
+
class _ReadableFileobj(Protocol):
|
|
11
|
+
def read(self, n: int, /) -> bytes: ...
|
|
12
|
+
def readline(self) -> bytes: ...
|
|
13
|
+
|
|
14
|
+
_BufferCallback: TypeAlias = Callable[[PickleBuffer], Any] | None
|
|
15
|
+
|
|
16
|
+
_ReducedType: TypeAlias = (
|
|
17
|
+
str
|
|
18
|
+
| tuple[Callable[..., Any], tuple[Any, ...]]
|
|
19
|
+
| tuple[Callable[..., Any], tuple[Any, ...], Any]
|
|
20
|
+
| tuple[Callable[..., Any], tuple[Any, ...], Any, Iterator[Any] | None]
|
|
21
|
+
| tuple[Callable[..., Any], tuple[Any, ...], Any, Iterator[Any] | None, Iterator[Any] | None]
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
def dump(
|
|
25
|
+
obj: Any,
|
|
26
|
+
file: SupportsWrite[bytes],
|
|
27
|
+
protocol: int | None = None,
|
|
28
|
+
*,
|
|
29
|
+
fix_imports: bool = True,
|
|
30
|
+
buffer_callback: _BufferCallback = None,
|
|
31
|
+
) -> None:
|
|
32
|
+
"""
|
|
33
|
+
Write a pickled representation of obj to the open file object file.
|
|
34
|
+
|
|
35
|
+
This is equivalent to ``Pickler(file, protocol).dump(obj)``, but may
|
|
36
|
+
be more efficient.
|
|
37
|
+
|
|
38
|
+
The optional *protocol* argument tells the pickler to use the given
|
|
39
|
+
protocol; supported protocols are 0, 1, 2, 3, 4 and 5. The default
|
|
40
|
+
protocol is 4. It was introduced in Python 3.4, and is incompatible
|
|
41
|
+
with previous versions.
|
|
42
|
+
|
|
43
|
+
Specifying a negative protocol version selects the highest protocol
|
|
44
|
+
version supported. The higher the protocol used, the more recent the
|
|
45
|
+
version of Python needed to read the pickle produced.
|
|
46
|
+
|
|
47
|
+
The *file* argument must have a write() method that accepts a single
|
|
48
|
+
bytes argument. It can thus be a file object opened for binary
|
|
49
|
+
writing, an io.BytesIO instance, or any other custom object that meets
|
|
50
|
+
this interface.
|
|
51
|
+
|
|
52
|
+
If *fix_imports* is True and protocol is less than 3, pickle will try
|
|
53
|
+
to map the new Python 3 names to the old module names used in Python
|
|
54
|
+
2, so that the pickle data stream is readable with Python 2.
|
|
55
|
+
|
|
56
|
+
If *buffer_callback* is None (the default), buffer views are serialized
|
|
57
|
+
into *file* as part of the pickle stream. It is an error if
|
|
58
|
+
*buffer_callback* is not None and *protocol* is None or smaller than 5.
|
|
59
|
+
"""
|
|
60
|
+
...
|
|
61
|
+
def dumps(
|
|
62
|
+
obj: Any, protocol: int | None = None, *, fix_imports: bool = True, buffer_callback: _BufferCallback = None
|
|
63
|
+
) -> bytes:
|
|
64
|
+
"""
|
|
65
|
+
Return the pickled representation of the object as a bytes object.
|
|
66
|
+
|
|
67
|
+
The optional *protocol* argument tells the pickler to use the given
|
|
68
|
+
protocol; supported protocols are 0, 1, 2, 3, 4 and 5. The default
|
|
69
|
+
protocol is 4. It was introduced in Python 3.4, and is incompatible
|
|
70
|
+
with previous versions.
|
|
71
|
+
|
|
72
|
+
Specifying a negative protocol version selects the highest protocol
|
|
73
|
+
version supported. The higher the protocol used, the more recent the
|
|
74
|
+
version of Python needed to read the pickle produced.
|
|
75
|
+
|
|
76
|
+
If *fix_imports* is True and *protocol* is less than 3, pickle will
|
|
77
|
+
try to map the new Python 3 names to the old module names used in
|
|
78
|
+
Python 2, so that the pickle data stream is readable with Python 2.
|
|
79
|
+
|
|
80
|
+
If *buffer_callback* is None (the default), buffer views are serialized
|
|
81
|
+
into *file* as part of the pickle stream. It is an error if
|
|
82
|
+
*buffer_callback* is not None and *protocol* is None or smaller than 5.
|
|
83
|
+
"""
|
|
84
|
+
...
|
|
85
|
+
def load(
|
|
86
|
+
file: _ReadableFileobj,
|
|
87
|
+
*,
|
|
88
|
+
fix_imports: bool = True,
|
|
89
|
+
encoding: str = "ASCII",
|
|
90
|
+
errors: str = "strict",
|
|
91
|
+
buffers: Iterable[Any] | None = (),
|
|
92
|
+
) -> Any:
|
|
93
|
+
"""
|
|
94
|
+
Read and return an object from the pickle data stored in a file.
|
|
95
|
+
|
|
96
|
+
This is equivalent to ``Unpickler(file).load()``, but may be more
|
|
97
|
+
efficient.
|
|
98
|
+
|
|
99
|
+
The protocol version of the pickle is detected automatically, so no
|
|
100
|
+
protocol argument is needed. Bytes past the pickled object's
|
|
101
|
+
representation are ignored.
|
|
102
|
+
|
|
103
|
+
The argument *file* must have two methods, a read() method that takes
|
|
104
|
+
an integer argument, and a readline() method that requires no
|
|
105
|
+
arguments. Both methods should return bytes. Thus *file* can be a
|
|
106
|
+
binary file object opened for reading, an io.BytesIO object, or any
|
|
107
|
+
other custom object that meets this interface.
|
|
108
|
+
|
|
109
|
+
Optional keyword arguments are *fix_imports*, *encoding* and *errors*,
|
|
110
|
+
which are used to control compatibility support for pickle stream
|
|
111
|
+
generated by Python 2. If *fix_imports* is True, pickle will try to
|
|
112
|
+
map the old Python 2 names to the new names used in Python 3. The
|
|
113
|
+
*encoding* and *errors* tell pickle how to decode 8-bit string
|
|
114
|
+
instances pickled by Python 2; these default to 'ASCII' and 'strict',
|
|
115
|
+
respectively. The *encoding* can be 'bytes' to read these 8-bit
|
|
116
|
+
string instances as bytes objects.
|
|
117
|
+
"""
|
|
118
|
+
...
|
|
119
|
+
def loads(
|
|
120
|
+
data: ReadableBuffer,
|
|
121
|
+
/,
|
|
122
|
+
*,
|
|
123
|
+
fix_imports: bool = True,
|
|
124
|
+
encoding: str = "ASCII",
|
|
125
|
+
errors: str = "strict",
|
|
126
|
+
buffers: Iterable[Any] | None = (),
|
|
127
|
+
) -> Any:
|
|
128
|
+
"""
|
|
129
|
+
Read and return an object from the given pickle data.
|
|
130
|
+
|
|
131
|
+
The protocol version of the pickle is detected automatically, so no
|
|
132
|
+
protocol argument is needed. Bytes past the pickled object's
|
|
133
|
+
representation are ignored.
|
|
134
|
+
|
|
135
|
+
Optional keyword arguments are *fix_imports*, *encoding* and *errors*,
|
|
136
|
+
which are used to control compatibility support for pickle stream
|
|
137
|
+
generated by Python 2. If *fix_imports* is True, pickle will try to
|
|
138
|
+
map the old Python 2 names to the new names used in Python 3. The
|
|
139
|
+
*encoding* and *errors* tell pickle how to decode 8-bit string
|
|
140
|
+
instances pickled by Python 2; these default to 'ASCII' and 'strict',
|
|
141
|
+
respectively. The *encoding* can be 'bytes' to read these 8-bit
|
|
142
|
+
string instances as bytes objects.
|
|
143
|
+
"""
|
|
144
|
+
...
|
|
145
|
+
|
|
146
|
+
class PickleError(Exception): ...
|
|
147
|
+
class PicklingError(PickleError): ...
|
|
148
|
+
class UnpicklingError(PickleError): ...
|
|
149
|
+
|
|
150
|
+
@type_check_only
|
|
151
|
+
class PicklerMemoProxy:
|
|
152
|
+
def clear(self, /) -> None: ...
|
|
153
|
+
def copy(self, /) -> dict[int, tuple[int, Any]]: ...
|
|
154
|
+
|
|
155
|
+
class Pickler:
|
|
156
|
+
"""
|
|
157
|
+
This takes a binary file for writing a pickle data stream.
|
|
158
|
+
|
|
159
|
+
The optional *protocol* argument tells the pickler to use the given
|
|
160
|
+
protocol; supported protocols are 0, 1, 2, 3, 4 and 5. The default
|
|
161
|
+
protocol is 4. It was introduced in Python 3.4, and is incompatible
|
|
162
|
+
with previous versions.
|
|
163
|
+
|
|
164
|
+
Specifying a negative protocol version selects the highest protocol
|
|
165
|
+
version supported. The higher the protocol used, the more recent the
|
|
166
|
+
version of Python needed to read the pickle produced.
|
|
167
|
+
|
|
168
|
+
The *file* argument must have a write() method that accepts a single
|
|
169
|
+
bytes argument. It can thus be a file object opened for binary
|
|
170
|
+
writing, an io.BytesIO instance, or any other custom object that meets
|
|
171
|
+
this interface.
|
|
172
|
+
|
|
173
|
+
If *fix_imports* is True and protocol is less than 3, pickle will try
|
|
174
|
+
to map the new Python 3 names to the old module names used in Python
|
|
175
|
+
2, so that the pickle data stream is readable with Python 2.
|
|
176
|
+
|
|
177
|
+
If *buffer_callback* is None (the default), buffer views are
|
|
178
|
+
serialized into *file* as part of the pickle stream.
|
|
179
|
+
|
|
180
|
+
If *buffer_callback* is not None, then it can be called any number
|
|
181
|
+
of times with a buffer view. If the callback returns a false value
|
|
182
|
+
(such as None), the given buffer is out-of-band; otherwise the
|
|
183
|
+
buffer is serialized in-band, i.e. inside the pickle stream.
|
|
184
|
+
|
|
185
|
+
It is an error if *buffer_callback* is not None and *protocol*
|
|
186
|
+
is None or smaller than 5.
|
|
187
|
+
"""
|
|
188
|
+
fast: bool
|
|
189
|
+
dispatch_table: Mapping[type, Callable[[Any], _ReducedType]]
|
|
190
|
+
reducer_override: Callable[[Any], Any]
|
|
191
|
+
bin: bool # undocumented
|
|
192
|
+
def __init__(
|
|
193
|
+
self,
|
|
194
|
+
file: SupportsWrite[bytes],
|
|
195
|
+
protocol: int | None = None,
|
|
196
|
+
fix_imports: bool = True,
|
|
197
|
+
buffer_callback: _BufferCallback = None,
|
|
198
|
+
) -> None: ...
|
|
199
|
+
@property
|
|
200
|
+
def memo(self) -> PicklerMemoProxy: ...
|
|
201
|
+
@memo.setter
|
|
202
|
+
def memo(self, value: PicklerMemoProxy | dict[int, tuple[int, Any]]) -> None: ...
|
|
203
|
+
def dump(self, obj: Any, /) -> None:
|
|
204
|
+
"""Write a pickled representation of the given object to the open file."""
|
|
205
|
+
...
|
|
206
|
+
def clear_memo(self) -> None:
|
|
207
|
+
"""
|
|
208
|
+
Clears the pickler's "memo".
|
|
209
|
+
|
|
210
|
+
The memo is the data structure that remembers which objects the
|
|
211
|
+
pickler has already seen, so that shared or recursive objects are
|
|
212
|
+
pickled by reference and not by value. This method is useful when
|
|
213
|
+
re-using picklers.
|
|
214
|
+
"""
|
|
215
|
+
...
|
|
216
|
+
if sys.version_info >= (3, 13):
|
|
217
|
+
def persistent_id(self, obj: Any, /) -> Any: ...
|
|
218
|
+
else:
|
|
219
|
+
persistent_id: Callable[[Any], Any]
|
|
220
|
+
|
|
221
|
+
@type_check_only
|
|
222
|
+
class UnpicklerMemoProxy:
|
|
223
|
+
def clear(self, /) -> None: ...
|
|
224
|
+
def copy(self, /) -> dict[int, tuple[int, Any]]: ...
|
|
225
|
+
|
|
226
|
+
class Unpickler:
|
|
227
|
+
"""
|
|
228
|
+
This takes a binary file for reading a pickle data stream.
|
|
229
|
+
|
|
230
|
+
The protocol version of the pickle is detected automatically, so no
|
|
231
|
+
protocol argument is needed. Bytes past the pickled object's
|
|
232
|
+
representation are ignored.
|
|
233
|
+
|
|
234
|
+
The argument *file* must have two methods, a read() method that takes
|
|
235
|
+
an integer argument, and a readline() method that requires no
|
|
236
|
+
arguments. Both methods should return bytes. Thus *file* can be a
|
|
237
|
+
binary file object opened for reading, an io.BytesIO object, or any
|
|
238
|
+
other custom object that meets this interface.
|
|
239
|
+
|
|
240
|
+
Optional keyword arguments are *fix_imports*, *encoding* and *errors*,
|
|
241
|
+
which are used to control compatibility support for pickle stream
|
|
242
|
+
generated by Python 2. If *fix_imports* is True, pickle will try to
|
|
243
|
+
map the old Python 2 names to the new names used in Python 3. The
|
|
244
|
+
*encoding* and *errors* tell pickle how to decode 8-bit string
|
|
245
|
+
instances pickled by Python 2; these default to 'ASCII' and 'strict',
|
|
246
|
+
respectively. The *encoding* can be 'bytes' to read these 8-bit
|
|
247
|
+
string instances as bytes objects.
|
|
248
|
+
"""
|
|
249
|
+
def __init__(
|
|
250
|
+
self,
|
|
251
|
+
file: _ReadableFileobj,
|
|
252
|
+
*,
|
|
253
|
+
fix_imports: bool = True,
|
|
254
|
+
encoding: str = "ASCII",
|
|
255
|
+
errors: str = "strict",
|
|
256
|
+
buffers: Iterable[Any] | None = (),
|
|
257
|
+
) -> None: ...
|
|
258
|
+
@property
|
|
259
|
+
def memo(self) -> UnpicklerMemoProxy: ...
|
|
260
|
+
@memo.setter
|
|
261
|
+
def memo(self, value: UnpicklerMemoProxy | dict[int, tuple[int, Any]]) -> None: ...
|
|
262
|
+
def load(self) -> Any:
|
|
263
|
+
"""
|
|
264
|
+
Load a pickle.
|
|
265
|
+
|
|
266
|
+
Read a pickled object representation from the open file object given
|
|
267
|
+
in the constructor, and return the reconstituted object hierarchy
|
|
268
|
+
specified therein.
|
|
269
|
+
"""
|
|
270
|
+
...
|
|
271
|
+
def find_class(self, module_name: str, global_name: str, /) -> Any:
|
|
272
|
+
"""
|
|
273
|
+
Return an object from a specified module.
|
|
274
|
+
|
|
275
|
+
If necessary, the module will be imported. Subclasses may override
|
|
276
|
+
this method (e.g. to restrict unpickling of arbitrary classes and
|
|
277
|
+
functions).
|
|
278
|
+
|
|
279
|
+
This method is called whenever a class or a function object is
|
|
280
|
+
needed. Both arguments passed are str objects.
|
|
281
|
+
"""
|
|
282
|
+
...
|
|
283
|
+
if sys.version_info >= (3, 13):
|
|
284
|
+
def persistent_load(self, pid: Any, /) -> Any: ...
|
|
285
|
+
else:
|
|
286
|
+
persistent_load: Callable[[Any], Any]
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import sys
|
|
1
2
|
from collections.abc import Iterable
|
|
2
3
|
from typing import ClassVar, Literal, NoReturn
|
|
3
4
|
|
|
@@ -5,7 +6,7 @@ class Quitter:
|
|
|
5
6
|
name: str
|
|
6
7
|
eof: str
|
|
7
8
|
def __init__(self, name: str, eof: str) -> None: ...
|
|
8
|
-
def __call__(self, code:
|
|
9
|
+
def __call__(self, code: sys._ExitCode = None) -> NoReturn: ...
|
|
9
10
|
|
|
10
11
|
class _Printer:
|
|
11
12
|
MAXLINES: ClassVar[Literal[23]]
|
|
@@ -13,4 +14,4 @@ class _Printer:
|
|
|
13
14
|
def __call__(self) -> None: ...
|
|
14
15
|
|
|
15
16
|
class _Helper:
|
|
16
|
-
def __call__(self, request: object) -> None: ...
|
|
17
|
+
def __call__(self, request: object = ...) -> None: ...
|
|
@@ -84,8 +84,10 @@ if sys.platform == "win32":
|
|
|
84
84
|
SO_EXCLUSIVEADDRUSE: int
|
|
85
85
|
if sys.platform != "win32":
|
|
86
86
|
SO_REUSEPORT: int
|
|
87
|
+
if sys.platform != "darwin" or sys.version_info >= (3, 13):
|
|
88
|
+
SO_BINDTODEVICE: int
|
|
89
|
+
|
|
87
90
|
if sys.platform != "win32" and sys.platform != "darwin":
|
|
88
|
-
SO_BINDTODEVICE: int
|
|
89
91
|
SO_DOMAIN: int
|
|
90
92
|
SO_MARK: int
|
|
91
93
|
SO_PASSCRED: int
|
|
@@ -17,7 +17,7 @@ from ssl import (
|
|
|
17
17
|
SSLWantWriteError as SSLWantWriteError,
|
|
18
18
|
SSLZeroReturnError as SSLZeroReturnError,
|
|
19
19
|
)
|
|
20
|
-
from typing import Any, Literal, TypedDict, final, overload
|
|
20
|
+
from typing import Any, ClassVar, Literal, TypedDict, final, overload
|
|
21
21
|
from typing_extensions import NotRequired, Self, TypeAlias
|
|
22
22
|
|
|
23
23
|
_PasswordType: TypeAlias = Callable[[], str | bytes | bytearray] | str | bytes | bytearray
|
|
@@ -216,6 +216,7 @@ class MemoryBIO:
|
|
|
216
216
|
|
|
217
217
|
@final
|
|
218
218
|
class SSLSession:
|
|
219
|
+
__hash__: ClassVar[None] # type: ignore[assignment]
|
|
219
220
|
@property
|
|
220
221
|
def has_ticket(self) -> bool:
|
|
221
222
|
"""Does the session contain a ticket?"""
|
|
@@ -346,9 +347,7 @@ OP_SINGLE_ECDH_USE: int
|
|
|
346
347
|
OP_NO_COMPRESSION: int
|
|
347
348
|
OP_ENABLE_MIDDLEBOX_COMPAT: int
|
|
348
349
|
OP_NO_RENEGOTIATION: int
|
|
349
|
-
if sys.version_info >= (3, 11):
|
|
350
|
-
OP_IGNORE_UNEXPECTED_EOF: int
|
|
351
|
-
elif sys.version_info >= (3, 8) and sys.platform == "linux":
|
|
350
|
+
if sys.version_info >= (3, 11) or sys.platform == "linux":
|
|
352
351
|
OP_IGNORE_UNEXPECTED_EOF: int
|
|
353
352
|
if sys.version_info >= (3, 12):
|
|
354
353
|
OP_LEGACY_SERVER_CONNECT: int
|
|
@@ -28,54 +28,37 @@ def _count() -> int:
|
|
|
28
28
|
"""
|
|
29
29
|
...
|
|
30
30
|
@final
|
|
31
|
-
class
|
|
32
|
-
"""
|
|
33
|
-
A lock object is a synchronization primitive. To create a lock,
|
|
34
|
-
call threading.Lock(). Methods are:
|
|
35
|
-
|
|
36
|
-
acquire() -- lock the lock, possibly blocking until it can be obtained
|
|
37
|
-
release() -- unlock of the lock
|
|
38
|
-
locked() -- test whether the lock is currently locked
|
|
39
|
-
|
|
40
|
-
A lock is not owned by the thread that locked it; another thread may
|
|
41
|
-
unlock it. A thread attempting to lock a lock that it has already locked
|
|
42
|
-
will block until another thread unlocks it. Deadlocks may ensue.
|
|
43
|
-
"""
|
|
31
|
+
class RLock:
|
|
44
32
|
def acquire(self, blocking: bool = True, timeout: float = -1) -> bool:
|
|
45
33
|
"""
|
|
46
|
-
Lock the lock.
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
34
|
+
Lock the lock. `blocking` indicates whether we should wait
|
|
35
|
+
for the lock to be available or not. If `blocking` is False
|
|
36
|
+
and another thread holds the lock, the method will return False
|
|
37
|
+
immediately. If `blocking` is True and another thread holds
|
|
38
|
+
the lock, the method will wait for the lock to be released,
|
|
39
|
+
take it and then return True.
|
|
40
|
+
(note: the blocking operation is interruptible.)
|
|
41
|
+
|
|
42
|
+
In all other cases, the method will return True immediately.
|
|
43
|
+
Precisely, if the current thread already holds the lock, its
|
|
44
|
+
internal counter is simply incremented. If nobody holds the lock,
|
|
45
|
+
the lock is taken and its internal counter initialized to 1.
|
|
52
46
|
"""
|
|
53
47
|
...
|
|
54
48
|
def release(self) -> None:
|
|
55
49
|
"""
|
|
56
50
|
Release the lock, allowing another thread that is blocked waiting for
|
|
57
51
|
the lock to acquire the lock. The lock must be in the locked state,
|
|
58
|
-
|
|
52
|
+
and must be locked by the same thread that unlocks it; otherwise a
|
|
53
|
+
`RuntimeError` is raised.
|
|
54
|
+
|
|
55
|
+
Do note that if the lock was acquire()d several times in a row by the
|
|
56
|
+
current thread, release() needs to be called as many times for the lock
|
|
57
|
+
to be available for other threads.
|
|
59
58
|
"""
|
|
60
59
|
...
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
...
|
|
64
|
-
def acquire_lock(self, blocking: bool = True, timeout: float = -1) -> bool:
|
|
65
|
-
"""An obsolete synonym of acquire()."""
|
|
66
|
-
...
|
|
67
|
-
def release_lock(self) -> None:
|
|
68
|
-
"""An obsolete synonym of release()."""
|
|
69
|
-
...
|
|
70
|
-
def locked_lock(self) -> bool:
|
|
71
|
-
"""An obsolete synonym of locked()."""
|
|
72
|
-
...
|
|
73
|
-
def __enter__(self) -> bool:
|
|
74
|
-
"""Lock the lock."""
|
|
75
|
-
...
|
|
76
|
-
def __exit__(
|
|
77
|
-
self, type: type[BaseException] | None, value: BaseException | None, traceback: TracebackType | None
|
|
78
|
-
) -> None:
|
|
60
|
+
__enter__ = acquire
|
|
61
|
+
def __exit__(self, t: type[BaseException] | None, v: BaseException | None, tb: TracebackType | None) -> None:
|
|
79
62
|
"""Release the lock."""
|
|
80
63
|
...
|
|
81
64
|
|
|
@@ -103,7 +86,72 @@ if sys.version_info >= (3, 13):
|
|
|
103
86
|
newly created thread._ThreadHandle instance.
|
|
104
87
|
"""
|
|
105
88
|
...
|
|
106
|
-
|
|
89
|
+
@final
|
|
90
|
+
class lock:
|
|
91
|
+
"""
|
|
92
|
+
A lock object is a synchronization primitive. To create a lock,
|
|
93
|
+
call threading.Lock(). Methods are:
|
|
94
|
+
|
|
95
|
+
acquire() -- lock the lock, possibly blocking until it can be obtained
|
|
96
|
+
release() -- unlock of the lock
|
|
97
|
+
locked() -- test whether the lock is currently locked
|
|
98
|
+
|
|
99
|
+
A lock is not owned by the thread that locked it; another thread may
|
|
100
|
+
unlock it. A thread attempting to lock a lock that it has already locked
|
|
101
|
+
will block until another thread unlocks it. Deadlocks may ensue.
|
|
102
|
+
"""
|
|
103
|
+
def acquire(self, blocking: bool = True, timeout: float = -1) -> bool:
|
|
104
|
+
"""
|
|
105
|
+
Lock the lock. Without argument, this blocks if the lock is already
|
|
106
|
+
locked (even by the same thread), waiting for another thread to release
|
|
107
|
+
the lock, and return True once the lock is acquired.
|
|
108
|
+
With an argument, this will only block if the argument is true,
|
|
109
|
+
and the return value reflects whether the lock is acquired.
|
|
110
|
+
The blocking operation is interruptible.
|
|
111
|
+
"""
|
|
112
|
+
...
|
|
113
|
+
def release(self) -> None:
|
|
114
|
+
"""
|
|
115
|
+
Release the lock, allowing another thread that is blocked waiting for
|
|
116
|
+
the lock to acquire the lock. The lock must be in the locked state,
|
|
117
|
+
but it needn't be locked by the same thread that unlocks it.
|
|
118
|
+
"""
|
|
119
|
+
...
|
|
120
|
+
def locked(self) -> bool:
|
|
121
|
+
"""Return whether the lock is in the locked state."""
|
|
122
|
+
...
|
|
123
|
+
def acquire_lock(self, blocking: bool = True, timeout: float = -1) -> bool:
|
|
124
|
+
"""An obsolete synonym of acquire()."""
|
|
125
|
+
...
|
|
126
|
+
def release_lock(self) -> None:
|
|
127
|
+
"""An obsolete synonym of release()."""
|
|
128
|
+
...
|
|
129
|
+
def locked_lock(self) -> bool:
|
|
130
|
+
"""An obsolete synonym of locked()."""
|
|
131
|
+
...
|
|
132
|
+
def __enter__(self) -> bool:
|
|
133
|
+
"""Lock the lock."""
|
|
134
|
+
...
|
|
135
|
+
def __exit__(
|
|
136
|
+
self, type: type[BaseException] | None, value: BaseException | None, traceback: TracebackType | None
|
|
137
|
+
) -> None:
|
|
138
|
+
"""Release the lock."""
|
|
139
|
+
...
|
|
140
|
+
|
|
141
|
+
LockType = lock
|
|
142
|
+
else:
|
|
143
|
+
@final
|
|
144
|
+
class LockType:
|
|
145
|
+
def acquire(self, blocking: bool = True, timeout: float = -1) -> bool: ...
|
|
146
|
+
def release(self) -> None: ...
|
|
147
|
+
def locked(self) -> bool: ...
|
|
148
|
+
def acquire_lock(self, blocking: bool = True, timeout: float = -1) -> bool: ...
|
|
149
|
+
def release_lock(self) -> None: ...
|
|
150
|
+
def locked_lock(self) -> bool: ...
|
|
151
|
+
def __enter__(self) -> bool: ...
|
|
152
|
+
def __exit__(
|
|
153
|
+
self, type: type[BaseException] | None, value: BaseException | None, traceback: TracebackType | None
|
|
154
|
+
) -> None: ...
|
|
107
155
|
|
|
108
156
|
@overload
|
|
109
157
|
def start_new_thread(function: Callable[[Unpack[_Ts]], object], args: tuple[Unpack[_Ts]], /) -> int:
|
|
@@ -133,26 +133,41 @@ TK_VERSION: Final[str]
|
|
|
133
133
|
class TkttType:
|
|
134
134
|
def deletetimerhandler(self): ...
|
|
135
135
|
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
136
|
+
if sys.version_info >= (3, 13):
|
|
137
|
+
def create(
|
|
138
|
+
screenName: str | None = None,
|
|
139
|
+
baseName: str = "",
|
|
140
|
+
className: str = "Tk",
|
|
141
|
+
interactive: bool = False,
|
|
142
|
+
wantobjects: int = 0,
|
|
143
|
+
wantTk: bool = True,
|
|
144
|
+
sync: bool = False,
|
|
145
|
+
use: str | None = None,
|
|
146
|
+
/,
|
|
147
|
+
):
|
|
148
|
+
"""
|
|
149
|
+
wantTk
|
|
150
|
+
if false, then Tk_Init() doesn't get called
|
|
151
|
+
sync
|
|
152
|
+
if true, then pass -sync to wish
|
|
153
|
+
use
|
|
154
|
+
if not None, then pass -use to wish
|
|
155
|
+
"""
|
|
156
|
+
...
|
|
157
|
+
|
|
158
|
+
else:
|
|
159
|
+
def create(
|
|
160
|
+
screenName: str | None = None,
|
|
161
|
+
baseName: str = "",
|
|
162
|
+
className: str = "Tk",
|
|
163
|
+
interactive: bool = False,
|
|
164
|
+
wantobjects: bool = False,
|
|
165
|
+
wantTk: bool = True,
|
|
166
|
+
sync: bool = False,
|
|
167
|
+
use: str | None = None,
|
|
168
|
+
/,
|
|
169
|
+
): ...
|
|
170
|
+
|
|
156
171
|
def getbusywaitinterval():
|
|
157
172
|
"""Return the current busy-wait interval between successive calls to Tcl_DoOneEvent in a threaded Python interpreter."""
|
|
158
173
|
...
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import sys
|
|
2
2
|
from collections.abc import Iterable, Iterator, MutableSet
|
|
3
|
-
from typing import Any, TypeVar, overload
|
|
3
|
+
from typing import Any, ClassVar, TypeVar, overload
|
|
4
4
|
from typing_extensions import Self
|
|
5
5
|
|
|
6
6
|
if sys.version_info >= (3, 9):
|
|
@@ -21,6 +21,7 @@ class WeakSet(MutableSet[_T]):
|
|
|
21
21
|
def copy(self) -> Self: ...
|
|
22
22
|
def remove(self, item: _T) -> None: ...
|
|
23
23
|
def update(self, other: Iterable[_T]) -> None: ...
|
|
24
|
+
__hash__: ClassVar[None] # type: ignore[assignment]
|
|
24
25
|
def __contains__(self, item: object) -> bool: ...
|
|
25
26
|
def __len__(self) -> int: ...
|
|
26
27
|
def __iter__(self) -> Iterator[_T]: ...
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import sys
|
|
2
|
-
from _typeshed import sentinel
|
|
2
|
+
from _typeshed import SupportsWrite, sentinel
|
|
3
3
|
from collections.abc import Callable, Generator, Iterable, Sequence
|
|
4
4
|
from re import Pattern
|
|
5
|
-
from typing import IO, Any, Final, Generic, NewType, NoReturn, Protocol, TypeVar, overload
|
|
5
|
+
from typing import IO, Any, ClassVar, Final, Generic, NewType, NoReturn, Protocol, TypeVar, overload
|
|
6
6
|
from typing_extensions import Self, TypeAlias, deprecated
|
|
7
7
|
|
|
8
8
|
__all__ = [
|
|
@@ -182,33 +182,33 @@ class ArgumentParser(_AttributeHolder, _ActionsContainer):
|
|
|
182
182
|
def add_subparsers(
|
|
183
183
|
self: _ArgumentParserT,
|
|
184
184
|
*,
|
|
185
|
-
title: str =
|
|
186
|
-
description: str | None =
|
|
187
|
-
prog: str =
|
|
185
|
+
title: str = "subcommands",
|
|
186
|
+
description: str | None = None,
|
|
187
|
+
prog: str | None = None,
|
|
188
188
|
action: type[Action] = ...,
|
|
189
189
|
option_string: str = ...,
|
|
190
|
-
dest: str | None =
|
|
191
|
-
required: bool =
|
|
192
|
-
help: str | None =
|
|
193
|
-
metavar: str | None =
|
|
190
|
+
dest: str | None = None,
|
|
191
|
+
required: bool = False,
|
|
192
|
+
help: str | None = None,
|
|
193
|
+
metavar: str | None = None,
|
|
194
194
|
) -> _SubParsersAction[_ArgumentParserT]: ...
|
|
195
195
|
@overload
|
|
196
196
|
def add_subparsers(
|
|
197
197
|
self,
|
|
198
198
|
*,
|
|
199
|
-
title: str =
|
|
200
|
-
description: str | None =
|
|
201
|
-
prog: str =
|
|
199
|
+
title: str = "subcommands",
|
|
200
|
+
description: str | None = None,
|
|
201
|
+
prog: str | None = None,
|
|
202
202
|
parser_class: type[_ArgumentParserT],
|
|
203
203
|
action: type[Action] = ...,
|
|
204
204
|
option_string: str = ...,
|
|
205
|
-
dest: str | None =
|
|
206
|
-
required: bool =
|
|
207
|
-
help: str | None =
|
|
208
|
-
metavar: str | None =
|
|
205
|
+
dest: str | None = None,
|
|
206
|
+
required: bool = False,
|
|
207
|
+
help: str | None = None,
|
|
208
|
+
metavar: str | None = None,
|
|
209
209
|
) -> _SubParsersAction[_ArgumentParserT]: ...
|
|
210
|
-
def print_usage(self, file:
|
|
211
|
-
def print_help(self, file:
|
|
210
|
+
def print_usage(self, file: SupportsWrite[str] | None = None) -> None: ...
|
|
211
|
+
def print_help(self, file: SupportsWrite[str] | None = None) -> None: ...
|
|
212
212
|
def format_usage(self) -> str: ...
|
|
213
213
|
def format_help(self) -> str: ...
|
|
214
214
|
@overload
|
|
@@ -237,7 +237,13 @@ class ArgumentParser(_AttributeHolder, _ActionsContainer):
|
|
|
237
237
|
# undocumented
|
|
238
238
|
def _get_optional_actions(self) -> list[Action]: ...
|
|
239
239
|
def _get_positional_actions(self) -> list[Action]: ...
|
|
240
|
-
|
|
240
|
+
if sys.version_info >= (3, 12):
|
|
241
|
+
def _parse_known_args(
|
|
242
|
+
self, arg_strings: list[str], namespace: Namespace, intermixed: bool
|
|
243
|
+
) -> tuple[Namespace, list[str]]: ...
|
|
244
|
+
else:
|
|
245
|
+
def _parse_known_args(self, arg_strings: list[str], namespace: Namespace) -> tuple[Namespace, list[str]]: ...
|
|
246
|
+
|
|
241
247
|
def _read_args_from_files(self, arg_strings: list[str]) -> list[str]: ...
|
|
242
248
|
def _match_argument(self, action: Action, arg_strings_pattern: str) -> int: ...
|
|
243
249
|
def _match_arguments_partial(self, actions: Sequence[Action], arg_strings_pattern: str) -> list[int]: ...
|
|
@@ -248,7 +254,7 @@ class ArgumentParser(_AttributeHolder, _ActionsContainer):
|
|
|
248
254
|
def _get_value(self, action: Action, arg_string: str) -> Any: ...
|
|
249
255
|
def _check_value(self, action: Action, value: Any) -> None: ...
|
|
250
256
|
def _get_formatter(self) -> HelpFormatter: ...
|
|
251
|
-
def _print_message(self, message: str, file:
|
|
257
|
+
def _print_message(self, message: str, file: SupportsWrite[str] | None = None) -> None: ...
|
|
252
258
|
|
|
253
259
|
class HelpFormatter:
|
|
254
260
|
# undocumented
|
|
@@ -452,6 +458,7 @@ class Namespace(_AttributeHolder):
|
|
|
452
458
|
...
|
|
453
459
|
def __contains__(self, key: str) -> bool: ...
|
|
454
460
|
def __eq__(self, other: object) -> bool: ...
|
|
461
|
+
__hash__: ClassVar[None] # type: ignore[assignment]
|
|
455
462
|
|
|
456
463
|
class FileType:
|
|
457
464
|
# undocumented
|