diff --git "a/example/codeql-db/db-python/default/pools/0/pageDump/page-000000000" "b/example/codeql-db/db-python/default/pools/0/pageDump/page-000000000" new file mode 100644--- /dev/null +++ "b/example/codeql-db/db-python/default/pools/0/pageDump/page-000000000" @@ -0,0 +1,15593 @@ +/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_collections_abc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/Users/pwntester/.pyenv/versions/3.8.13/lib/Users/pwntester/.pyenv/versions/3.8.13/Users/pwntester/.pyenv/versions/Users/pwntester/.pyenv/Users/pwntester/Users//Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tokenize.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/doctest.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/signals.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/main.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/locks.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/windows_events.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/socket.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/futures/_base.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/futures/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ast.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/_bootstrap.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/process.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/resource_sharer.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/urllib/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/urllib/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/http/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/http/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/message.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/header.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tkinter/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tkinter/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_py_abc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/collections/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/collections/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/token.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_compat_pickle.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/async_case.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/transports.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/exceptions.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/streams.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/queues.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/contextvars.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/logging/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/logging/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/opcode.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/zipfile.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/parser.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/abc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/parsers/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/parsers/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/decimal.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/feedparser.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/plistlib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/wintypes.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/socketserver.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/text_file.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/html/entities.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/html/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/abc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_weakrefset.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/traceback.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ntpath.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/heapq.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/pprint.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/result.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/case.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/glob.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/dis.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/windows_utils.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/locale.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/calendar.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/hmac.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/webbrowser.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/gzip.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/zipimport.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/spawn.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/test/support/testresult.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/test/support/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/test/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/_aix.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/refactor.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/btm_matcher.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/grammar.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/pgen.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/literals.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/signal.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/functools.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/sre_parse.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/encodings/mbcs.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/encodings/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/runner.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/protocols.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/futures.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/unix_events.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/getopt.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/selector_events.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tarfile.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/urllib/parse.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_pydecimal.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/selectors.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/collections/abc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tracemalloc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_threading_local.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/genericpath.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/string.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/argparse.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/runners.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/subprocess.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/tasks.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/copy.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/base_futures.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/base_tasks.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/bdb.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/codeop.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/trsock.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/staggered.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/queue.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/queues.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/random.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/test/support/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/utils.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/urllib/request.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ftplib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/io.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/enum.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/reprlib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/pickle.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/pdb.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/log.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/format_helpers.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/futures/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/constants.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/code.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/pydoc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/platform.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/_policybase.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_osx_support.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/errors.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/_encoded_words.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/nntplib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/macholib/dyld.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/macholib/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/errors.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/file_util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/etree/ElementTree.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/etree/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tkinter/constants.py/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/example/src/main.py/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/example/src/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/example/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/Users/pwntester/src/github.com/github/Users/pwntester/src/github.com/Users/pwntester/src/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/os.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/copyreg.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/weakref.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/operator.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/encodings/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/__future__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/suite.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/base_events.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/base_subprocess.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/futures/thread.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/sslproto.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lzma.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_compression.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/context.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/base64.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/test/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/bisect.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xmlrpc/client.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xmlrpc/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/pkgutil.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/shlex.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/charset.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/uu.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/sysconfig.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/encoders.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/quoprimime.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/html/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/optparse.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/token.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/fixer_util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/patcomp.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/contextlib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/types.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/sre_compile.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/inspect.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/concurrent/futures/process.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/machinery.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tempfile.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/_bootstrap_external.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xmlrpc/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/spawn.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/tty.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/importlib/util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/http/server.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/quopri.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/ccompiler.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/_parseaddr.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/debug.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/dep_util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/fancy_getopt.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/textwrap.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/tokenize.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/numbers.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/threading.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/posixpath.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/fnmatch.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/keyword.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/sre_constants.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/codecs.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/struct.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/unittest/loader.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/events.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/coroutines.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/shutil.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ssl.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/_bootlocale.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/reduction.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/forkserver.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/runpy.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/sysconfig.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/parsers/expat.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/http/client.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/log.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/urllib/error.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/email/base64mime.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/mimetypes.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/macholib/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/_endian.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/urllib/response.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/dir_util.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/etree/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/test/__init__.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/test/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/macholib/framework.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/distutils/filelist.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/driver.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pygram.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pgen2/parse.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/btm_utils.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/nturl2path.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/netrc.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/subprocess.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/warnings.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/re.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/linecache.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/stat.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/typing.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/encodings/aliases.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/difflib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/gettext.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/cmd.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/asyncio/proactor_events.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/bz2.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/connection.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/multiprocessing/resource_tracker.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/hashlib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/datetime.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/logging/handlers.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/macholib/dylib.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/py_compile.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib2to3/pytree.py/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/xml/etree/ElementPath.pyextractor_python_version.major3extractor_python_version.minor8extractor_python_version.micro13extractor_python_version.releaselevelfinalextractor_python_version.serial0flags.bytes_warningflags.debugflags.dev_modeFalseflags.dont_write_bytecodeflags.hash_randomization1flags.ignore_environmentflags.inspectflags.interactiveflags.isolatedflags.n_fields15flags.n_sequence_fieldsflags.n_unnamed_fieldsflags.no_siteflags.no_user_siteflags.optimizeflags.quietflags.utf8_modeflags.verbosefloat.digfloat.epsilon2.220446049250313e-16float.mant_dig53float.max1.7976931348623157e+308float.max_10_exp308float.max_exp1024float.min2.2250738585072014e-308float.min_10_exp-307float.min_exp-1021float.n_fields11float.n_sequence_fieldsfloat.n_unnamed_fieldsfloat.radix2float.roundsoptions.alloptions.colorizeoptions.extract_stdlibTrueoptions.guessoptions.helpoptions.ignore_missing_modulesoptions.introspect_coptions.max_import_depthinfoptions.max_procsalloptions.no_symlinksoptions.no_syntax_errorsoptions.noneoptions.pruneoptions.quietoptions.respect_initoptions.splitoptions.topoptions.trace_onlyoptions.trap_cache/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/example/codeql-db/working/trap_cacheoptions.unrolloptions.verboseoptions.verbositysys.prefixsys.path/Users/pwntester/.pyenv/versions/3.8.13/lib/python38.zip:/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8:/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynloadlanguage.version3.11extractor.path/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/site-packagessys.platformdarwinos.sepos.pathsep:extractor.version5.34__call____repr____getattribute____get____set____delete____objclass____bool____doc____add____contains__u'str(object='') -> str +str(bytes_or_buffer[, encoding[, errors]]) -> str + +Create a new string object from the given object. If encoding or +errors is specified, then the object must expose a data buffer +that will be decoded using the given encoding and error handler. +Otherwise, returns the result of object.__str__() (if defined) +or repr(object). +encoding defaults to sys.getdefaultencoding(). +errors defaults to 'strict'.'__eq__u'method_descriptor.__doc__'__qualname__u'member_descriptor.__doc__'__name__u'member_descriptor.__qualname__'__reduce__u'the object's class'u'object.__class__'__class____delattr____dir__u'The base class of the class hierarchy. + +When called, it accepts no arguments and returns a new featureless +instance that has no instance attributes and cannot be given any. +'__format____ge____gt____hash____init__u'classmethod_descriptor.__doc__'u'classmethod_descriptor.__qualname__'u'classmethod_descriptor.__text_signature__'__text_signature__.super.classmethod_descriptor__init_subclass____le____lt____ne____new____reduce_ex____setattr____sizeof____str____subclasshook__objectmember_descriptoru'method_descriptor.__qualname__'u'method_descriptor.__text_signature__'method_descriptor__getitem____getnewargs____iter____len____mod____mul____rmod____rmul__capitalizecasefoldcentercountencodeendswithexpandtabsfindformatformat_mapindexisalnumisalphaisasciiisdecimalisdigitisidentifierislowerisnumericisprintableisspaceistitleisupperjoinljustlowerlstripu'staticmethod.__dict__'__dict__u'staticmethod(function) -> method + +Convert a function to be a static method. + +A static method does not receive an implicit first argument. +To declare a static method, use this idiom: + + class C: + @staticmethod + def f(arg1, arg2, ...): + ... + +It can be called either on the class (e.g. C.f()) or on an instance +(e.g. C().f()). Both the class and the instance are ignored, and +neither is passed implicitly as the first argument to the method. + +Static methods in Python are similar to those found in Java or C++. +For a more advanced concept, see the classmethod builtin.'__func__u'staticmethod.__isabstractmethod__'__isabstractmethod__staticmethodmaketranspartitionreplacerfindrindexrjustrpartitionrsplitrstripsplitsplitlinesstartswithstripswapcasetitletranslateupperzfillunicodeu'builtin_function_or_method.__doc__'__module__u'builtin_function_or_method.__name__'u'builtin_function_or_method.__qualname__'u'builtin_function_or_method.__self__'__self__u'builtin_function_or_method.__text_signature__'builtin_function_or_methodNoneTypeNoneu'method-wrapper.__doc__'u'method-wrapper.__name__'u'method-wrapper.__objclass__'u'method-wrapper.__qualname__'u'method-wrapper.__text_signature__'method-wrapperu'wrapper_descriptor.__doc__'u'wrapper_descriptor.__qualname__'u'wrapper_descriptor.__text_signature__'wrapper_descriptoru'getset_descriptor.__doc__'u'getset_descriptor.__qualname__'getset_descriptoru'type.__abstractmethods__'__abstractmethods____base__u'type.__bases__'__bases____basicsize__u'type.__dict__'__dictoffset__u'type.__doc__'__flags____instancecheck____itemsize__u'type.__module__'__mro__u'type.__name__'__prepare__u'type.__qualname__'__subclasscheck____subclasses__u'type.__text_signature__'__weakrefoffset__mrotypeu'function.__annotations__'__annotations____closure__u'function.__code__'__code__u'function.__defaults__'__defaults__u'function.__dict__'__globals__u'function.__kwdefaults__'__kwdefaults__u'function.__name__'u'function.__qualname__'functionFunctionTypeBuiltinFunctionTypeu'classmethod.__dict__'u'classmethod(function) -> method + +Convert a function to be a class method. + +A class method receives the class as implicit first argument, +just like an instance method receives the instance. +To declare a class method, use this idiom: + + class C: + @classmethod + def f(cls, arg1, arg2, ...): + ... + +It can be called either on the class (e.g. C.f()) or on an instance +(e.g. C().f()). The instance is ignored except for its class. +If a class method is called for a derived class, the derived class +object is passed as the implied first argument. + +Class methods are different than C++ or Java static methods. +If you want those, see the staticmethod builtin.'u'classmethod.__isabstractmethod__'classmethodClassMethodStaticMethodu'Create a module object. + +The name must be a string; the optional doc argument can have any type.'moduleModuleType__del__u'name of the generator'u'generator.__name__'__next__u'qualified name of the generator'u'generator.__qualname__'closegi_codegi_framegi_runningu'object being iterated by yield from, or None'u'generator.gi_yieldfrom'gi_yieldfromsendthrowgenerator__and__u'bool(x) -> bool + +Returns True when the argument x is true, False otherwise. +The builtins True and False are the only two instances of the class bool. +The class bool is a subclass of the class int, and cannot be subclassed.'__or____rand____ror____rxor____xor____abs____ceil____divmod__u'int([x]) -> integer +int(x, base=10) -> integer + +Convert a number or string to an integer, or return 0 if no arguments +are given. If x is a number, return x.__int__(). For floating point +numbers, this truncates towards zero. + +If x is not a number or if base is given, then x must be a string, +bytes, or bytearray instance representing an integer literal in the +given base. The literal can be preceded by '+' or '-' and be surrounded +by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. +Base 0 means to interpret the base from the string as an integer literal. +>>> int('0b100', base=0) +4'__float____floor____floordiv____index____int____invert____lshift____neg____pos____pow____radd____rdivmod____rfloordiv____rlshift____round____rpow____rrshift____rshift____rsub____rtruediv____sub____truediv____trunc__as_integer_ratiobit_lengthconjugateu'the denominator of a rational number in lowest terms'u'int.denominator'denominatorfrom_bytesu'the imaginary part of a complex number'u'int.imag'imagu'the numerator of a rational number in lowest terms'u'int.numerator'numeratoru'the real part of a complex number'u'int.real'realto_bytesintboolbreakpointhook__breakpointhook__displayhook__displayhook__u'This module provides access to some objects used or maintained by the +interpreter and to functions that interact strongly with the interpreter. + +Dynamic objects: + +argv -- command line arguments; argv[0] is the script pathname if known +path -- module search path; path[0] is the script directory, else '' +modules -- dictionary of loaded modules + +displayhook -- called to show results in an interactive session +excepthook -- called to handle any uncaught exception other than SystemExit + To customize printing in an interactive session or to install a custom + top-level exception handler, assign other functions to replace these. + +stdin -- standard input file object; used by input() +stdout -- standard output file object; used by print() +stderr -- standard error object; used for error messages + By assigning other file objects (or objects that behave like files) + to these, it is possible to redirect all of the interpreter's I/O. + +last_type -- type of last uncaught exception +last_value -- value of last uncaught exception +last_traceback -- traceback of last uncaught exception + These three are only available in an interactive session after a + traceback has been printed. + +Static objects: + +builtin_module_names -- tuple of module names built into this interpreter +copyright -- copyright notice pertaining to this interpreter +exec_prefix -- prefix used to find the machine-specific Python library +executable -- absolute path of the executable binary of the Python interpreter +float_info -- a named tuple with information about the float implementation. +float_repr_style -- string indicating the style of repr() output for floats +hash_info -- a named tuple with information about the hash algorithm. +hexversion -- version information encoded as a single integer +implementation -- Python implementation information. +int_info -- a named tuple with information about the int implementation. +maxsize -- the largest supported length of containers. +maxunicode -- the value of the largest Unicode code point +platform -- platform identifier +prefix -- prefix used to find the Python library +thread_info -- a named tuple with information about the thread implementation. +version -- the version of this interpreter as a string +version_info -- version information as a named tuple +__stdin__ -- the original stdin; don't touch! +__stdout__ -- the original stdout; don't touch! +__stderr__ -- the original stderr; don't touch! +__displayhook__ -- the original displayhook; don't touch! +__excepthook__ -- the original excepthook; don't touch! + +Functions: + +displayhook() -- print an object to the screen, and save it in builtins._ +excepthook() -- print an exception and its traceback to sys.stderr +exc_info() -- return thread-safe information about the current exception +exit() -- exit the interpreter by raising SystemExit +getdlopenflags() -- returns flags to be used for dlopen() calls +getprofile() -- get the global profiling function +getrefcount() -- return the reference count for an object (plus one :-) +getrecursionlimit() -- return the max recursion depth for the interpreter +getsizeof() -- return the size of an object in bytes +gettrace() -- get the global debug tracing function +setcheckinterval() -- control how often the interpreter checks for events +setdlopenflags() -- set the flags to be used for dlopen() calls +setprofile() -- set the global profiling function +setrecursionlimit() -- set the max recursion depth for the interpreter +settrace() -- set the global debug tracing function +'excepthook__excepthook__u'dictionary for instance variables (if defined)'u'BuiltinImporter.__dict__'u'Meta path import for built-in modules. + + All methods are either class or static methods to avoid the need to + instantiate the class. + + 'u'_frozen_importlib'u'list of weak references to the object (if defined)'u'BuiltinImporter.__weakref__'__weakref__create_moduleexec_modulefind_modulefind_specget_codeget_sourceis_packageload_modulemodule_repr_frozen_importlib.BuiltinImporter__loader__u'sys'u''__package__u'ModuleSpec.__dict__'u'The specification for a module, used for loading. + + A module's spec is the source for information about the module. For + data associated with the module, including source, use the spec's + loader. + + `name` is the absolute name of the module. `loader` is the loader + to use when loading the module. `parent` is the name of the + package the module is in. The parent is derived from the name. + + `is_package` determines if the module is considered a package or + not. On modules this is reflected by the `__path__` attribute. + + `origin` is the specific location used by the loader from which to + load the module, if that information is available. When filename is + set, origin will match. + + `has_location` indicates that a spec's "origin" reflects a location. + When this is True, `__file__` attribute of the module is set. + + `cached` is the location of the cached bytecode file, if any. It + corresponds to the `__cached__` attribute. + + `submodule_search_locations` is the sequence of path entries to + search when importing submodules. If set, is_package should be + True--and False otherwise. + + Packages are simply modules that (may) have submodules. If a spec + has a non-None value in `submodule_search_locations`, the import + system will consider modules loaded from the spec as packages. + + Only finders (see importlib.abc.MetaPathFinder and + importlib.abc.PathEntryFinder) should modify ModuleSpec instances. + + 'u'ModuleSpec.__weakref__'u'property.__isabstractmethod__'deleterfdelfgetfsetgettersetterpropertycachedhas_locationparent_frozen_importlib.ModuleSpec__spec__u'TextIOWrapper._CHUNK_SIZE'_CHUNK_SIZEu'Character and line based layer over a BufferedIOBase object, buffer. + +encoding gives the name of the encoding that the stream will be +decoded or encoded with. It defaults to locale.getpreferredencoding(False). + +errors determines the strictness of encoding and decoding (see +help(codecs.Codec) or the documentation for codecs.register) and +defaults to "strict". + +newline controls how line endings are handled. It can be None, '', +'\n', '\r', and '\r\n'. It works as follows: + +* On input, if newline is None, universal newlines mode is + enabled. Lines in the input can end in '\n', '\r', or '\r\n', and + these are translated into '\n' before being returned to the + caller. If it is '', universal newline mode is enabled, but line + endings are returned to the caller untranslated. If it has any of + the other legal values, input lines are only terminated by the given + string, and the line ending is returned to the caller untranslated. + +* On output, if newline is None, any '\n' characters written are + translated to the system default line separator, os.linesep. If + newline is '' or '\n', no translation takes place. If newline is any + of the other legal values, any '\n' characters written are translated + to the given string. + +If line_buffering is True, a call to flush is implied when a call to +write contains a newline character.'_finalizingbufferu'TextIOWrapper.closed'closeddetachencodingu'TextIOWrapper.errors'errorsfilenoflushisattyline_bufferingu'TextIOWrapper.name'nameu'TextIOWrapper.newlines'newlinesreadreadablereadlinereconfigureseekseekabletelltruncatewritablewritewrite_throughu'Base class for text I/O. + +This class provides a character and line based interface to stream +I/O. There is no readinto method because Python's character strings +are immutable. There is no public constructor. +'u'Encoding of the text stream. + +Subclasses should override. +'u'_TextIOBase.encoding'u'The error setting of the decoder or encoder. + +Subclasses should override. +'u'_TextIOBase.errors'u'Line endings translated so far. + +Only line endings translated during reading are considered. + +Subclasses should override. +'u'_TextIOBase.newlines'u'_IOBase.__dict__'u'The abstract base class for all I/O classes, acting on streams of +bytes. There is no public constructor. + +This class provides dummy implementations for many methods that +derived classes can override selectively; the default implementations +represent a file that cannot be read, written or seeked. + +Even though IOBase does not declare read, readinto, or write because +their signatures will vary, implementations and clients should +consider those methods part of the interface. Also, implementations +may raise UnsupportedOperation when operations they do not support are +called. + +The basic type used for binary data read from or written to a file is +bytes. Other bytes-like objects are accepted as method arguments too. +In some cases (such as readinto), a writable object is required. Text +I/O classes work with str data. + +Note that calling any method (except additional calls to close(), +which are ignored) on a closed stream should raise a ValueError. + +IOBase (and its subclasses) support the iterator protocol, meaning +that an IOBase object can be iterated over yielding the lines in a +stream. + +IOBase also supports the :keyword:`with` statement. In this example, +fp is closed after the suite of the with statement is complete: + +with open('spam.txt', 'r') as fp: + fp.write('Spam and eggs!') +'__enter____exit___checkClosed_checkReadable_checkSeekable_checkWritableu'_IOBase.closed'readlineswritelines_io._IOBase_io._TextIOBase_io.TextIOWrapper__stderr____stdin____stdout__unraisablehook__unraisablehook__u'/Users/pwntester/.pyenv/versions/3.8.13/bin/python3'_base_executable_clear_type_cache_current_frames_debugmallocstats_framework_getframeu'Built-in immutable sequence. + +If no argument is given, the constructor returns an empty tuple. +If iterable is specified the tuple is initialized from iterable's items. + +If the argument is a tuple, the return value is the same object.'tupleu'CPython'_git__delitem__u'dict() -> new empty dictionary +dict(mapping) -> new dictionary initialized from a mapping object's + (key, value) pairs +dict(iterable) -> new dictionary initialized as if via: + d = {} + for k, v in iterable: + d[k] = v +dict(**kwargs) -> new dictionary initialized with the name=value pairs + in the keyword argument list. For example: dict(one=1, two=2)'__reversed____setitem__clearcopyfromkeysgetitemskeyspoppopitemsetdefaultupdatevaluesdict_xoptionsabiflagsaddaudithook1013api_versionu'Built-in mutable sequence. + +If no argument is given, the constructor creates a new empty list. +The argument must be an iterable if specified.'__iadd____imul__appendextendinsertremovereversesortlistu'/Users/pwntester/.local/share/nvim/mason/packages/codeql/codeql/python/tools/python_tracer.py'u'-v'u'-z'u'all'u'-c'u'/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/example/codeql-db/working/trap_cache'u'-p'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/site-packages'u'-R'u'/Users/pwntester/src/github.com/github/codeql-jupyter-kernel/example/src'argvauditu'/Users/pwntester/.pyenv/versions/3.8.13'base_exec_prefixbase_prefixu'_abc'u'_ast'u'_codecs'u'_collections'u'_functools'u'_imp'u'_io'u'_locale'u'_operator'u'_signal'u'_sre'u'_stat'u'_string'u'_symtable'u'_thread'u'_tracemalloc'u'_warnings'u'_weakref'u'atexit'u'builtins'u'errno'u'faulthandler'u'gc'u'itertools'u'marshal'u'posix'u'pwd'u'time'u'xxsubtype'builtin_module_namesu'little'byteordercall_tracingcallstatsu'Copyright (c) 2001-2022 Python Software Foundation. +All Rights Reserved. + +Copyright (c) 2000 BeOpen.com. +All Rights Reserved. + +Copyright (c) 1995-2001 Corporation for National Research Initiatives. +All Rights Reserved. + +Copyright (c) 1991-1995 Stichting Mathematisch Centrum, Amsterdam. +All Rights Reserved.'copyrightdont_write_bytecodeexc_infoexec_prefixexecutableexitu'sys.flags + +Flags provided through command line arguments or environment vars.'bytes_warningdebugdev_modehash_randomizationignore_environmentinspectinteractiveisolatedn_fieldsn_sequence_fieldsn_unnamed_fieldsno_siteno_user_siteoptimizequietutf8_modeverbosesys.flagsflagsu'sys.float_info + +A named tuple holding information about the float type. It contains low level +information about the precision and internal representation. Please study +your system's :file:`float.h` for more information.'digepsilonmant_digmaxmax_10_expmax_expminmin_10_expmin_expradixroundssys.float_infou'Convert a string or number to a floating point number, if possible.'__getformat____set_format__fromhexhexu'float.imag'is_integeru'float.real'floatfloat_infou'short'float_repr_styleget_asyncgen_hooksget_coroutine_origin_tracking_depthgetallocatedblocksgetcheckintervalgetdefaultencodinggetdlopenflagsgetfilesystemencodeerrorsgetfilesystemencodinggetprofilegetrecursionlimitgetrefcountgetsizeofgetswitchintervalgettraceu'hash_info + +A named tuple providing parameters used for computing +hashes. The attributes are read only.'algorithmcutoffhash_bitsmodulus9nanseed_bitswidthsys.hash_info6423058430092136939513141591000003u'siphash24'128hash_info50859504hexversionu'A simple attribute-based namespace. + +SimpleNamespace(**kwargs)'types.SimpleNamespaceimplementationu'sys.int_info + +A named tuple that holds information about Python's +internal representation of integers. The attributes are read only.'bits_per_digitsizeof_digitsys.int_info304int_infointernis_finalizing9223372036854775807maxsize1114111maxunicodeu'frozen'_ORIGINu'FrozenImporter.__dict__'u'Meta path import for frozen modules. + + All methods are either class or static methods to avoid the need to + instantiate the class. + + 'u'FrozenImporter.__weakref__'_frozen_importlib.FrozenImporteru'PathFinder.__dict__'u'Meta path finder for sys.path and package __path__ attributes.'u'_frozen_importlib_external'u'PathFinder.__weakref__'_get_spec_legacy_get_spec_path_hooks_path_importer_cachefind_distributionsinvalidate_caches_frozen_importlib_external.PathFindermeta_pathmodulesu'/Users/pwntester/.local/share/nvim/mason/packages/codeql/codeql/python/tools/python3src.zip'u'/Users/pwntester/.local/share/nvim/mason/packages/codeql/codeql/python/tools'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python38.zip'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload'pathu'zipimporter.__dict__'u'zipimporter(archivepath) -> zipimporter object + + Create a new zipimporter instance. 'archivepath' must be a path to + a zipfile, or to a specific path inside a zipfile. For example, it can be + '/tmp/myimport.zip', or '/tmp/myimport.zip/mydirectory', if mydirectory is a + valid directory inside the archive. + + 'ZipImportError is raised if 'archivepath' doesn't point to a valid Zip + archive. + + The 'archive' attribute of zipimporter objects contains the name of the + zipfile targeted. + 'u'zipimport'u'zipimporter.__weakref__'find_loaderget_dataget_filenameget_resource_readerzipimport.zipimporterpath_hook_for_FileFinderpath_hookspath_importer_cacheu'darwin'platformprefixpycache_prefixset_asyncgen_hooksset_coroutine_origin_tracking_depthsetcheckintervalsetdlopenflagssetprofilesetrecursionlimitsetswitchintervalsettracestderrstdinstdoutu'sys.thread_info + +A named tuple holding information about the thread implementation.'lockversionsys.thread_infou'pthread'u'mutex+cond'thread_infou'3.8.13 (default, Oct 3 2022, 12:54:21) +[Clang 14.0.0 (clang-1400.0.29.102)]'u'sys.version_info + +Version information as a named tuple.'majormicrominor5releaselevelserialsys.version_infou'final'version_infowarnoptionssysu'Common base class for all non-exit exceptions.'u'exception cause'u'BaseException.__cause__'__cause__u'exception context'u'BaseException.__context__'__context__u'BaseException.__dict__'u'Common base class for all exceptions'__setstate____suppress_context__u'BaseException.__traceback__'__traceback__u'BaseException.args'argswith_tracebackBaseExceptionExceptionu'Inappropriate argument type.'TypeErroru'Attribute not found.'AttributeErroru'Mapping key not found.'u'Base class for lookup errors.'LookupErrorKeyErroru'set() -> new empty set object +set(iterable) -> new set object + +Build an unordered collection of unique elements.'__iand____ior____isub____ixor__adddifferencedifference_updatediscardintersectionintersection_updateisdisjointissubsetissupersetsymmetric_differencesymmetric_difference_updateunionsetlocalsglobalsMethodDescriptorTypeu'super() -> same as super(__class__, ) +super(type) -> unbound super object +super(type, obj) -> bound super object; requires isinstance(obj, type) +super(type, type2) -> bound super object; requires issubclass(type2, type) +Typical use to call a cooperative superclass method: +class C(B): + def meth(self, arg): + super().meth(arg) +This works for class methods too: +class C(B): + @classmethod + def cmeth(cls, arg): + super().cmeth(arg) +'__self_class____thisclass__superu'method.__doc__'methodMethodType_1_2u'bytes(iterable_of_ints) -> bytes +bytes(string, encoding[, errors]) -> bytes +bytes(bytes_or_buffer) -> immutable copy of bytes_or_buffer +bytes(int) -> bytes object of size given by the parameter initialized with null bytes +bytes() -> empty bytes object + +Construct an immutable array of bytes from: + - an iterable yielding integers in range(256) + - a text string encoded using the specified encoding + - any object implementing the buffer API. + - an integer'decodebytesb'2'b2b'3'b3u'2'u2u'3'u3u'Base class for arithmetic errors.'ArithmeticErroru'Assertion failed.'AssertionErroru'I/O operation would block.'u'Base class for I/O related errors.'u'OSError.characters_written'characters_writtenerrnofilenamefilename2strerrorOSErrorBlockingIOErroru'Broken pipe.'u'Connection error.'ConnectionErrorBrokenPipeErroru'Buffer error.'BufferErroru'Base class for warnings about bytes and buffer related problems, mostly +related to conversion from str or comparing to str.'u'Base class for warning categories.'WarningBytesWarningu'Child process error.'ChildProcessErroru'Connection aborted.'ConnectionAbortedErroru'Connection refused.'ConnectionRefusedErroru'Connection reset.'ConnectionResetErroru'Base class for warnings about deprecated features.'DeprecationWarningu'Read beyond end of file.'EOFErrorellipsisEllipsisEnvironmentErroru'File already exists.'FileExistsErroru'File not found.'FileNotFoundErroru'Floating point operation failed.'FloatingPointErroru'Base class for warnings about constructs that will change semantically +in the future.'FutureWarningu'Request that a generator exit.'GeneratorExitIOErroru'Import can't find module, or can't find name in module.'msgImportErroru'Base class for warnings about probable mistakes in module imports'ImportWarningu'Improper indentation.'u'Invalid syntax.'linenooffsetprint_file_and_linetextSyntaxErrorIndentationErroru'Sequence index out of range.'IndexErroru'Interrupted by signal.'InterruptedErroru'Operation doesn't work on directories.'IsADirectoryErroru'Program interrupted by user.'KeyboardInterruptu'Out of memory.'MemoryErroru'Module not found.'ModuleNotFoundErroru'Name not found globally.'NameErroru'Operation only works on directories.'NotADirectoryErrorNotImplementedTypeNotImplementedu'Method or function hasn't been implemented yet.'u'Unspecified run-time error.'RuntimeErrorNotImplementedErroru'Result too large to be represented.'OverflowErroru'Base class for warnings about features which will be deprecated +in the future.'PendingDeprecationWarningu'Not enough permissions.'PermissionErroru'Process not found.'ProcessLookupErroru'Recursion limit exceeded.'RecursionErroru'Weak ref proxy used after referent went away.'ReferenceErroru'Base class for warnings about resource usage.'ResourceWarningu'Base class for warnings about dubious runtime behavior.'RuntimeWarningu'Signal the end from iterator.__anext__().'StopAsyncIterationu'Signal the end from iterator.__next__().'valueStopIterationu'Base class for warnings about dubious syntax.'SyntaxWarningu'Internal error in the Python interpreter. + +Please report this to the Python maintainer, along with the traceback, +the Python version, and the hardware/OS platform and version.'SystemErroru'Request to exit from the interpreter.'codeSystemExitu'Improper mixture of spaces and tabs.'TabErroru'Timeout expired.'TimeoutErroru'Local name referenced but not bound to a value.'UnboundLocalErroru'Unicode decoding error.'endreasonstartu'Unicode related error.'u'Inappropriate argument value (of correct type).'ValueErrorUnicodeErrorUnicodeDecodeErroru'Unicode encoding error.'UnicodeEncodeErroru'Unicode translation error.'UnicodeTranslateErroru'Base class for warnings about Unicode related problems, mostly +related to conversion problems.'UnicodeWarningu'Base class for warnings generated by user code.'UserWarningu'Second argument to a division or modulo operation was zero.'ZeroDivisionError__build_class____debug__u'Built-in functions, exceptions, and other objects. + +Noteworthy: None is the `nil' object; Ellipsis represents `...' in slices.'__import__absanyasciibinbreakpoint__alloc__u'bytearray(iterable_of_ints) -> bytearray +bytearray(string, encoding[, errors]) -> bytearray +bytearray(bytes_or_buffer) -> mutable copy of bytes_or_buffer +bytearray(int) -> bytes array of size given by the parameter initialized with null bytes +bytearray() -> empty bytes array + +Construct a mutable bytearray object from: + - an iterable yielding integers in range(256) + - a text string encoded using the specified encoding + - a bytes or a buffer object + - any object implementing the buffer API. + - an integer'bytearraycallablechrcompileu'Create a complex number from a real part and an optional imaginary part. + +This is equivalent to (real + imag*1j) where imag defaults to 0.'complexdelattrdirdivmodu'Return an enumerate object. + + iterable + an object supporting iteration + +The enumerate object yields pairs containing a count (from start, which +defaults to zero) and a value yielded by the iterable argument. + +enumerate is useful for obtaining an indexed list: + (0, seq[0]), (1, seq[1]), (2, seq[2]), ...'enumerateevalexecu'filter(function or None, iterable) --> filter object + +Return an iterator yielding those items of iterable for which function(item) +is true. If function is None, return the items that are true.'filteru'frozenset() -> empty frozenset object +frozenset(iterable) -> frozenset object + +Build an immutable unordered collection of unique elements.'frozensetgetattrhasattrhashidinputisinstanceissubclassiterlenu'map(func, *iterables) --> map object + +Make an iterator that computes the function using arguments from +each of the iterables. Stops when the shortest iterable is exhausted.'mapu'Create a new memoryview object which references the given object.'u'A bool indicating whether the memory is C contiguous.'u'memoryview.c_contiguous'c_contiguouscastu'A bool indicating whether the memory is contiguous.'u'memoryview.contiguous'contiguousu'A bool indicating whether the memory is Fortran contiguous.'u'memoryview.f_contiguous'f_contiguousu'A string containing the format (in struct module style) + for each element in the view.'u'memoryview.format'u'The size in bytes of each element of the memoryview.'u'memoryview.itemsize'itemsizeu'The amount of space in bytes that the array would use in + a contiguous representation.'u'memoryview.nbytes'nbytesu'An integer indicating how many dimensions of a multi-dimensional + array the memory represents.'u'memoryview.ndim'ndimu'The underlying object of the memoryview.'u'memoryview.obj'obju'A bool indicating whether the memory is read only.'u'memoryview.readonly'readonlyreleaseu'A tuple of ndim integers giving the shape of the memory + as an N-dimensional array.'u'memoryview.shape'shapeu'A tuple of ndim integers giving the size in bytes to access + each element for each dimension of the array.'u'memoryview.strides'stridesu'A tuple of integers used internally for PIL-style arrays.'u'memoryview.suboffsets'suboffsetstobytestolisttoreadonlymemoryviewnextoctopenordpowprintu'range(stop) -> range object +range(start, stop[, step]) -> range object + +Return an object that produces a sequence of integers from start (inclusive) +to stop (exclusive) by step. range(i, j) produces i, i+1, i+2, ..., j-1. +start defaults to 0, and stop is omitted! range(4) produces 0, 1, 2, 3. +These are exactly the valid indices for a list of 4 elements. +When step is given, it specifies the increment (or decrement).'stepstoprangerepru'Return a reverse iterator over the values of the given sequence.'__length_hint__reversedroundsetattru'slice(stop) +slice(start, stop[, step]) + +Create a slice object. This is used for extended slicing (e.g. a[0:10:2]).'indicesslicesortedstrsumvarsu'zip(*iterables) --> A zip object yielding tuples until an input is exhausted. + + >>> list(zip('abcdefg', range(3), range(4))) + [('a', 0, 0), ('b', 1, 1), ('c', 2, 2)] + +The zip object yields n-length tuples, where n is the number of iterables +passed as positional arguments to zip(). The i-th element in every tuple +comes from the i-th iterable argument to zip(). This continues until the +shortest argument is exhausted.'zipbuiltinsbuiltin_module_semmle_unknown_type_semmle_undefined_value$re('[^']*'|\"[^\"]*\"|::|//?|\.\.|\(\)|[/.*:\[\]\(\)@=])|((?:\{[^}]+\})?[^/\[\]\(\)@=\s]+)|\s+r"r"("r"'[^']*'|\"[^\"]*\"|"r"::|"r"//?|"r"\.\.|"r"\(\)|"r"[/.*:\[\]\(\)@=])|"r"((?:\{[^}]+\})?[^/\[\]\(\)@=\s]+)|"r"\s+"xpath_tokenizer_rexpath_tokenizerpatternnamespaces'default_namespaceparsing_attributetokenfindallttypetag{"uri{%s}%sprefix %r not found in prefix map@get_parent_mapcontextparent_mapproote_is_wildcard_tag{*}}*_prepare_tag_isinstance_str{*}*selectresultelem{}*el_tagsuffixno_nsnsns_onlyinternal parser error, got f"prepare_childselect_tagselect_child{}prepare_starprepare_selfprepare_descendant*invalid descendantprepare_parentresult_mapprepare_predicatesignaturepredicate]'"-@-key@-='match\-?\d+$.='-='itertext-()-()-XPath position >= 1 expectedlastunsupported functionunsupported expressionXPath offset from last() must be negativeelemsinvalid predicate...//[ops_cache_SelectorContextselfiterfindcache_keyselector100cannot use absolute path on elementinvalid pathfindtextdefault## ElementTree# $Id: ElementPath.py 3375 2008-02-13 08:05:08Z fredrik $# limited xpath support for element trees# history:# 2003-05-23 fl created# 2003-05-28 fl added support for // etc# 2003-08-27 fl fixed parsing of periods in element names# 2007-09-10 fl new selection engine# 2007-09-12 fl fixed parent selector# 2007-09-13 fl added iterfind; changed findall to return a list# 2007-11-30 fl added namespaces support# 2009-10-30 fl added child element value filter# Copyright (c) 2003-2009 by Fredrik Lundh. All rights reserved.# fredrik@pythonware.com# http://www.pythonware.com# --------------------------------------------------------------------# The ElementTree toolkit is# Copyright (c) 1999-2009 by Fredrik Lundh# By obtaining, using, and/or copying this software and/or its# associated documentation, you agree that you have read, understood,# and will comply with the following terms and conditions:# Permission to use, copy, modify, and distribute this software and# its associated documentation for any purpose and without fee is# hereby granted, provided that the above copyright notice appears in# all copies, and that both that copyright notice and this permission# notice appear in supporting documentation, and that the name of# Secret Labs AB or the author not be used in advertising or publicity# pertaining to distribution of the software without specific, written# prior permission.# SECRET LABS AB AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD# TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANT-# ABILITY AND FITNESS. IN NO EVENT SHALL SECRET LABS AB OR THE AUTHOR# BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY# DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,# WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS# ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE# OF THIS SOFTWARE.# Licensed to PSF under a Contributor Agreement.# See http://www.python.org/psf/license for licensing details.### Implementation module for XPath support. There's usually no reason# to import this module directly; the ElementTree does this for# you, if needed.# Same as '*', but no comments or processing instructions.# It can be a surprise that '*' includes those, but there is no# justification for '{*}*' doing the same.# Any tag that is not in a namespace.# The tag in any (or no) namespace.# '}name'# Any tag in the given namespace.# '{}tag' == 'tag'# FIXME: raise error if .. is applied at toplevel?# FIXME: replace with real parser!!! refs:# http://effbot.org/zone/simple-iterator-parser.htm# http://javascript.crockford.com/tdop/tdop.html# ignore whitespace# use signature to determine predicate type# [@attribute] predicate# [@attribute='value']# [tag]# [.='value'] or [tag='value']# [index] or [last()] or [last()-index]# [index]# FIXME: what if the selector is "*" ?# Generate all matching objects.# compile selector pattern# implicit all (FIXME: keep this?)# execute selector pattern# Find first matching object.# Find all matching objects.# Find text for first matching object.b'('[^']*'|\"[^\"]*\"|::|//?|\.\.|\(\)|[/.*:\[\]\(\)@=])|((?:\{[^}]+\})?[^/\[\]\(\)@=\s]+)|\s+'u'('[^']*'|\"[^\"]*\"|::|//?|\.\.|\(\)|[/.*:\[\]\(\)@=])|((?:\{[^}]+\})?[^/\[\]\(\)@=\s]+)|\s+'b''b'{'u'{'b':'u':'b'{%s}%s'u'{%s}%s'b'prefix %r not found in prefix map'u'prefix %r not found in prefix map'b'@'u'@'b'{*}'u'{*}'b'}*'u'}*'b'{*}*'u'{*}*'b'{}*'u'{}*'b'internal parser error, got 'u'internal parser error, got 'b'{}'u'{}'b'*'u'*'b'invalid descendant'u'invalid descendant'b']'u']'b''"'u''"'b'''u'''b'-'u'-'b'@-'u'@-'b'@-=''u'@-=''b'\-?\d+$'u'\-?\d+$'b'.=''u'.=''b'-=''u'-=''b'-()'u'-()'b'-()-'u'-()-'b'XPath position >= 1 expected'u'XPath position >= 1 expected'b'last'u'last'b'unsupported function'u'unsupported function'b'unsupported expression'u'unsupported expression'b'XPath offset from last() must be negative'u'XPath offset from last() must be negative'b'invalid predicate'u'invalid predicate'b'.'u'.'b'..'u'..'b'//'u'//'b'['u'['b'/'u'/'b'cannot use absolute path on element'u'cannot use absolute path on element'b'invalid path'u'invalid path'u'xml.etree.ElementPath'u'xml.etree'u'xml'u'etree.ElementPath'u'etree'u'ElementPath'Lightweight XML support for Python. + + XML is an inherently hierarchical data format, and the most natural way to + represent it is with a tree. This module has two classes for this purpose: + + 1. ElementTree represents the whole XML document as a tree and + + 2. Element represents a single node in this tree. + + Interactions with the whole document (reading and writing to/from files) are + usually done on the ElementTree level. Interactions with a single XML element + and its sub-elements are done on the Element level. + + Element is a flexible container object designed to store hierarchical data + structures in memory. It can be described as a cross between a list and a + dictionary. Each Element has a number of properties associated with it: + + 'tag' - a string containing the element's name. + + 'attributes' - a Python dictionary storing the element's attributes. + + 'text' - a string containing the element's text content. + + 'tail' - an optional string containing text after the element's end tag. + + And a number of child elements stored in a Python sequence. + + To create an element instance, use the Element constructor, + or the SubElement factory function. + + You can also use the ElementTree class to wrap an element structure + and convert it to and from XML. + +"""CommentdumpElementElementTreefromstringfromstringlistiselementiterparseparseParseErrorPIProcessingInstructionQNameSubElementtostringtostringlistTreeBuilderVERSIONXMLXMLIDXMLParserXMLPullParserregister_namespacecanonicalizeC14NWriterTarget__all__1.3.0warningsiocollectionscollections.abccontextlibElementPathAn error when parsing an XML document. + + In addition to its exception value, a ParseError contains + two extra attributes: + 'code' - the specific exception code + 'position' - the line and column of the error + + elementReturn True if *element* appears to be an Element.An XML element. + + This class is the reference implementation of the Element interface. + + An element's length is its number of subelements. That means if you + want to check if an element is truly empty, you should check BOTH + its length AND its text attribute. + + The element tag, attribute names, and attribute values can be either + bytes or strings. + + *tag* is the element name. *attrib* is an optional dictionary containing + element attributes. *extra* are additional element attributes given as + keyword arguments. + + Example form: + text...tail + + The element's name.attribDictionary of the element's attributes. + Text before first subelement. This is either a string or the value None. + Note that if there is no text, this attribute may be either + None or the empty string, depending on the parser. + + tail + Text after this element's end tag, but before the next sibling element's + start tag. This is either a string or the value None. Note that if there + was no text, this attribute may be either None or an empty string, + depending on the parser. + + extraattrib must be dict, not %s_children<%s %r at %#x>makeelementCreate a new element with the same type. + + *tag* is a string containing the element name. + *attrib* is a dictionary containing the element attributes. + + Do not call this method, use the SubElement factory function instead. + + Return copy of current element. + + This creates a shallow copy. Subelements will be shared with the + original tree. + + warnThe behavior of this method will change in future versions. Use specific 'len(elem)' or 'elem is not None' test instead."The behavior of this method will change in future versions. ""Use specific 'len(elem)' or 'elem is not None' test instead."stacklevelelt_assert_is_elementsubelementAdd *subelement* to the end of this element. + + The new element will appear in document order after the last existing + subelement (or directly after the text, if it's the first subelement), + but before the end tag for this element. + + elementsAppend subelements from a sequence. + + *elements* is a sequence with zero or more elements. + + Insert *subelement* at position *index*._Element_Pyexpected an Element, not %sRemove matching subelement. + + Unlike the find methods, this method compares elements based on + identity, NOT ON tag value or contents. To remove subelements by + other means, the easiest way is to use a list comprehension to + select what elements to keep, and then use slice assignment to update + the parent element. + + ValueError is raised if a matching element could not be found. + + getchildren(Deprecated) Return all subelements. + + Elements are returned in document order. + + This method will be removed in future versions. Use 'list(elem)' or iteration over elem instead."This method will be removed in future versions. ""Use 'list(elem)' or iteration over elem instead."Find first matching element by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + Find text for first matching element by tag name or path. + + *path* is a string having either an element tag or an XPath, + *default* is the value to return if the element was not found, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return text content of first matching element, or default value if + none was found. Note that if an element is found having no text + content, the empty string is returned. + + Find all matching subelements by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Returns list containing all matching elements in document order. + + Find all matching subelements by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return an iterable yielding all matching elements in document order. + + Reset element. + + This function removes all subelements, clears all attributes, and sets + the text and tail attributes to None. + + Get element attribute. + + Equivalent to attrib.get, but some implementations may handle this a + bit more efficiently. *key* is what attribute to look for, and + *default* is what to return if the attribute was not found. + + Returns a string containing the attribute value, or the default if + attribute was not found. + + Set element attribute. + + Equivalent to attrib[key] = value, but some implementations may handle + this a bit more efficiently. *key* is what attribute to set, and + *value* is the attribute value to set it to. + + Get list of attribute names. + + Names are returned in an arbitrary order, just like an ordinary + Python dict. Equivalent to attrib.keys() + + Get element attributes as a sequence. + + The attributes are returned in arbitrary order. Equivalent to + attrib.items(). + + Return a list of (name, value) tuples. + + Create tree iterator. + + The iterator loops over the element and all subelements in document + order, returning all elements with a matching tag. + + If the tree structure is modified during iteration, new or removed + elements may or may not be included. To get a stable set, use the + list() function on the iterator, and loop over the resulting list. + + *tag* is what tags to look for (default is to return all elements) + + Return an iterator containing all the matching elements. + + getiteratorThis method will be removed in future versions. Use 'elem.iter()' or 'list(elem.iter())' instead."Use 'elem.iter()' or 'list(elem.iter())' instead."Create text iterator. + + The iterator loops over the element and all subelements in document + order, returning all inner text. + + tSubelement factory which creates an element instance, and appends it + to an existing parent. + + The element tag, attribute names, and attribute values can be either + bytes or Unicode strings. + + *parent* is the parent element, *tag* is the subelements name, *attrib* is + an optional directory containing element attributes, *extra* are + additional attributes given as keyword arguments. + + Comment element factory. + + This function creates a special element which the standard serializer + serializes as an XML comment. + + *text* is a string containing the comment string. + + targetProcessing Instruction element factory. + + This function creates a special element which the standard serializer + serializes as an XML comment. + + *target* is a string containing the processing instruction, *text* is a + string containing the processing instruction contents, if any. + + Qualified name wrapper. + + This class can be used to wrap a QName attribute value in order to get + proper namespace handing on output. + + *text_or_uri* is a string containing the QName value either in the form + {uri}local, or if the tag argument is given, the URI part of a QName. + + *tag* is an optional argument which if given, will make the first + argument (text_or_uri) be interpreted as a URI, and this argument (tag) + be interpreted as a local name. + + text_or_uri<%s %r>otherAn XML element hierarchy. + + This class also provides support for serialization to and from + standard XML. + + *element* is an optional root element node, + *file* is an optional file handle or file name of an XML file whose + contents will be used to initialize the tree with. + + file_rootgetrootReturn root element of this tree._setrootReplace root element of this tree. + + This will discard the current contents of the tree and replace it + with the given element. Use with care! + + sourceparserLoad external XML document into element tree. + + *source* is a file name or file object, *parser* is an optional parser + instance that defaults to XMLParser. + + ParseError is raised if the parser fails to parse the document. + + Returns the root element of the given source document. + + close_sourcerb_parse_whole65536datafeedCreate and return tree iterator for the root element. + + The iterator loops over all elements in this tree, in document order. + + *tag* is a string with the tag name to iterate over + (default is to return all elements). + + This method will be removed in future versions. Use 'tree.iter()' or 'list(tree.iter())' instead."Use 'tree.iter()' or 'list(tree.iter())' instead."Find first matching element by tag name or path. + + Same as getroot().find(path), which is Element.find() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + This search is broken in 1.3 and earlier, and will be fixed in a future version. If you rely on the current behaviour, change it to %r"This search is broken in 1.3 and earlier, and will be ""fixed in a future version. If you rely on the current ""behaviour, change it to %r"Find first matching element by tag name or path. + + Same as getroot().findtext(path), which is Element.findtext() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + Find all matching subelements by tag name or path. + + Same as getroot().findall(path), which is Element.findall(). + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return list containing all matching elements in document order. + + Find all matching subelements by tag name or path. + + Same as getroot().iterfind(path), which is element.iterfind() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return an iterable yielding all matching elements in document order. + + file_or_filenamexml_declarationshort_empty_elementsWrite element tree to a file as XML. + + Arguments: + *file_or_filename* -- file name or a file object opened for writing + + *encoding* -- the output encoding (default: US-ASCII) + + *xml_declaration* -- bool indicating if an XML declaration should be + added to the output. If None, an XML declaration + is added if encoding IS NOT either of: + US-ASCII, UTF-8, or Unicode + + *default_namespace* -- sets the default XML namespace (for "xmlns") + + *method* -- either "xml" (default), "html, "text", or "c14n" + + *short_empty_elements* -- controls the formatting of elements + that contain no content. If True (default) + they are emitted as a single self-closed + tag, otherwise they are emitted as a pair + of start/end tags + + xml_serializeunknown method %rc14nutf-8us-asciienc_lower_get_writerdeclared_encodinglocalegetpreferredencoding +_serialize_text_namespacesqnamesserializewrite_c14ncontextmanagerExitStackstackBufferedIOBaseRawIOBaseBufferedWritercallbacklambdaTextIOWrapperxmlcharrefreplace +newlinewadd_qnameqname}_namespace_mapns%d%s:%scannot use non-qualified names with default_namespace option"cannot use non-qualified names with ""default_namespace option"_raise_serialization_error_serialize_xmlkwargs_escape_cdataareabasebasefontbrcolframehrimgisindexlinkmetaparamHTML_EMPTY_serialize_html_escape_attrib_htmlltagscriptstyleparthtmlRegister a namespace prefix. + + The registry is global, and any existing mapping for either the + given prefix or the namespace URI will be removed. + + *prefix* is the namespace prefix, *uri* is a namespace uri. Tags and + attributes in this namespace will be serialized with prefix if possible. + + ValueError is raised if prefix is reserved or is invalid. + + ns\d+$Prefix format reserved for internal usehttp://www.w3.org/XML/1998/namespacehttp://www.w3.org/1999/xhtmlrdfhttp://www.w3.org/1999/02/22-rdf-syntax-ns#wsdlhttp://schemas.xmlsoap.org/wsdl/xshttp://www.w3.org/2001/XMLSchemaxsihttp://www.w3.org/2001/XMLSchema-instancedchttp://purl.org/dc/elements/1.1/cannot serialize %r (type %s)&&<>" + Generate string representation of XML element. + + All subelements are included. If encoding is "unicode", a string + is returned. Otherwise a bytestring is returned. + + *element* is an Element instance, *encoding* is an optional output + encoding defaulting to US-ASCII, *method* is an optional output which can + be one of "xml" (default), "html", "text" or "c14n", *default_namespace* + sets the default XML namespace (for "xmlns"). + + Returns an (optionally) encoded string containing the XML data. + + StringIOBytesIOstreamgetvalue_ListDataStreamAn auxiliary stream accumulating into a list reference.lstbWrite element tree or element structure to sys.stdout. + + This function should be used for debugging only. + + *elem* is either an ElementTree, or a single Element. The exact output + format is implementation dependent. In this version, it's written as an + ordinary XML file. + + Parse XML document into element tree. + + *source* is a filename or file object containing XML data, + *parser* is an optional parser instance defaulting to XMLParser. + + Return an ElementTree instance. + + treeeventsIncrementally parse XML document into ElementTree. + + This class also reports what's going on to the user based on the + *events* it is initialized with. The supported events are the strings + "start", "end", "start-ns" and "end-ns" (the "ns" events are used to get + detailed namespace information). If *events* is omitted, only + "end" events are reported. + + *source* is a filename or file object containing XML data, *events* is + a list of events to report back, *parser* is an optional parser instance. + + Returns an iterator providing (event, elem) pairs. + + _parserpullparseriteratorread_events16_close_and_return_rootitIterParseIteratorabcIteratordeque_events_queue_seteventsFeed encoded data to parser.feed() called after end of streamexcFinish feeding data to parser. + + Unlike XMLParser, does not return the root element. Use + read_events() to consume elements from XMLPullParser. + Return an iterator over currently available (event, elem) pairs. + + Events are consumed from the internal event queue as they are + retrieved from the iterator. + poplefteventParse XML document from string constant. + + This function can be used to embed "XML Literals" in Python code. + + *text* is a string containing XML data, *parser* is an + optional parser instance, defaulting to the standard XMLParser. + + Returns an Element instance. + + Parse XML document from string constant for its IDs. + + *text* is a string containing XML data, *parser* is an + optional parser instance, defaulting to the standard XMLParser. + + Returns an (Element, dict) tuple, in which the + dict maps element id:s to elements. + + idssequenceParse XML document from sequence of string fragments. + + *sequence* is a list of other sequence, *parser* is an optional parser + instance, defaulting to the standard XMLParser. + + Returns an Element instance. + + Generic element structure builder. + + This builder converts a sequence of start, data, and end method + calls to a well-formed element structure. + + You can use this class to build an element structure using a custom XML + parser, or a parser for some other XML-like format. + + *element_factory* is an optional element factory which is called + to create new Element instances, as necessary. + + *comment_factory* is a factory to create comments to be used instead of + the standard factory. If *insert_comments* is false (the default), + comments will not be inserted into the tree. + + *pi_factory* is a factory to create processing instructions to be used + instead of the standard factory. If *insert_pis* is false (the default), + processing instructions will not be inserted into the tree. + element_factorycomment_factorypi_factoryinsert_commentsinsert_pis_data_elem_last_tail_comment_factory_pi_factory_factoryFlush builder buffers and return toplevel document Element.missing end tagsmissing toplevel element_flushinternal error (tail)internal error (text)Add text to current element.attrsOpen new element and return it. + + *tag* is the element name, *attrs* is a dict containing element + attributes. + + Close and return current Element. + + *tag* is the element name. + + end tag mismatch (expected %s, got %s)commentCreate a comment using the comment_factory. + + *text* is the text of the comment. + _handle_singlepiCreate a processing instruction using the pi_factory. + + *target* is the target name of the processing instruction. + *text* is the data of the processing instruction, or ''. + factoryElement structure builder for XML source data based on the expat parser. + + *target* is an optional target object which defaults to an instance of the + standard TreeBuilder class, *encoding* is an optional encoding string + which if given, overrides the encoding specified in the XML file: + http://www.iana.org/assignments/character-sets + + xml.parsersexpatpyexpatNo module named expat; use SimpleXMLTreeBuilder insteadParserCreate_targeterror_error_names_defaultDefaultHandlerExpand_startStartElementHandler_endEndElementHandlerstart_ns_start_nsStartNamespaceDeclHandlerend_ns_end_nsEndNamespaceDeclHandlerCharacterDataHandlerCommentHandlerProcessingInstructionHandlerbuffer_textordered_attributesspecified_attributes_doctypeentityExpat %d.%d.%devents_queueevents_to_reportevent_namehandlerattrib_instart-nsend-nspi_targetunknown event %r_raiseerrorerrposition_fixnameattr_listfixnameidata_handlerundefined entity %s: line %d, column %dErrorLineNumberErrorColumnNumber _elementtree_set_factories#---------------------------------------------------------------------# Copyright (c) 1999-2008 by Fredrik Lundh. All rights reserved.# Copyright (c) 1999-2008 by Fredrik Lundh# public symbols# emulate old behaviour, for now# Need to refer to the actual Python implementation, not the# shadowing C implementation.# assert iselement(element)# compatibility# assert element is None or iselement(element)# first node# If no parser was specified, create a default XMLParser# The default XMLParser, when it comes from an accelerator,# can define an internal _parse_whole API for efficiency.# It can be used to parse the whole source without feeding# it with chunks.# assert self._root is not None# Retrieve the default encoding for the xml declaration# lxml.etree compatibility. use output method instead# serialization support# returns text write method and release all resources after using# file_or_filename is a file name# file_or_filename is a file-like object# encoding determines if it is a text or binary writer# use a text writer as is# wrap a binary writer with TextIOWrapper# Keep the original file open when the BufferedWriter is# destroyed# This is to handle passed objects that aren't in the# IOBase hierarchy, but just have a write method# TextIOWrapper uses this methods to determine# if BOM (for UTF-16, etc) should be added# Keep the original file open when the TextIOWrapper is# identify namespaces used in this tree# maps qnames to *encoded* prefix:local names# maps uri:s to prefixes# calculate serialized qname representation# default element# FIXME: can this be handled in XML 1.0?# populate qname and namespaces table# sort on prefix# FIXME: handle boolean attributes# this optional method is imported at the end of the module# "c14n": _serialize_c14n,# "well-known" namespace prefixes# xml schema# dublin core# For tests and troubleshooting# escape character data# it's worth avoiding do-nothing calls for strings that are# shorter than 500 characters, or so. assume that's, by far,# the most common case in most applications.# escape attribute value# The following business with carriage returns is to satisfy# Section 2.11 of the XML specification, stating that# CR or CR LN should be replaced with just LN# http://www.w3.org/TR/REC-xml/#sec-line-ends#The following four lines are issue 17582# debugging# parsing# Use the internal, undocumented _parser argument for now; When the# parser argument of iterparse is removed, this can be killed.# load event buffer# The _parser argument is for internal use only and must not be relied# upon in user code. It will be removed in a future release.# See http://bugs.python.org/issue17741 for more details.# wire up the parser for event reporting# iterparse needs this to set its root attribute properly :(# Parse XML document from string constant. Alias for XML().# data collector# element stack# last element# root element# true if we're after an end tag# also see ElementTree and TreeBuilder# underscored names are provided for compatibility only# name memo cache# main callbacks# miscellaneous callbacks# Configure pyexpat: buffering, new-style attribute handling.# unknown# Internal API for XMLPullParser# events_to_report: a list of events to report during parsing (same as# the *events* of XMLPullParser's constructor.# events_queue: a list of actual parsing events that will be populated# by the underlying parser.# TreeBuilder does not implement .start_ns()# TreeBuilder does not implement .end_ns()# expand qname, and convert name string to ascii, if possible# Handler for expat's StartElementHandler. Since ordered_attributes# is set, the attributes are reported as a list of alternating# attribute name,value.# deal with undefined entities# XML_ERROR_UNDEFINED_ENTITY# inside a doctype declaration# parse doctype contents# end of data# get rid of circular references# C14N 2.0# Stack with globally and newly declared namespaces as (uri, prefix) pairs.# Stack with user declared namespace prefixes as (uri, prefix) pairs.# almost no element declares new namespaces# Not declared yet => add new declaration.# No default namespace declared => no prefix needed.# As soon as a default namespace is defined,# anything that has no namespace (and thus, no prefix) goes there.# we may have to resolve qnames in text content# Need to parse text first to see if it requires a prefix declaration.# Resolve prefixes in attribute and tag text.# Assign prefixes in lexicographical order of used URIs.# Write namespace declarations in prefix order ...# almost always empty# ... followed by attributes in URI+name order# No prefix for attributes in default ('') namespace.# Honour xml:space attributes.# Write the tag.# Write the resolved qname text content.# shorter than 500 character, or so. assume that's, by far,# Import the C accelerators# Element is going to be shadowed by the C implementation. We need to keep# the Python version of it accessible for some "creative" by external code# (see tests)# Element, SubElement, ParseError, TreeBuilder, XMLParser, _set_factoriesb'Lightweight XML support for Python. + + XML is an inherently hierarchical data format, and the most natural way to + represent it is with a tree. This module has two classes for this purpose: + + 1. ElementTree represents the whole XML document as a tree and + + 2. Element represents a single node in this tree. + + Interactions with the whole document (reading and writing to/from files) are + usually done on the ElementTree level. Interactions with a single XML element + and its sub-elements are done on the Element level. + + Element is a flexible container object designed to store hierarchical data + structures in memory. It can be described as a cross between a list and a + dictionary. Each Element has a number of properties associated with it: + + 'tag' - a string containing the element's name. + + 'attributes' - a Python dictionary storing the element's attributes. + + 'text' - a string containing the element's text content. + + 'tail' - an optional string containing text after the element's end tag. + + And a number of child elements stored in a Python sequence. + + To create an element instance, use the Element constructor, + or the SubElement factory function. + + You can also use the ElementTree class to wrap an element structure + and convert it to and from XML. + +'u'Lightweight XML support for Python. + + XML is an inherently hierarchical data format, and the most natural way to + represent it is with a tree. This module has two classes for this purpose: + + 1. ElementTree represents the whole XML document as a tree and + + 2. Element represents a single node in this tree. + + Interactions with the whole document (reading and writing to/from files) are + usually done on the ElementTree level. Interactions with a single XML element + and its sub-elements are done on the Element level. + + Element is a flexible container object designed to store hierarchical data + structures in memory. It can be described as a cross between a list and a + dictionary. Each Element has a number of properties associated with it: + + 'tag' - a string containing the element's name. + + 'attributes' - a Python dictionary storing the element's attributes. + + 'text' - a string containing the element's text content. + + 'tail' - an optional string containing text after the element's end tag. + + And a number of child elements stored in a Python sequence. + + To create an element instance, use the Element constructor, + or the SubElement factory function. + + You can also use the ElementTree class to wrap an element structure + and convert it to and from XML. + +'b'Comment'u'Comment'b'dump'u'dump'b'Element'u'Element'b'ElementTree'u'ElementTree'b'fromstring'u'fromstring'b'fromstringlist'u'fromstringlist'b'iselement'u'iselement'b'iterparse'u'iterparse'b'parse'u'parse'b'ParseError'u'ParseError'b'PI'u'PI'b'ProcessingInstruction'u'ProcessingInstruction'b'QName'u'QName'b'SubElement'u'SubElement'b'tostring'u'tostring'b'tostringlist'u'tostringlist'b'TreeBuilder'u'TreeBuilder'b'VERSION'u'VERSION'b'XML'u'XML'b'XMLID'u'XMLID'b'XMLParser'u'XMLParser'b'XMLPullParser'u'XMLPullParser'b'register_namespace'u'register_namespace'b'canonicalize'u'canonicalize'b'C14NWriterTarget'u'C14NWriterTarget'b'1.3.0'u'1.3.0'b'An error when parsing an XML document. + + In addition to its exception value, a ParseError contains + two extra attributes: + 'code' - the specific exception code + 'position' - the line and column of the error + + 'u'An error when parsing an XML document. + + In addition to its exception value, a ParseError contains + two extra attributes: + 'code' - the specific exception code + 'position' - the line and column of the error + + 'b'Return True if *element* appears to be an Element.'u'Return True if *element* appears to be an Element.'b'tag'u'tag'b'An XML element. + + This class is the reference implementation of the Element interface. + + An element's length is its number of subelements. That means if you + want to check if an element is truly empty, you should check BOTH + its length AND its text attribute. + + The element tag, attribute names, and attribute values can be either + bytes or strings. + + *tag* is the element name. *attrib* is an optional dictionary containing + element attributes. *extra* are additional element attributes given as + keyword arguments. + + Example form: + text...tail + + 'u'An XML element. + + This class is the reference implementation of the Element interface. + + An element's length is its number of subelements. That means if you + want to check if an element is truly empty, you should check BOTH + its length AND its text attribute. + + The element tag, attribute names, and attribute values can be either + bytes or strings. + + *tag* is the element name. *attrib* is an optional dictionary containing + element attributes. *extra* are additional element attributes given as + keyword arguments. + + Example form: + text...tail + + 'b'The element's name.'u'The element's name.'b'Dictionary of the element's attributes.'u'Dictionary of the element's attributes.'b' + Text before first subelement. This is either a string or the value None. + Note that if there is no text, this attribute may be either + None or the empty string, depending on the parser. + + 'u' + Text before first subelement. This is either a string or the value None. + Note that if there is no text, this attribute may be either + None or the empty string, depending on the parser. + + 'b' + Text after this element's end tag, but before the next sibling element's + start tag. This is either a string or the value None. Note that if there + was no text, this attribute may be either None or an empty string, + depending on the parser. + + 'u' + Text after this element's end tag, but before the next sibling element's + start tag. This is either a string or the value None. Note that if there + was no text, this attribute may be either None or an empty string, + depending on the parser. + + 'b'attrib must be dict, not %s'u'attrib must be dict, not %s'b'<%s %r at %#x>'u'<%s %r at %#x>'b'Create a new element with the same type. + + *tag* is a string containing the element name. + *attrib* is a dictionary containing the element attributes. + + Do not call this method, use the SubElement factory function instead. + + 'u'Create a new element with the same type. + + *tag* is a string containing the element name. + *attrib* is a dictionary containing the element attributes. + + Do not call this method, use the SubElement factory function instead. + + 'b'Return copy of current element. + + This creates a shallow copy. Subelements will be shared with the + original tree. + + 'u'Return copy of current element. + + This creates a shallow copy. Subelements will be shared with the + original tree. + + 'b'The behavior of this method will change in future versions. Use specific 'len(elem)' or 'elem is not None' test instead.'u'The behavior of this method will change in future versions. Use specific 'len(elem)' or 'elem is not None' test instead.'b'Add *subelement* to the end of this element. + + The new element will appear in document order after the last existing + subelement (or directly after the text, if it's the first subelement), + but before the end tag for this element. + + 'u'Add *subelement* to the end of this element. + + The new element will appear in document order after the last existing + subelement (or directly after the text, if it's the first subelement), + but before the end tag for this element. + + 'b'Append subelements from a sequence. + + *elements* is a sequence with zero or more elements. + + 'u'Append subelements from a sequence. + + *elements* is a sequence with zero or more elements. + + 'b'Insert *subelement* at position *index*.'u'Insert *subelement* at position *index*.'b'expected an Element, not %s'u'expected an Element, not %s'b'Remove matching subelement. + + Unlike the find methods, this method compares elements based on + identity, NOT ON tag value or contents. To remove subelements by + other means, the easiest way is to use a list comprehension to + select what elements to keep, and then use slice assignment to update + the parent element. + + ValueError is raised if a matching element could not be found. + + 'u'Remove matching subelement. + + Unlike the find methods, this method compares elements based on + identity, NOT ON tag value or contents. To remove subelements by + other means, the easiest way is to use a list comprehension to + select what elements to keep, and then use slice assignment to update + the parent element. + + ValueError is raised if a matching element could not be found. + + 'b'(Deprecated) Return all subelements. + + Elements are returned in document order. + + 'u'(Deprecated) Return all subelements. + + Elements are returned in document order. + + 'b'This method will be removed in future versions. Use 'list(elem)' or iteration over elem instead.'u'This method will be removed in future versions. Use 'list(elem)' or iteration over elem instead.'b'Find first matching element by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + 'u'Find first matching element by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + 'b'Find text for first matching element by tag name or path. + + *path* is a string having either an element tag or an XPath, + *default* is the value to return if the element was not found, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return text content of first matching element, or default value if + none was found. Note that if an element is found having no text + content, the empty string is returned. + + 'u'Find text for first matching element by tag name or path. + + *path* is a string having either an element tag or an XPath, + *default* is the value to return if the element was not found, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return text content of first matching element, or default value if + none was found. Note that if an element is found having no text + content, the empty string is returned. + + 'b'Find all matching subelements by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Returns list containing all matching elements in document order. + + 'u'Find all matching subelements by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Returns list containing all matching elements in document order. + + 'b'Find all matching subelements by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return an iterable yielding all matching elements in document order. + + 'u'Find all matching subelements by tag name or path. + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return an iterable yielding all matching elements in document order. + + 'b'Reset element. + + This function removes all subelements, clears all attributes, and sets + the text and tail attributes to None. + + 'u'Reset element. + + This function removes all subelements, clears all attributes, and sets + the text and tail attributes to None. + + 'b'Get element attribute. + + Equivalent to attrib.get, but some implementations may handle this a + bit more efficiently. *key* is what attribute to look for, and + *default* is what to return if the attribute was not found. + + Returns a string containing the attribute value, or the default if + attribute was not found. + + 'u'Get element attribute. + + Equivalent to attrib.get, but some implementations may handle this a + bit more efficiently. *key* is what attribute to look for, and + *default* is what to return if the attribute was not found. + + Returns a string containing the attribute value, or the default if + attribute was not found. + + 'b'Set element attribute. + + Equivalent to attrib[key] = value, but some implementations may handle + this a bit more efficiently. *key* is what attribute to set, and + *value* is the attribute value to set it to. + + 'u'Set element attribute. + + Equivalent to attrib[key] = value, but some implementations may handle + this a bit more efficiently. *key* is what attribute to set, and + *value* is the attribute value to set it to. + + 'b'Get list of attribute names. + + Names are returned in an arbitrary order, just like an ordinary + Python dict. Equivalent to attrib.keys() + + 'u'Get list of attribute names. + + Names are returned in an arbitrary order, just like an ordinary + Python dict. Equivalent to attrib.keys() + + 'b'Get element attributes as a sequence. + + The attributes are returned in arbitrary order. Equivalent to + attrib.items(). + + Return a list of (name, value) tuples. + + 'u'Get element attributes as a sequence. + + The attributes are returned in arbitrary order. Equivalent to + attrib.items(). + + Return a list of (name, value) tuples. + + 'b'Create tree iterator. + + The iterator loops over the element and all subelements in document + order, returning all elements with a matching tag. + + If the tree structure is modified during iteration, new or removed + elements may or may not be included. To get a stable set, use the + list() function on the iterator, and loop over the resulting list. + + *tag* is what tags to look for (default is to return all elements) + + Return an iterator containing all the matching elements. + + 'u'Create tree iterator. + + The iterator loops over the element and all subelements in document + order, returning all elements with a matching tag. + + If the tree structure is modified during iteration, new or removed + elements may or may not be included. To get a stable set, use the + list() function on the iterator, and loop over the resulting list. + + *tag* is what tags to look for (default is to return all elements) + + Return an iterator containing all the matching elements. + + 'b'This method will be removed in future versions. Use 'elem.iter()' or 'list(elem.iter())' instead.'u'This method will be removed in future versions. Use 'elem.iter()' or 'list(elem.iter())' instead.'b'Create text iterator. + + The iterator loops over the element and all subelements in document + order, returning all inner text. + + 'u'Create text iterator. + + The iterator loops over the element and all subelements in document + order, returning all inner text. + + 'b'Subelement factory which creates an element instance, and appends it + to an existing parent. + + The element tag, attribute names, and attribute values can be either + bytes or Unicode strings. + + *parent* is the parent element, *tag* is the subelements name, *attrib* is + an optional directory containing element attributes, *extra* are + additional attributes given as keyword arguments. + + 'u'Subelement factory which creates an element instance, and appends it + to an existing parent. + + The element tag, attribute names, and attribute values can be either + bytes or Unicode strings. + + *parent* is the parent element, *tag* is the subelements name, *attrib* is + an optional directory containing element attributes, *extra* are + additional attributes given as keyword arguments. + + 'b'Comment element factory. + + This function creates a special element which the standard serializer + serializes as an XML comment. + + *text* is a string containing the comment string. + + 'u'Comment element factory. + + This function creates a special element which the standard serializer + serializes as an XML comment. + + *text* is a string containing the comment string. + + 'b'Processing Instruction element factory. + + This function creates a special element which the standard serializer + serializes as an XML comment. + + *target* is a string containing the processing instruction, *text* is a + string containing the processing instruction contents, if any. + + 'u'Processing Instruction element factory. + + This function creates a special element which the standard serializer + serializes as an XML comment. + + *target* is a string containing the processing instruction, *text* is a + string containing the processing instruction contents, if any. + + 'b' 'u' 'b'Qualified name wrapper. + + This class can be used to wrap a QName attribute value in order to get + proper namespace handing on output. + + *text_or_uri* is a string containing the QName value either in the form + {uri}local, or if the tag argument is given, the URI part of a QName. + + *tag* is an optional argument which if given, will make the first + argument (text_or_uri) be interpreted as a URI, and this argument (tag) + be interpreted as a local name. + + 'u'Qualified name wrapper. + + This class can be used to wrap a QName attribute value in order to get + proper namespace handing on output. + + *text_or_uri* is a string containing the QName value either in the form + {uri}local, or if the tag argument is given, the URI part of a QName. + + *tag* is an optional argument which if given, will make the first + argument (text_or_uri) be interpreted as a URI, and this argument (tag) + be interpreted as a local name. + + 'b'<%s %r>'u'<%s %r>'b'An XML element hierarchy. + + This class also provides support for serialization to and from + standard XML. + + *element* is an optional root element node, + *file* is an optional file handle or file name of an XML file whose + contents will be used to initialize the tree with. + + 'u'An XML element hierarchy. + + This class also provides support for serialization to and from + standard XML. + + *element* is an optional root element node, + *file* is an optional file handle or file name of an XML file whose + contents will be used to initialize the tree with. + + 'b'Return root element of this tree.'u'Return root element of this tree.'b'Replace root element of this tree. + + This will discard the current contents of the tree and replace it + with the given element. Use with care! + + 'u'Replace root element of this tree. + + This will discard the current contents of the tree and replace it + with the given element. Use with care! + + 'b'Load external XML document into element tree. + + *source* is a file name or file object, *parser* is an optional parser + instance that defaults to XMLParser. + + ParseError is raised if the parser fails to parse the document. + + Returns the root element of the given source document. + + 'u'Load external XML document into element tree. + + *source* is a file name or file object, *parser* is an optional parser + instance that defaults to XMLParser. + + ParseError is raised if the parser fails to parse the document. + + Returns the root element of the given source document. + + 'b'read'u'read'b'rb'u'rb'b'_parse_whole'u'_parse_whole'b'Create and return tree iterator for the root element. + + The iterator loops over all elements in this tree, in document order. + + *tag* is a string with the tag name to iterate over + (default is to return all elements). + + 'u'Create and return tree iterator for the root element. + + The iterator loops over all elements in this tree, in document order. + + *tag* is a string with the tag name to iterate over + (default is to return all elements). + + 'b'This method will be removed in future versions. Use 'tree.iter()' or 'list(tree.iter())' instead.'u'This method will be removed in future versions. Use 'tree.iter()' or 'list(tree.iter())' instead.'b'Find first matching element by tag name or path. + + Same as getroot().find(path), which is Element.find() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + 'u'Find first matching element by tag name or path. + + Same as getroot().find(path), which is Element.find() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + 'b'This search is broken in 1.3 and earlier, and will be fixed in a future version. If you rely on the current behaviour, change it to %r'u'This search is broken in 1.3 and earlier, and will be fixed in a future version. If you rely on the current behaviour, change it to %r'b'Find first matching element by tag name or path. + + Same as getroot().findtext(path), which is Element.findtext() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + 'u'Find first matching element by tag name or path. + + Same as getroot().findtext(path), which is Element.findtext() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return the first matching element, or None if no element was found. + + 'b'Find all matching subelements by tag name or path. + + Same as getroot().findall(path), which is Element.findall(). + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return list containing all matching elements in document order. + + 'u'Find all matching subelements by tag name or path. + + Same as getroot().findall(path), which is Element.findall(). + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return list containing all matching elements in document order. + + 'b'Find all matching subelements by tag name or path. + + Same as getroot().iterfind(path), which is element.iterfind() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return an iterable yielding all matching elements in document order. + + 'u'Find all matching subelements by tag name or path. + + Same as getroot().iterfind(path), which is element.iterfind() + + *path* is a string having either an element tag or an XPath, + *namespaces* is an optional mapping from namespace prefix to full name. + + Return an iterable yielding all matching elements in document order. + + 'b'Write element tree to a file as XML. + + Arguments: + *file_or_filename* -- file name or a file object opened for writing + + *encoding* -- the output encoding (default: US-ASCII) + + *xml_declaration* -- bool indicating if an XML declaration should be + added to the output. If None, an XML declaration + is added if encoding IS NOT either of: + US-ASCII, UTF-8, or Unicode + + *default_namespace* -- sets the default XML namespace (for "xmlns") + + *method* -- either "xml" (default), "html, "text", or "c14n" + + *short_empty_elements* -- controls the formatting of elements + that contain no content. If True (default) + they are emitted as a single self-closed + tag, otherwise they are emitted as a pair + of start/end tags + + 'u'Write element tree to a file as XML. + + Arguments: + *file_or_filename* -- file name or a file object opened for writing + + *encoding* -- the output encoding (default: US-ASCII) + + *xml_declaration* -- bool indicating if an XML declaration should be + added to the output. If None, an XML declaration + is added if encoding IS NOT either of: + US-ASCII, UTF-8, or Unicode + + *default_namespace* -- sets the default XML namespace (for "xmlns") + + *method* -- either "xml" (default), "html, "text", or "c14n" + + *short_empty_elements* -- controls the formatting of elements + that contain no content. If True (default) + they are emitted as a single self-closed + tag, otherwise they are emitted as a pair + of start/end tags + + 'b'xml'b'unknown method %r'u'unknown method %r'b'c14n'u'c14n'b'utf-8'u'utf-8'b'us-ascii'u'us-ascii'b'unicode'u'unicode'b' +'u' +'b'text'u'text'b'xmlcharrefreplace'u'xmlcharrefreplace'b' +'u' +'b'w'u'w'b'}'u'}'b'ns%d'u'ns%d'b'%s:%s'u'%s:%s'b'cannot use non-qualified names with default_namespace option'u'cannot use non-qualified names with default_namespace option'b''u''b''u''b'<'u'<'b' xmlns%s="%s"'u' xmlns%s="%s"'b' %s="%s"'u' %s="%s"'b'>'u'>'b''u' />'b'area'u'area'b'base'u'base'b'basefont'u'basefont'b'br'u'br'b'col'u'col'b'frame'u'frame'b'hr'u'hr'b'img'u'img'b'input'u'input'b'isindex'u'isindex'b'link'u'link'b'meta'u'meta'b'param'u'param'b'script'u'script'b'style'u'style'b'html'u'html'b'Register a namespace prefix. + + The registry is global, and any existing mapping for either the + given prefix or the namespace URI will be removed. + + *prefix* is the namespace prefix, *uri* is a namespace uri. Tags and + attributes in this namespace will be serialized with prefix if possible. + + ValueError is raised if prefix is reserved or is invalid. + + 'u'Register a namespace prefix. + + The registry is global, and any existing mapping for either the + given prefix or the namespace URI will be removed. + + *prefix* is the namespace prefix, *uri* is a namespace uri. Tags and + attributes in this namespace will be serialized with prefix if possible. + + ValueError is raised if prefix is reserved or is invalid. + + 'b'ns\d+$'u'ns\d+$'b'Prefix format reserved for internal use'u'Prefix format reserved for internal use'b'http://www.w3.org/XML/1998/namespace'u'http://www.w3.org/XML/1998/namespace'b'http://www.w3.org/1999/xhtml'u'http://www.w3.org/1999/xhtml'b'rdf'u'rdf'b'http://www.w3.org/1999/02/22-rdf-syntax-ns#'u'http://www.w3.org/1999/02/22-rdf-syntax-ns#'b'wsdl'u'wsdl'b'http://schemas.xmlsoap.org/wsdl/'u'http://schemas.xmlsoap.org/wsdl/'b'xs'u'xs'b'http://www.w3.org/2001/XMLSchema'u'http://www.w3.org/2001/XMLSchema'b'xsi'u'xsi'b'http://www.w3.org/2001/XMLSchema-instance'u'http://www.w3.org/2001/XMLSchema-instance'b'dc'u'dc'b'http://purl.org/dc/elements/1.1/'u'http://purl.org/dc/elements/1.1/'b'cannot serialize %r (type %s)'u'cannot serialize %r (type %s)'b'&'u'&'b'&'u'&'b'<'u'<'b'>'u'>'b'"'u'"'b'"'u'"'b' +'u' +'b' 'u' 'b' 'u' 'b' 'u' 'b' 'u' 'b'Generate string representation of XML element. + + All subelements are included. If encoding is "unicode", a string + is returned. Otherwise a bytestring is returned. + + *element* is an Element instance, *encoding* is an optional output + encoding defaulting to US-ASCII, *method* is an optional output which can + be one of "xml" (default), "html", "text" or "c14n", *default_namespace* + sets the default XML namespace (for "xmlns"). + + Returns an (optionally) encoded string containing the XML data. + + 'u'Generate string representation of XML element. + + All subelements are included. If encoding is "unicode", a string + is returned. Otherwise a bytestring is returned. + + *element* is an Element instance, *encoding* is an optional output + encoding defaulting to US-ASCII, *method* is an optional output which can + be one of "xml" (default), "html", "text" or "c14n", *default_namespace* + sets the default XML namespace (for "xmlns"). + + Returns an (optionally) encoded string containing the XML data. + + 'b'An auxiliary stream accumulating into a list reference.'u'An auxiliary stream accumulating into a list reference.'b'Write element tree or element structure to sys.stdout. + + This function should be used for debugging only. + + *elem* is either an ElementTree, or a single Element. The exact output + format is implementation dependent. In this version, it's written as an + ordinary XML file. + + 'u'Write element tree or element structure to sys.stdout. + + This function should be used for debugging only. + + *elem* is either an ElementTree, or a single Element. The exact output + format is implementation dependent. In this version, it's written as an + ordinary XML file. + + 'b'Parse XML document into element tree. + + *source* is a filename or file object containing XML data, + *parser* is an optional parser instance defaulting to XMLParser. + + Return an ElementTree instance. + + 'u'Parse XML document into element tree. + + *source* is a filename or file object containing XML data, + *parser* is an optional parser instance defaulting to XMLParser. + + Return an ElementTree instance. + + 'b'Incrementally parse XML document into ElementTree. + + This class also reports what's going on to the user based on the + *events* it is initialized with. The supported events are the strings + "start", "end", "start-ns" and "end-ns" (the "ns" events are used to get + detailed namespace information). If *events* is omitted, only + "end" events are reported. + + *source* is a filename or file object containing XML data, *events* is + a list of events to report back, *parser* is an optional parser instance. + + Returns an iterator providing (event, elem) pairs. + + 'u'Incrementally parse XML document into ElementTree. + + This class also reports what's going on to the user based on the + *events* it is initialized with. The supported events are the strings + "start", "end", "start-ns" and "end-ns" (the "ns" events are used to get + detailed namespace information). If *events* is omitted, only + "end" events are reported. + + *source* is a filename or file object containing XML data, *events* is + a list of events to report back, *parser* is an optional parser instance. + + Returns an iterator providing (event, elem) pairs. + + 'b'end'u'end'b'Feed encoded data to parser.'u'Feed encoded data to parser.'b'feed() called after end of stream'u'feed() called after end of stream'b'Finish feeding data to parser. + + Unlike XMLParser, does not return the root element. Use + read_events() to consume elements from XMLPullParser. + 'u'Finish feeding data to parser. + + Unlike XMLParser, does not return the root element. Use + read_events() to consume elements from XMLPullParser. + 'b'Return an iterator over currently available (event, elem) pairs. + + Events are consumed from the internal event queue as they are + retrieved from the iterator. + 'u'Return an iterator over currently available (event, elem) pairs. + + Events are consumed from the internal event queue as they are + retrieved from the iterator. + 'b'Parse XML document from string constant. + + This function can be used to embed "XML Literals" in Python code. + + *text* is a string containing XML data, *parser* is an + optional parser instance, defaulting to the standard XMLParser. + + Returns an Element instance. + + 'u'Parse XML document from string constant. + + This function can be used to embed "XML Literals" in Python code. + + *text* is a string containing XML data, *parser* is an + optional parser instance, defaulting to the standard XMLParser. + + Returns an Element instance. + + 'b'Parse XML document from string constant for its IDs. + + *text* is a string containing XML data, *parser* is an + optional parser instance, defaulting to the standard XMLParser. + + Returns an (Element, dict) tuple, in which the + dict maps element id:s to elements. + + 'u'Parse XML document from string constant for its IDs. + + *text* is a string containing XML data, *parser* is an + optional parser instance, defaulting to the standard XMLParser. + + Returns an (Element, dict) tuple, in which the + dict maps element id:s to elements. + + 'b'id'u'id'b'Parse XML document from sequence of string fragments. + + *sequence* is a list of other sequence, *parser* is an optional parser + instance, defaulting to the standard XMLParser. + + Returns an Element instance. + + 'u'Parse XML document from sequence of string fragments. + + *sequence* is a list of other sequence, *parser* is an optional parser + instance, defaulting to the standard XMLParser. + + Returns an Element instance. + + 'b'Generic element structure builder. + + This builder converts a sequence of start, data, and end method + calls to a well-formed element structure. + + You can use this class to build an element structure using a custom XML + parser, or a parser for some other XML-like format. + + *element_factory* is an optional element factory which is called + to create new Element instances, as necessary. + + *comment_factory* is a factory to create comments to be used instead of + the standard factory. If *insert_comments* is false (the default), + comments will not be inserted into the tree. + + *pi_factory* is a factory to create processing instructions to be used + instead of the standard factory. If *insert_pis* is false (the default), + processing instructions will not be inserted into the tree. + 'u'Generic element structure builder. + + This builder converts a sequence of start, data, and end method + calls to a well-formed element structure. + + You can use this class to build an element structure using a custom XML + parser, or a parser for some other XML-like format. + + *element_factory* is an optional element factory which is called + to create new Element instances, as necessary. + + *comment_factory* is a factory to create comments to be used instead of + the standard factory. If *insert_comments* is false (the default), + comments will not be inserted into the tree. + + *pi_factory* is a factory to create processing instructions to be used + instead of the standard factory. If *insert_pis* is false (the default), + processing instructions will not be inserted into the tree. + 'b'Flush builder buffers and return toplevel document Element.'u'Flush builder buffers and return toplevel document Element.'b'missing end tags'u'missing end tags'b'missing toplevel element'u'missing toplevel element'b'internal error (tail)'u'internal error (tail)'b'internal error (text)'u'internal error (text)'b'Add text to current element.'u'Add text to current element.'b'Open new element and return it. + + *tag* is the element name, *attrs* is a dict containing element + attributes. + + 'u'Open new element and return it. + + *tag* is the element name, *attrs* is a dict containing element + attributes. + + 'b'Close and return current Element. + + *tag* is the element name. + + 'u'Close and return current Element. + + *tag* is the element name. + + 'b'end tag mismatch (expected %s, got %s)'u'end tag mismatch (expected %s, got %s)'b'Create a comment using the comment_factory. + + *text* is the text of the comment. + 'u'Create a comment using the comment_factory. + + *text* is the text of the comment. + 'b'Create a processing instruction using the pi_factory. + + *target* is the target name of the processing instruction. + *text* is the data of the processing instruction, or ''. + 'u'Create a processing instruction using the pi_factory. + + *target* is the target name of the processing instruction. + *text* is the data of the processing instruction, or ''. + 'b'Element structure builder for XML source data based on the expat parser. + + *target* is an optional target object which defaults to an instance of the + standard TreeBuilder class, *encoding* is an optional encoding string + which if given, overrides the encoding specified in the XML file: + http://www.iana.org/assignments/character-sets + + 'u'Element structure builder for XML source data based on the expat parser. + + *target* is an optional target object which defaults to an instance of the + standard TreeBuilder class, *encoding* is an optional encoding string + which if given, overrides the encoding specified in the XML file: + http://www.iana.org/assignments/character-sets + + 'b'No module named expat; use SimpleXMLTreeBuilder instead'u'No module named expat; use SimpleXMLTreeBuilder instead'b'start'u'start'b'start_ns'u'start_ns'b'end_ns'u'end_ns'b'data'u'data'b'comment'u'comment'b'pi'u'pi'b'Expat %d.%d.%d'u'Expat %d.%d.%d'b'start-ns'u'start-ns'b'end-ns'u'end-ns'b'unknown event %r'u'unknown event %r'b'undefined entity %s: line %d, column %d'u'undefined entity %s: line %d, column %d'b''u'-->'b''u'?>'b' 'u' 'b' 'u' 'b' 'u' 'u'xml.etree.ElementTree'u'etree.ElementTree'Record of phased-in incompatible language changes. + +Each line is of the form: + + FeatureName = "_Feature(" OptionalRelease "," MandatoryRelease "," + CompilerFlag ")" + +where, normally, OptionalRelease < MandatoryRelease, and both are 5-tuples +of the same form as sys.version_info: + + (PY_MAJOR_VERSION, # the 2 in 2.1.0a3; an int + PY_MINOR_VERSION, # the 1; an int + PY_MICRO_VERSION, # the 0; an int + PY_RELEASE_LEVEL, # "alpha", "beta", "candidate" or "final"; string + PY_RELEASE_SERIAL # the 3; an int + ) + +OptionalRelease records the first release in which + + from __future__ import FeatureName + +was accepted. + +In the case of MandatoryReleases that have not yet occurred, +MandatoryRelease predicts the release in which the feature will become part +of the language. + +Else MandatoryRelease records when the feature became part of the language; +in releases at or after that, modules no longer need + + from __future__ import FeatureName + +to use the feature in question, but may continue to use such imports. + +MandatoryRelease may also be None, meaning that a planned feature got +dropped. + +Instances of class _Feature have two corresponding methods, +.getOptionalRelease() and .getMandatoryRelease(). + +CompilerFlag is the (bitfield) flag that should be passed in the fourth +argument to the builtin function compile() to enable the feature in +dynamically compiled code. This flag is stored in the .compiler_flag +attribute on _Future instances. These values must match the appropriate +#defines of CO_xxx flags in Include/compile.h. + +No feature line is ever to be deleted from this file. +nested_scopesgeneratorsdivisionabsolute_importwith_statementprint_functionunicode_literalsbarry_as_FLUFLgenerator_stopannotationsall_feature_names0x0010CO_NESTEDCO_GENERATOR_ALLOWED1310720x20000CO_FUTURE_DIVISION2621440x40000CO_FUTURE_ABSOLUTE_IMPORT5242880x80000CO_FUTURE_WITH_STATEMENT10485760x100000CO_FUTURE_PRINT_FUNCTION20971520x200000CO_FUTURE_UNICODE_LITERALS41943040x400000CO_FUTURE_BARRY_AS_BDFL83886080x800000CO_FUTURE_GENERATOR_STOP167772160x1000000CO_FUTURE_ANNOTATIONS_FeatureoptionalReleasemandatoryReleasecompiler_flagoptionalmandatorygetOptionalReleaseReturn first release in which this feature was recognized. + + This is a 5-tuple, of the same form as sys.version_info. + getMandatoryReleaseReturn release in which this feature will become mandatory. + + This is a 5-tuple, of the same form as sys.version_info, or, if + the feature was dropped, is None. + betaalpha6710# The CO_xxx symbols are defined here under the same names defined in# code.h and used by compile.h, so that an editor search will find them here.# However, they're not exported in __all__, because they don't really belong to# this module.# nested_scopes# generators (obsolete, was 0x1000)# division# perform absolute imports by default# with statement# print function# unicode string literals# StopIteration becomes RuntimeError in generators# annotations become strings at runtimeb'Record of phased-in incompatible language changes. + +Each line is of the form: + + FeatureName = "_Feature(" OptionalRelease "," MandatoryRelease "," + CompilerFlag ")" + +where, normally, OptionalRelease < MandatoryRelease, and both are 5-tuples +of the same form as sys.version_info: + + (PY_MAJOR_VERSION, # the 2 in 2.1.0a3; an int + PY_MINOR_VERSION, # the 1; an int + PY_MICRO_VERSION, # the 0; an int + PY_RELEASE_LEVEL, # "alpha", "beta", "candidate" or "final"; string + PY_RELEASE_SERIAL # the 3; an int + ) + +OptionalRelease records the first release in which + + from __future__ import FeatureName + +was accepted. + +In the case of MandatoryReleases that have not yet occurred, +MandatoryRelease predicts the release in which the feature will become part +of the language. + +Else MandatoryRelease records when the feature became part of the language; +in releases at or after that, modules no longer need + + from __future__ import FeatureName + +to use the feature in question, but may continue to use such imports. + +MandatoryRelease may also be None, meaning that a planned feature got +dropped. + +Instances of class _Feature have two corresponding methods, +.getOptionalRelease() and .getMandatoryRelease(). + +CompilerFlag is the (bitfield) flag that should be passed in the fourth +argument to the builtin function compile() to enable the feature in +dynamically compiled code. This flag is stored in the .compiler_flag +attribute on _Future instances. These values must match the appropriate +#defines of CO_xxx flags in Include/compile.h. + +No feature line is ever to be deleted from this file. +'u'Record of phased-in incompatible language changes. + +Each line is of the form: + + FeatureName = "_Feature(" OptionalRelease "," MandatoryRelease "," + CompilerFlag ")" + +where, normally, OptionalRelease < MandatoryRelease, and both are 5-tuples +of the same form as sys.version_info: + + (PY_MAJOR_VERSION, # the 2 in 2.1.0a3; an int + PY_MINOR_VERSION, # the 1; an int + PY_MICRO_VERSION, # the 0; an int + PY_RELEASE_LEVEL, # "alpha", "beta", "candidate" or "final"; string + PY_RELEASE_SERIAL # the 3; an int + ) + +OptionalRelease records the first release in which + + from __future__ import FeatureName + +was accepted. + +In the case of MandatoryReleases that have not yet occurred, +MandatoryRelease predicts the release in which the feature will become part +of the language. + +Else MandatoryRelease records when the feature became part of the language; +in releases at or after that, modules no longer need + + from __future__ import FeatureName + +to use the feature in question, but may continue to use such imports. + +MandatoryRelease may also be None, meaning that a planned feature got +dropped. + +Instances of class _Feature have two corresponding methods, +.getOptionalRelease() and .getMandatoryRelease(). + +CompilerFlag is the (bitfield) flag that should be passed in the fourth +argument to the builtin function compile() to enable the feature in +dynamically compiled code. This flag is stored in the .compiler_flag +attribute on _Future instances. These values must match the appropriate +#defines of CO_xxx flags in Include/compile.h. + +No feature line is ever to be deleted from this file. +'b'nested_scopes'u'nested_scopes'b'generators'u'generators'b'division'u'division'b'absolute_import'u'absolute_import'b'with_statement'u'with_statement'b'print_function'u'print_function'b'unicode_literals'u'unicode_literals'b'barry_as_FLUFL'u'barry_as_FLUFL'b'generator_stop'u'generator_stop'b'annotations'u'annotations'b'all_feature_names'u'all_feature_names'b'Return first release in which this feature was recognized. + + This is a 5-tuple, of the same form as sys.version_info. + 'u'Return first release in which this feature was recognized. + + This is a 5-tuple, of the same form as sys.version_info. + 'b'Return release in which this feature will become mandatory. + + This is a 5-tuple, of the same form as sys.version_info, or, if + the feature was dropped, is None. + 'u'Return release in which this feature will become mandatory. + + This is a 5-tuple, of the same form as sys.version_info, or, if + the feature was dropped, is None. + 'b'_Feature'u'_Feature'b'beta'u'beta'b'alpha'u'alpha'b'final'u'__future__'u'urllib.__init__'u'urllib'u'__init__'osunittesttestsupportimport_modulectypesctypes_symbolsneed_symbolskipUnless{!r} is requiredload_testsload_package_testsdirname__file__# skip tests if _ctypes was not builtb'ctypes'u'ctypes'b'{!r} is required'u'{!r} is required'u'ctypes.test.__init__'u'ctypes.test'u'test.__init__'u'test'A pure Python implementation of import.reload_imp_frozen_importlib_bootstrapimportlib._bootstrapimportlib__init__.py_bootstrap.py_setup_frozen_importlib_external_bootstrap_externalimportlib._bootstrap_external_bootstrap_external.py_pack_uint32_unpack_uint32typesCall the invalidate_caches() method on all meta path finders stored in + sys.meta_path (where implemented).finderReturn the loader for the specified module. + + This is a backward-compatible wrapper around find_spec(). + + This function is deprecated in favor of importlib.util.find_spec(). + + Deprecated since Python 3.4. Use importlib.util.find_spec() instead.'Deprecated since Python 3.4. ''Use importlib.util.find_spec() instead.'loader{}.__loader__ is None{}.__loader__ is not set_find_specspecsubmodule_search_locationsspec for {} missing loadernamespace packages do not have loaderspackageImport a module. + + The 'package' argument is required when performing a relative import. It + specifies the package to use as the anchor point from which to resolve the + relative import to an absolute import. + + levelthe 'package' argument is required to perform a relative import for {!r}"the 'package' argument is required to perform a relative ""import for {!r}"character_gcd_import_RELOADINGReload the module and return it. + + The module must have been successfully imported before. + + reload() argument must be a modulemodule {} not in sys.modulesparent_name__path__pkgpathparent {!r} not in sys.modulesspec not found for the module _exec# Bootstrap help ###################################################### Until bootstrapping is complete, DO NOT import any modules that attempt# to import importlib._bootstrap (directly or indirectly). Since this# partially initialised package would be present in sys.modules, those# modules would get an uninitialised copy of the source version, instead# of a fully initialised version (either the frozen one or the one# initialised below if the frozen one is not available).# Just the builtin component, NOT the full Python module# importlib._bootstrap is the built-in import, ensure we don't create# a second copy of the module.# __file__ is not guaranteed to be defined, e.g. if this code gets# frozen by a tool like cx_Freeze.# To simplify imports in test code# Fully bootstrapped at this point, import whatever you like, circular# dependencies and startup overhead minimisation permitting :)# Public API ########################################################## We won't worry about malformed specs (missing attributes).# The module may have replaced itself in sys.modules!b'A pure Python implementation of import.'u'A pure Python implementation of import.'b'__import__'u'__import__'b'import_module'u'import_module'b'invalidate_caches'u'invalidate_caches'b'reload'u'reload'b'importlib._bootstrap'u'importlib._bootstrap'b'importlib'u'importlib'b'__init__.py'u'__init__.py'b'_bootstrap.py'u'_bootstrap.py'b'importlib._bootstrap_external'u'importlib._bootstrap_external'b'_bootstrap_external.py'u'_bootstrap_external.py'b'Call the invalidate_caches() method on all meta path finders stored in + sys.meta_path (where implemented).'u'Call the invalidate_caches() method on all meta path finders stored in + sys.meta_path (where implemented).'b'Return the loader for the specified module. + + This is a backward-compatible wrapper around find_spec(). + + This function is deprecated in favor of importlib.util.find_spec(). + + 'u'Return the loader for the specified module. + + This is a backward-compatible wrapper around find_spec(). + + This function is deprecated in favor of importlib.util.find_spec(). + + 'b'Deprecated since Python 3.4. Use importlib.util.find_spec() instead.'u'Deprecated since Python 3.4. Use importlib.util.find_spec() instead.'b'{}.__loader__ is None'u'{}.__loader__ is None'b'{}.__loader__ is not set'u'{}.__loader__ is not set'b'spec for {} missing loader'u'spec for {} missing loader'b'namespace packages do not have loaders'u'namespace packages do not have loaders'b'Import a module. + + The 'package' argument is required when performing a relative import. It + specifies the package to use as the anchor point from which to resolve the + relative import to an absolute import. + + 'u'Import a module. + + The 'package' argument is required when performing a relative import. It + specifies the package to use as the anchor point from which to resolve the + relative import to an absolute import. + + 'b'the 'package' argument is required to perform a relative import for {!r}'u'the 'package' argument is required to perform a relative import for {!r}'b'Reload the module and return it. + + The module must have been successfully imported before. + + 'u'Reload the module and return it. + + The module must have been successfully imported before. + + 'b'reload() argument must be a module'u'reload() argument must be a module'b'module {} not in sys.modules'u'module {} not in sys.modules'b'parent {!r} not in sys.modules'u'parent {!r} not in sys.modules'b'spec not found for the module 'u'spec not found for the module 'u'importlib.__init__'enumIntEnumHTTPStatusHTTP status codes and reason phrases + + Status codes from the following RFCs are all observed: + + * RFC 7231: Hypertext Transfer Protocol (HTTP/1.1), obsoletes 2616 + * RFC 6585: Additional HTTP Status Codes + * RFC 3229: Delta encoding in HTTP + * RFC 4918: HTTP Extensions for WebDAV, obsoletes 2518 + * RFC 5842: Binding Extensions to WebDAV + * RFC 7238: Permanent Redirect + * RFC 2295: Transparent Content Negotiation in HTTP + * RFC 2774: An HTTP Extension Framework + * RFC 7725: An HTTP Status Code to Report Legal Obstacles + * RFC 7540: Hypertext Transfer Protocol Version 2 (HTTP/2) + clsphrasedescription_value_ContinueRequest received, please continueCONTINUE101Switching ProtocolsSwitching to new protocol; obey Upgrade headerSWITCHING_PROTOCOLS102ProcessingPROCESSING200OKRequest fulfilled, document follows201CreatedDocument created, URL followsCREATED202AcceptedRequest accepted, processing continues off-lineACCEPTED203Non-Authoritative InformationRequest fulfilled from cacheNON_AUTHORITATIVE_INFORMATION204No ContentRequest fulfilled, nothing followsNO_CONTENT205Reset ContentClear input form for further inputRESET_CONTENT206Partial ContentPartial content followsPARTIAL_CONTENT207Multi-StatusMULTI_STATUS208Already ReportedALREADY_REPORTED226IM UsedIM_USED300Multiple ChoicesObject has several resources -- see URI listMULTIPLE_CHOICES301Moved PermanentlyObject moved permanently -- see URI listMOVED_PERMANENTLY302FoundObject moved temporarily -- see URI listFOUND303See OtherObject moved -- see Method and URL listSEE_OTHER304Not ModifiedDocument has not changed since given timeNOT_MODIFIED305Use ProxyYou must use proxy specified in Location to access this resourceUSE_PROXY307Temporary RedirectTEMPORARY_REDIRECTPermanent RedirectPERMANENT_REDIRECT400Bad RequestBad request syntax or unsupported methodBAD_REQUEST401UnauthorizedNo permission -- see authorization schemesUNAUTHORIZED402Payment RequiredNo payment -- see charging schemesPAYMENT_REQUIRED403ForbiddenRequest forbidden -- authorization will not helpFORBIDDEN404Not FoundNothing matches the given URINOT_FOUND405Method Not AllowedSpecified method is invalid for this resourceMETHOD_NOT_ALLOWED406Not AcceptableURI not available in preferred formatNOT_ACCEPTABLE407Proxy Authentication RequiredYou must authenticate with this proxy before proceedingPROXY_AUTHENTICATION_REQUIRED408Request TimeoutRequest timed out; try again laterREQUEST_TIMEOUT409ConflictRequest conflictCONFLICT410GoneURI no longer exists and has been permanently removedGONE411Length RequiredClient must specify Content-LengthLENGTH_REQUIRED412Precondition FailedPrecondition in headers is falsePRECONDITION_FAILED413Request Entity Too LargeEntity is too largeREQUEST_ENTITY_TOO_LARGE414Request-URI Too LongURI is too longREQUEST_URI_TOO_LONG415Unsupported Media TypeEntity body in unsupported formatUNSUPPORTED_MEDIA_TYPE416Requested Range Not SatisfiableCannot satisfy request rangeREQUESTED_RANGE_NOT_SATISFIABLE417Expectation FailedExpect condition could not be satisfiedEXPECTATION_FAILED421Misdirected RequestServer is not able to produce a responseMISDIRECTED_REQUEST422Unprocessable EntityUNPROCESSABLE_ENTITY423LockedLOCKED424Failed DependencyFAILED_DEPENDENCY426Upgrade RequiredUPGRADE_REQUIRED428Precondition RequiredThe origin server requires the request to be conditionalPRECONDITION_REQUIRED429Too Many RequestsThe user has sent too many requests in a given amount of time ("rate limiting")'The user has sent too many requests in ''a given amount of time ("rate limiting")'TOO_MANY_REQUESTS431Request Header Fields Too LargeThe server is unwilling to process the request because its header fields are too large'The server is unwilling to process the request because its header ''fields are too large'REQUEST_HEADER_FIELDS_TOO_LARGE451Unavailable For Legal ReasonsThe server is denying access to the resource as a consequence of a legal demand'The server is denying access to the ''resource as a consequence of a legal demand'UNAVAILABLE_FOR_LEGAL_REASONS500Internal Server ErrorServer got itself in troubleINTERNAL_SERVER_ERROR501Not ImplementedServer does not support this operationNOT_IMPLEMENTED502Bad GatewayInvalid responses from another server/proxyBAD_GATEWAY503Service UnavailableThe server cannot process the request due to a high loadSERVICE_UNAVAILABLE504Gateway TimeoutThe gateway server did not receive a timely responseGATEWAY_TIMEOUT505HTTP Version Not SupportedCannot fulfill requestHTTP_VERSION_NOT_SUPPORTED506Variant Also NegotiatesVARIANT_ALSO_NEGOTIATES507Insufficient StorageINSUFFICIENT_STORAGE508Loop DetectedLOOP_DETECTED510Not ExtendedNOT_EXTENDED511Network Authentication RequiredThe client needs to authenticate to gain network accessNETWORK_AUTHENTICATION_REQUIRED# informational# success# redirection# client error# server errorsb'HTTPStatus'u'HTTPStatus'b'HTTP status codes and reason phrases + + Status codes from the following RFCs are all observed: + + * RFC 7231: Hypertext Transfer Protocol (HTTP/1.1), obsoletes 2616 + * RFC 6585: Additional HTTP Status Codes + * RFC 3229: Delta encoding in HTTP + * RFC 4918: HTTP Extensions for WebDAV, obsoletes 2518 + * RFC 5842: Binding Extensions to WebDAV + * RFC 7238: Permanent Redirect + * RFC 2295: Transparent Content Negotiation in HTTP + * RFC 2774: An HTTP Extension Framework + * RFC 7725: An HTTP Status Code to Report Legal Obstacles + * RFC 7540: Hypertext Transfer Protocol Version 2 (HTTP/2) + 'u'HTTP status codes and reason phrases + + Status codes from the following RFCs are all observed: + + * RFC 7231: Hypertext Transfer Protocol (HTTP/1.1), obsoletes 2616 + * RFC 6585: Additional HTTP Status Codes + * RFC 3229: Delta encoding in HTTP + * RFC 4918: HTTP Extensions for WebDAV, obsoletes 2518 + * RFC 5842: Binding Extensions to WebDAV + * RFC 7238: Permanent Redirect + * RFC 2295: Transparent Content Negotiation in HTTP + * RFC 2774: An HTTP Extension Framework + * RFC 7725: An HTTP Status Code to Report Legal Obstacles + * RFC 7540: Hypertext Transfer Protocol Version 2 (HTTP/2) + 'b'Continue'u'Continue'b'Request received, please continue'u'Request received, please continue'b'Switching Protocols'u'Switching Protocols'b'Switching to new protocol; obey Upgrade header'u'Switching to new protocol; obey Upgrade header'b'Processing'u'Processing'b'OK'u'OK'b'Request fulfilled, document follows'u'Request fulfilled, document follows'b'Created'u'Created'b'Document created, URL follows'u'Document created, URL follows'b'Accepted'u'Accepted'b'Request accepted, processing continues off-line'u'Request accepted, processing continues off-line'b'Non-Authoritative Information'u'Non-Authoritative Information'b'Request fulfilled from cache'u'Request fulfilled from cache'b'No Content'u'No Content'b'Request fulfilled, nothing follows'u'Request fulfilled, nothing follows'b'Reset Content'u'Reset Content'b'Clear input form for further input'u'Clear input form for further input'b'Partial Content'u'Partial Content'b'Partial content follows'u'Partial content follows'b'Multi-Status'u'Multi-Status'b'Already Reported'u'Already Reported'b'IM Used'u'IM Used'b'Multiple Choices'u'Multiple Choices'b'Object has several resources -- see URI list'u'Object has several resources -- see URI list'b'Moved Permanently'u'Moved Permanently'b'Object moved permanently -- see URI list'u'Object moved permanently -- see URI list'b'Found'u'Found'b'Object moved temporarily -- see URI list'u'Object moved temporarily -- see URI list'b'See Other'u'See Other'b'Object moved -- see Method and URL list'u'Object moved -- see Method and URL list'b'Not Modified'u'Not Modified'b'Document has not changed since given time'u'Document has not changed since given time'b'Use Proxy'u'Use Proxy'b'You must use proxy specified in Location to access this resource'u'You must use proxy specified in Location to access this resource'b'Temporary Redirect'u'Temporary Redirect'b'Permanent Redirect'u'Permanent Redirect'b'Bad Request'u'Bad Request'b'Bad request syntax or unsupported method'u'Bad request syntax or unsupported method'b'Unauthorized'u'Unauthorized'b'No permission -- see authorization schemes'u'No permission -- see authorization schemes'b'Payment Required'u'Payment Required'b'No payment -- see charging schemes'u'No payment -- see charging schemes'b'Forbidden'u'Forbidden'b'Request forbidden -- authorization will not help'u'Request forbidden -- authorization will not help'b'Not Found'u'Not Found'b'Nothing matches the given URI'u'Nothing matches the given URI'b'Method Not Allowed'u'Method Not Allowed'b'Specified method is invalid for this resource'u'Specified method is invalid for this resource'b'Not Acceptable'u'Not Acceptable'b'URI not available in preferred format'u'URI not available in preferred format'b'Proxy Authentication Required'u'Proxy Authentication Required'b'You must authenticate with this proxy before proceeding'u'You must authenticate with this proxy before proceeding'b'Request Timeout'u'Request Timeout'b'Request timed out; try again later'u'Request timed out; try again later'b'Conflict'u'Conflict'b'Request conflict'u'Request conflict'b'Gone'u'Gone'b'URI no longer exists and has been permanently removed'u'URI no longer exists and has been permanently removed'b'Length Required'u'Length Required'b'Client must specify Content-Length'u'Client must specify Content-Length'b'Precondition Failed'u'Precondition Failed'b'Precondition in headers is false'u'Precondition in headers is false'b'Request Entity Too Large'u'Request Entity Too Large'b'Entity is too large'u'Entity is too large'b'Request-URI Too Long'u'Request-URI Too Long'b'URI is too long'u'URI is too long'b'Unsupported Media Type'u'Unsupported Media Type'b'Entity body in unsupported format'u'Entity body in unsupported format'b'Requested Range Not Satisfiable'u'Requested Range Not Satisfiable'b'Cannot satisfy request range'u'Cannot satisfy request range'b'Expectation Failed'u'Expectation Failed'b'Expect condition could not be satisfied'u'Expect condition could not be satisfied'b'Misdirected Request'u'Misdirected Request'b'Server is not able to produce a response'u'Server is not able to produce a response'b'Unprocessable Entity'u'Unprocessable Entity'b'Locked'u'Locked'b'Failed Dependency'u'Failed Dependency'b'Upgrade Required'u'Upgrade Required'b'Precondition Required'u'Precondition Required'b'The origin server requires the request to be conditional'u'The origin server requires the request to be conditional'b'Too Many Requests'u'Too Many Requests'b'The user has sent too many requests in a given amount of time ("rate limiting")'u'The user has sent too many requests in a given amount of time ("rate limiting")'b'Request Header Fields Too Large'u'Request Header Fields Too Large'b'The server is unwilling to process the request because its header fields are too large'u'The server is unwilling to process the request because its header fields are too large'b'Unavailable For Legal Reasons'u'Unavailable For Legal Reasons'b'The server is denying access to the resource as a consequence of a legal demand'u'The server is denying access to the resource as a consequence of a legal demand'b'Internal Server Error'u'Internal Server Error'b'Server got itself in trouble'u'Server got itself in trouble'b'Not Implemented'u'Not Implemented'b'Server does not support this operation'u'Server does not support this operation'b'Bad Gateway'u'Bad Gateway'b'Invalid responses from another server/proxy'u'Invalid responses from another server/proxy'b'Service Unavailable'u'Service Unavailable'b'The server cannot process the request due to a high load'u'The server cannot process the request due to a high load'b'Gateway Timeout'u'Gateway Timeout'b'The gateway server did not receive a timely response'u'The gateway server did not receive a timely response'b'HTTP Version Not Supported'u'HTTP Version Not Supported'b'Cannot fulfill request'u'Cannot fulfill request'b'Variant Also Negotiates'u'Variant Also Negotiates'b'Insufficient Storage'u'Insufficient Storage'b'Loop Detected'u'Loop Detected'b'Not Extended'u'Not Extended'b'Network Authentication Required'u'Network Authentication Required'b'The client needs to authenticate to gain network access'u'The client needs to authenticate to gain network access'u'http.__init__'u'http' +Enough Mach-O to make your head spin. + +See the relevant header files in /usr/include/mach-o + +And also Apple's documentation. +1.0__version__b' +Enough Mach-O to make your head spin. + +See the relevant header files in /usr/include/mach-o + +And also Apple's documentation. +'u' +Enough Mach-O to make your head spin. + +See the relevant header files in /usr/include/mach-o + +And also Apple's documentation. +'b'1.0'u'1.0'u'ctypes.macholib.__init__'u'ctypes.macholib'u'macholib.__init__'u'macholib'__default_contextgenexprSUBDEBUG25SUBWARNING__main____mp_main__# Package analogous to 'threading.py' but using processes# multiprocessing/__init__.py# This package is intended to duplicate the functionality (and much of# the API) of threading.py but uses processes instead of threads. A# subpackage 'multiprocessing.dummy' has the same API but is a simple# wrapper for 'threading'.# Copyright (c) 2006-2008, R Oudkerk# Copy stuff from default context# XXX These should not really be documented or public.# Alias for main module -- will be reset by bootstrapping child processesb'_'u'_'b'__main__'u'__main__'b'__mp_main__'u'__mp_main__'u'multiprocessing.__init__'u'multiprocessing'Wrapper functions for Tcl/Tk. + +Tkinter provides classes which allow the display, positioning and +control of widgets. Toplevel widgets are Tk and Toplevel. Other +widgets are Frame, Label, Entry, Text, Canvas, Button, Radiobutton, +Checkbutton, Scale, Listbox, Scrollbar, OptionMenu, Spinbox +LabelFrame and PanedWindow. + +Properties of the widgets are specified with keyword arguments. +Keyword arguments have the same name as the corresponding resource +under Tk. + +Widgets are positioned with one of the geometry managers Place, Pack +or Grid. These managers can be called with methods place, pack, grid +available in every Widget. + +Actions are bound to events by resources (e.g. keyword argument +command) or with the method bind. + +Example (Hello, World): +import tkinter +from tkinter.constants import * +tk = tkinter.Tk() +frame = tkinter.Frame(tk, relief=RIDGE, borderwidth=2) +frame.pack(fill=BOTH,expand=1) +label = tkinter.Label(frame, text="Hello, World") +label.pack(fill=X, expand=1) +button = tkinter.Button(frame,text="Exit",command=tk.destroy) +button.pack(side=BOTTOM) +tk.mainloop() +_tkinterTclErrortkinter.constantswantobjectsTK_VERSIONTkVersionTCL_VERSIONTclVersionREADABLEWRITABLEEXCEPTION([\\{}])_magic_re([\s])ASCII_space_re_joinInternal function._stringifysearch{%s}sub\\\1\n\_flattenseqresitem_cnfmergecnfscnfc_cnfmerge: fallback due to:_splitdicttkcut_minusconvReturn a properly formatted dict built from Tcl list pairs. + + If cut_minus is True, the supposed '-' prefix will be removed from + keys. If conv is specified, it is used to convert values. + + Tcl list is expected to contain an even number of elements. + splitlistTcl list representing a dict is expected to contain an even number of elements'Tcl list representing a dict is expected ''to contain an even number of elements'EventTypeEnumKeyPressKeyKeyReleaseButtonPressButtonButtonReleaseMotionEnterLeaveFocusInFocusOutKeymap12ExposeGraphicsExpose14NoExposeVisibilityCreate17Destroy18Unmap19Map20MapRequest21Reparent22Configure23ConfigureRequest24GravityResizeRequest26Circulate27CirculateRequest28Property29SelectionClearSelectionRequest31Selection32Colormap33ClientMessage34Mapping35VirtualEvent36Activate37Deactivate38MouseWheelEventContainer for the properties of an event. + + Instances of this type are generated if one of the following events occurs: + + KeyPress, KeyRelease - for keyboard events + ButtonPress, ButtonRelease, Motion, Enter, Leave, MouseWheel - for mouse events + Visibility, Unmap, Map, Expose, FocusIn, FocusOut, Circulate, + Colormap, Gravity, Reparent, Property, Destroy, Activate, + Deactivate - for window events. + + If a callback function for one of these events is registered + using bind, bind_all, bind_class, or tag_bind, the callback is + called with an Event as first argument. It will have the + following attributes (in braces are the event types for which + the attribute is valid): + + serial - serial number of event + num - mouse button pressed (ButtonPress, ButtonRelease) + focus - whether the window has the focus (Enter, Leave) + height - height of the exposed window (Configure, Expose) + width - width of the exposed window (Configure, Expose) + keycode - keycode of the pressed key (KeyPress, KeyRelease) + state - state of the event as a number (ButtonPress, ButtonRelease, + Enter, KeyPress, KeyRelease, + Leave, Motion) + state - state as a string (Visibility) + time - when the event occurred + x - x-position of the mouse + y - y-position of the mouse + x_root - x-position of the mouse on the screen + (ButtonPress, ButtonRelease, KeyPress, KeyRelease, Motion) + y_root - y-position of the mouse on the screen + (ButtonPress, ButtonRelease, KeyPress, KeyRelease, Motion) + char - pressed character (KeyPress, KeyRelease) + send_event - see X/Windows documentation + keysym - keysym of the event as a string (KeyPress, KeyRelease) + keysym_num - keysym of the event as a number (KeyPress, KeyRelease) + type - type of the event as a number + widget - widget in which the event occurred + delta - delta of wheel movement (MouseWheel) + ??charsend_eventstateShiftLockControlMod1Mod2Mod3Mod4Mod5Button1Button2Button3Button4Button5modss|deltakeysymkeycodenumfocusyheight<%s event%s> %s=%s_support_default_root_default_rootNoDefaultRootInhibit setting of default root window. + + Call this function to inhibit that the first instance of + Tk is used for windows without an explicit parent window. + _get_default_rootwhatNo master specified and tkinter is configured to not support default root"No master specified and tkinter is ""configured to not support default root"Too early to : no default root windowTk_tkerror_exitInternal function. Calling it will raise the exception SystemExit._varnumVariableClass to define value holders for e.g. buttons. + + Subclasses StringVar, IntVar, DoubleVar, BooleanVar are specializations + that constrain the type of the value returned from get()._tk_tclCommandsmasterConstruct a variable + + MASTER can be given as master widget. + VALUE is an optional value (defaults to "") + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + name must be a stringcreate variable_namePY_VARinitializegetbooleancallinfoexistsUnset the variable in Tcl.globalunsetvardeletecommandReturn the name of the variable in Tcl.Set the variable to VALUE.globalsetvarReturn value of variable.globalgetvar_registerCallWrapperfcbnamecreatecommandtrace_addmodeDefine a trace callback for the variable. + + Mode is one of "read", "write", "unset", or a list or tuple of + such strings. + Callback must be a function which is called when the variable is + read, written or unset. + + Return the name of the callback. + tracevariabletrace_removeDelete the trace callback for a variable. + + Mode is one of "read", "write", "unset" or a list or tuple of + such strings. Must be same as were specified in trace_add(). + cbname is the name of the callback returned from trace_add(). + mcatrace_infoReturn all trace callback information.trace_variableDefine a trace callback for the variable. + + MODE is one of "r", "w", "u" for read, write, undefine. + CALLBACK must be a function which is called when + the variable is read, written or undefined. + + Return the name of the callback. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_add() instead. + trace_vdeleteDelete the trace callback for a variable. + + MODE is one of "r", "w", "u" for read, write, undefine. + CBNAME is the name of the callback returned from trace_variable or trace. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_remove() instead. + vdeletetrace_vinfoReturn all trace callback information. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_info() instead. + vinfoStringVarValue holder for strings variables.Construct a string variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to "") + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + Return value of variable as string.IntVarValue holder for integer variables.Construct an integer variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to 0) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + Return the value of the variable as an integer.getintgetdoubleDoubleVarValue holder for float variables.0.0Construct a float variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to 0.0) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + Return the value of the variable as a float.BooleanVarValue holder for boolean variables.Construct a boolean variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to False) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + Return the value of the variable as a bool.invalid literal for getboolean()mainloopRun the main loop of Tcl.run the main loopConvert Tcl object to True or False.use getboolean()MiscInternal class. + + Base class which defines methods common for interior widgets._last_child_idsdestroyInternal function. + + Delete all Tcl commands created for + this widget in the Tcl interpreter.Internal function. + + Delete the Tcl command provided in NAME.tk_strictMotifbooleanSet Tcl internal variable, whether the look and feel + should adhere to Motif. + + A parameter of 1 means adhere to Motif (e.g. no color + change if mouse passes over slider). + Returns the set value.tk_bisqueChange the color scheme to light brown as used in Tk 3.6 and before.tk_setPalettekwSet a new color scheme for all widget elements. + + A single color as argument will cause that all colors of Tk + widget elements are derived from this. + Alternatively several keyword parameters and its associated + colors can be given. The following keywords are valid: + activeBackground, foreground, selectColor, + activeForeground, highlightBackground, selectBackground, + background, highlightColor, selectForeground, + disabledForeground, insertBackground, troughColor.wait_variableWait until the variable is modified. + + A parameter of type IntVar, StringVar, DoubleVar or + BooleanVar must be given.tkwaitwaitvarwait_windowwindowWait until a WIDGET is destroyed. + + If no parameter is given self is used._wwait_visibilityWait until the visibility of a WIDGET changes + (e.g. it appears). + + If no parameter is given self is used.visibilitysetvarSet Tcl variable NAME to VALUE.getvarReturn value of Tcl variable NAME.Return a boolean value for Tcl boolean values true and false given as parameter.focus_setDirect input focus to this widget. + + If the application currently does not have the focus + this widget will get the focus if the application gets + the focus through the window manager.focus_forceDirect input focus to this widget even if the + application does not have the focus. Use with + caution!-forcefocus_getReturn the widget which has currently the focus in the + application. + + Use focus_displayof to allow working with several + displays. Return None if application does not have + the focus.none_nametowidgetfocus_displayofReturn the widget which has currently the focus on the + display where this widget is located. + + Return None if the application does not have the focus.-displayoffocus_lastforReturn the widget which would have the focus if top level + for this widget gets the focus from the window manager.-lastfortk_focusFollowsMouseThe widget under mouse will get automatically focus. Can not + be disabled easily.tk_focusNextReturn the next widget in the focus order which follows + widget which has currently the focus. + + The focus order first goes to the next child, then to + the children of the child recursively and then to the + next sibling which is higher in the stacking order. A + widget is omitted if it has the takefocus resource set + to 0.tk_focusPrevReturn previous widget in the focus order. See tk_focusNext for details.aftermsfuncCall function once after given time. + + MS specifies the time in milliseconds. FUNC gives the + function which shall be called. Additional parameters + are given as parameters to the function call. Return + identifier to cancel scheduling with after_cancel.callitafter_idleCall FUNC once if the Tcl main loop has no event to + process. + + Return an identifier to cancel the scheduling with + after_cancel.idleafter_cancelCancel scheduling of function identified with ID. + + Identifier returned by after or after_idle must be + given as first parameter. + id must be a valid identifier returned from after or after_idle'id must be a valid identifier returned from ''after or after_idle'cancelbelldisplayofRing a display's bell._displayofclipboard_getRetrieve data from the clipboard on window's display. + + The window keyword defaults to the root window of the Tkinter + application. + + The type keyword specifies the form in which the data is + to be returned and should be an atom name such as STRING + or FILE_NAME. Type defaults to STRING, except on X11, where the default + is to try UTF8_STRING and fall back to STRING. + + This command is equivalent to: + + selection_get(CLIPBOARD) + _windowingsystemx11UTF8_STRINGclipboard_optionsclipboard_clearClear the data in the Tk clipboard. + + A widget specified for the optional displayof keyword + argument specifies the target display.clipboard_appendstringAppend STRING to the Tk clipboard. + + A widget specified at the optional displayof keyword + argument specifies the target display. The clipboard + can be retrieved with selection_get.--grab_currentReturn widget which has currently the grab in this application + or None.grabcurrentgrab_releaseRelease grab for this widget if currently set.grab_setSet grab for this widget. + + A grab directs all events to this and descendant + widgets in the application.grab_set_globalSet global grab for this widget. + + A global grab directs all events to this and + descendant widgets on the display. Use with caution - + other applications do not get events anymore.-globalgrab_statusReturn None, "local" or "global" if this widget has + no, a local or a global grab.statusoption_addprioritySet a VALUE (second parameter) for an option + PATTERN (first parameter). + + An optional third parameter gives the numeric priority + (defaults to 80).optionoption_clearClear the option database. + + It will be reloaded if option_add is called.option_getclassNameReturn the value for an option NAME for this widget + with CLASSNAME. + + Values with higher priority override lower values.option_readfilefileNameRead file FILENAME into the option database. + + An optional second parameter gives the numeric + priority.readfileselection_clearClear the current X selection.selectionselection_getReturn the contents of the current X selection. + + A keyword parameter selection specifies the name of + the selection and defaults to PRIMARY. A keyword + parameter displayof specifies a widget on the display + to use. A keyword parameter type specifies the form of data to be + fetched, defaulting to STRING except on X11, where UTF8_STRING is tried + before STRING.selection_handlecommandSpecify a function COMMAND to call if the X + selection owned by this widget is queried by another + application. + + This function must return the contents of the + selection. The function will be called with the + arguments OFFSET and LENGTH which allows the chunking + of very long selections. The following keyword + parameters can be provided: + selection - name of the selection (default PRIMARY), + type - type of the selection (e.g. STRING, FILE_NAME).handleselection_ownBecome owner of X selection. + + A keyword parameter selection specifies the name of + the selection (default PRIMARY).ownselection_own_getReturn owner of X selection. + + The following keyword parameter can + be provided: + selection - name of the selection (default PRIMARY), + type - type of the selection (e.g. STRING, FILE_NAME).interpcmdSend Tcl command CMD to different interpreter INTERP to be executed.belowThisLower this widget in the stacking order.tkraiseaboveThisRaise this widget in the stacking order.raiseliftwinfo_atomReturn integer which represents atom NAME.winfoatomwinfo_atomnameReturn name of atom with identifier ID.atomnamewinfo_cellsReturn number of cells in the colormap for this widget.cellswinfo_childrenReturn a list of all widgets which are children of this widget.childchildrenwinfo_classReturn window class name of this widget.classwinfo_colormapfullReturn True if at the last color request the colormap was full.colormapfullwinfo_containingrootXrootYReturn the widget which is at the root coordinates ROOTX, ROOTY.containingwinfo_depthReturn the number of bits per pixel.depthwinfo_existsReturn true if this widget exists.winfo_fpixelsnumberReturn the number of pixels for the given distance NUMBER + (e.g. "3c") as float.fpixelswinfo_geometryReturn geometry string for this widget in the form "widthxheight+X+Y".geometrywinfo_heightReturn height of this widget.winfo_idReturn identifier ID for this widget.winfo_interpsReturn the name of all Tcl interpreters for this display.interpswinfo_ismappedReturn true if this widget is mapped.ismappedwinfo_managerReturn the window manager name for this widget.managerwinfo_nameReturn the name of this widget.winfo_parentReturn the name of the parent of this widget.winfo_pathnameReturn the pathname of the widget given by ID.pathnamewinfo_pixelsRounded integer value of winfo_fpixels.pixelswinfo_pointerxReturn the x coordinate of the pointer on the root window.pointerxwinfo_pointerxyReturn a tuple of x and y coordinates of the pointer on the root window._getintspointerxywinfo_pointeryReturn the y coordinate of the pointer on the root window.pointerywinfo_reqheightReturn requested height of this widget.reqheightwinfo_reqwidthReturn requested width of this widget.reqwidthwinfo_rgbcolorReturn a tuple of integer RGB values in range(65536) for color in this widget.rgbwinfo_rootxReturn x coordinate of upper left corner of this widget on the + root window.rootxwinfo_rootyReturn y coordinate of upper left corner of this widget on the + root window.rootywinfo_screenReturn the screen name of this widget.screenwinfo_screencellsReturn the number of the cells in the colormap of the screen + of this widget.screencellswinfo_screendepthReturn the number of bits per pixel of the root window of the + screen of this widget.screendepthwinfo_screenheightReturn the number of pixels of the height of the screen of this widget + in pixel.screenheightwinfo_screenmmheightReturn the number of pixels of the height of the screen of + this widget in mm.screenmmheightwinfo_screenmmwidthReturn the number of pixels of the width of the screen of + this widget in mm.screenmmwidthwinfo_screenvisualReturn one of the strings directcolor, grayscale, pseudocolor, + staticcolor, staticgray, or truecolor for the default + colormodel of this screen.screenvisualwinfo_screenwidthReturn the number of pixels of the width of the screen of + this widget in pixel.screenwidthwinfo_serverReturn information of the X-Server of the screen of this widget in + the form "XmajorRminor vendor vendorVersion".serverwinfo_toplevelReturn the toplevel widget of this widget.toplevelwinfo_viewableReturn true if the widget and all its higher ancestors are mapped.viewablewinfo_visualReturn one of the strings directcolor, grayscale, pseudocolor, + staticcolor, staticgray, or truecolor for the + colormodel of this widget.visualwinfo_visualidReturn the X identifier for the visual for this widget.visualidwinfo_visualsavailableincludeidsReturn a list of all visuals available for the screen + of this widget. + + Each item in the list consists of a visual name (see winfo_visual), a + depth and if includeids is true is given also the X identifier.visualsavailable__winfo_parseitem__winfo_getintwinfo_vrootheightReturn the height of the virtual root window associated with this + widget in pixels. If there is no virtual root window return the + height of the screen.vrootheightwinfo_vrootwidthReturn the width of the virtual root window associated with this + widget in pixel. If there is no virtual root window return the + width of the screen.vrootwidthwinfo_vrootxReturn the x offset of the virtual root relative to the root + window of the screen of this widget.vrootxwinfo_vrootyReturn the y offset of the virtual root relative to the root + window of the screen of this widget.vrootywinfo_widthReturn the width of this widget.winfo_xReturn the x coordinate of the upper left corner of this widget + in the parent.winfo_yReturn the y coordinate of the upper left corner of this widget + in the parent.Enter event loop until all pending events have been processed by Tcl.update_idletasksEnter event loop until all idle callbacks have been called. This + will update the display of windows but not process events caused by + the user.idletasksbindtagstagListSet or get the list of bindtags for this widget. + + With no argument return the list of all bindtags associated with + this widget. With a list of strings as argument the bindtags are + set to this list. The bindtags determine in which order events are + processed (see bind)._bindneedcleanup_substitutefuncid%sif {"[%s %s]" == "break"} break ++_subst_format_strbindBind to this widget at event SEQUENCE a call to function FUNC. + + SEQUENCE is a string of concatenated event + patterns. An event pattern is of the form + where MODIFIER is one + of Control, Mod2, M2, Shift, Mod3, M3, Lock, Mod4, M4, + Button1, B1, Mod5, M5 Button2, B2, Meta, M, Button3, + B3, Alt, Button4, B4, Double, Button5, B5 Triple, + Mod1, M1. TYPE is one of Activate, Enter, Map, + ButtonPress, Button, Expose, Motion, ButtonRelease + FocusIn, MouseWheel, Circulate, FocusOut, Property, + Colormap, Gravity Reparent, Configure, KeyPress, Key, + Unmap, Deactivate, KeyRelease Visibility, Destroy, + Leave and DETAIL is the button number for ButtonPress, + ButtonRelease and DETAIL is the Keysym for KeyPress and + KeyRelease. Examples are + for pressing Control and mouse button 1 or + for pressing A and the Alt key (KeyPress can be omitted). + An event pattern can also be a virtual event of the form + <> where AString can be arbitrary. This + event can be generated by event_generate. + If events are concatenated they must appear shortly + after each other. + + FUNC will be called if the event sequence occurs with an + instance of Event as argument. If the return value of FUNC is + "break" no further bound function is invoked. + + An additional boolean parameter ADD specifies whether FUNC will + be called additionally to the other bound function or whether + it will replace the previous function. + + Bind will return an identifier to allow deletion of the bound function with + unbind without memory leak. + + If FUNC or SEQUENCE is omitted the bound function or list + of bound events are returned.unbindUnbind for this widget for event SEQUENCE the + function identified with FUNCID.bind_allBind to all widgets at an event SEQUENCE a call to function FUNC. + An additional boolean parameter ADD specifies whether FUNC will + be called additionally to the other bound function or whether + it will replace the previous function. See bind for the return value.unbind_allUnbind for all widgets for event SEQUENCE all functions.bind_classBind to widgets with bindtag CLASSNAME at event + SEQUENCE a call of function FUNC. An additional + boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or + whether it will replace the previous function. See bind for + the return value.unbind_classUnbind for all widgets with bindtag CLASSNAME for event SEQUENCE + all functions.Call the mainloop of Tk.quitQuit the Tcl interpreter. All widgets will be destroyed._getdoubles_getboolean_windowingsystem_cachedwindowingsystemwsnvnametowidgetReturn the Tkinter instance of a widget identified by + its Tcl name NAME.substReturn a newly created Tcl function. If this + function is called, the Python function FUNC will + be executed. An optional function SUBST can + be given which will be executed before FUNC.register%#%b%f%h%k%s%t%w%x%y%A%E%K%N%W%T%X%Y%D_subst_formatgetint_eventTk changed behavior in 8.4.2, returning "??" rather more often.nsignhAEKNWTXYDtimekeysym_numwidgetx_rooty_root_report_exceptionvaltbreport_callback_exception_getconfigureCall Tcl configure command and return the result as a dict._getconfigure1_configureconfigureConfigure resources of a widget. + + The values for resources are specified as keyword + arguments. To get an overview about + the allowed keyword arguments call the method keys. + configcgetReturn the resource value for a KEY given as string.Return a list of all resource names of this widget.Return the window path name of this widget.<%s.%s object %s>_noarg_pack_propagateflagSet or get the status for propagation of geometry information. + + A boolean argument specifies whether the geometry information + of the slaves will determine the size of this widget. If no argument + is given the current setting will be returned. + packpropagatepack_slavesReturn a list of all slaves of this widget + in its packing order.slavesplace_slavesplacegrid_anchoranchorThe anchor value controls how to place the grid within the + master when no row/column has any weight. + + The default anchor is nw.gridgrid_bboxcolumnrowcol2row2Return a tuple of integer coordinates for the bounding + box of this widget controlled by the geometry manager grid. + + If COLUMN, ROW is given the bounding box applies from + the cell with row and column 0 to the specified + cell. If COL2 and ROW2 are given the bounding box + starts at that cell. + + The returned integers specify the offset of the upper left + corner in the master widget and the width and height. + bbox_gridconvvalueTcl_Objsvalue_grid_configuregrid_columnconfigureConfigure column INDEX of a grid. + + Valid resources are minsize (minimum size of the column), + weight (how much does additional space propagate to this column) + and pad (how much space to let additionally).columnconfiguregrid_locationReturn a tuple of column and row which identify the cell + at which the pixel at position X and Y inside the master + widget is located.locationgrid_propagateSet or get the status for propagation of geometry information. + + A boolean argument specifies whether the geometry information + of the slaves will determine the size of this widget. If no argument + is given, the current setting will be returned. + grid_rowconfigureConfigure row INDEX of a grid. + + Valid resources are minsize (minimum size of the row), + weight (how much does additional space propagate to this row) + and pad (how much space to let additionally).rowconfiguregrid_sizeReturn a tuple of the number of column and rows in the grid.sizegrid_slaves-row-columnevent_addvirtualsequencesBind a virtual event VIRTUAL (of the form <>) + to an event SEQUENCE such that the virtual event is triggered + whenever SEQUENCE occurs.event_deleteUnbind a virtual event VIRTUAL from SEQUENCE.deleteevent_generateGenerate an event SEQUENCE. Additional + keyword arguments specify parameter of the event + (e.g. x, y, rootx, rooty).generate-%sevent_infoReturn a list of all virtual events or the information + about the SEQUENCE bound to the virtual event VIRTUAL.image_namesReturn a list of all existing image names.imagenamesimage_typesReturn a list of all available image types (e.g. photo bitmap).Internal class. Stores function to call when some user + defined Tcl function is called e.g. after an event occurred.Store FUNC, SUBST and WIDGET as members.Apply first function SUBST to arguments, than FUNC.XViewMix-in class for querying and changing the horizontal position + of a widget's window.xviewQuery and change the horizontal position of the view.xview_movetofractionAdjusts the view in the window so that FRACTION of the + total width of the canvas is off-screen to the left.movetoxview_scrollShift the x-view according to NUMBER which is measured in "units" + or "pages" (WHAT).scrollYViewMix-in class for querying and changing the vertical position + of a widget's window.yviewQuery and change the vertical position of the view.yview_movetoAdjusts the view in the window so that FRACTION of the + total height of the canvas is off-screen to the top.yview_scrollShift the y-view according to NUMBER which is measured in + "units" or "pages" (WHAT).WmProvides functions for the communication with the window manager.wm_aspectminNumerminDenommaxNumermaxDenomInstruct the window manager to set the aspect ratio (width/height) + of this widget to be between MINNUMER/MINDENOM and MAXNUMER/MAXDENOM. Return a tuple + of the actual values if no argument is given.wmaspectwm_attributesThis subcommand returns or sets platform specific attributes + + The first form returns a list of the platform specific flags and + their values. The second form returns the value for the specific + option. The third form sets one or more of the values. The values + are as follows: + + On Windows, -disabled gets or sets whether the window is in a + disabled state. -toolwindow gets or sets the style of the window + to toolwindow (as defined in the MSDN). -topmost gets or sets + whether this is a topmost window (displays above all other + windows). + + On Macintosh, XXXXX + + On Unix, there are currently no special attribute values. + attributeswm_clientStore NAME in WM_CLIENT_MACHINE property of this widget. Return + current value.clientwm_colormapwindowswlistStore list of window names (WLIST) into WM_COLORMAPWINDOWS property + of this widget. This list contains windows whose colormaps differ from their + parents. Return current list of widgets if WLIST is empty.colormapwindowswm_commandStore VALUE in WM_COMMAND property. It is the command + which shall be used to invoke the application. Return current + command if VALUE is None.wm_deiconifyDeiconify this widget. If it was never mapped it will not be mapped. + On Windows it will raise this widget and give it the focus.deiconifywm_focusmodelmodelSet focus model to MODEL. "active" means that this widget will claim + the focus itself, "passive" means that the window manager shall give + the focus. Return current focus model if MODEL is None.focusmodelwm_forgetThe window will be unmapped from the screen and will no longer + be managed by wm. toplevel windows will be treated like frame + windows once they are no longer managed by wm, however, the menu + option configuration will be remembered and the menus will return + once the widget is managed again.forgetwm_frameReturn identifier for decorative frame of this widget if present.wm_geometrynewGeometrySet geometry to NEWGEOMETRY of the form =widthxheight+x+y. Return + current value if None is given.wm_gridbaseWidthbaseHeightwidthIncheightIncInstruct the window manager that this widget shall only be + resized on grid boundaries. WIDTHINC and HEIGHTINC are the width and + height of a grid unit in pixels. BASEWIDTH and BASEHEIGHT are the + number of grid units requested in Tk_GeometryRequest.wm_grouppathNameSet the group leader widgets for related widgets to PATHNAME. Return + the group leader of this widget if None is given.groupwm_iconbitmapbitmapSet bitmap for the iconified widget to BITMAP. Return + the bitmap if None is given. + + Under Windows, the DEFAULT parameter can be used to set the icon + for the widget and any descendents that don't have an icon set + explicitly. DEFAULT can be the relative path to a .ico file + (example: root.iconbitmap(default='myicon.ico') ). See Tk + documentation for more information.iconbitmap-defaultwm_iconifyDisplay widget as icon.iconifywm_iconmaskSet mask for the icon bitmap of this widget. Return the + mask if None is given.iconmaskwm_iconnamenewNameSet the name of the icon for this widget. Return the name if + None is given.iconnamewm_iconphotoSets the titlebar icon for this window based on the named photo + images passed through args. If default is True, this is applied to + all future created toplevels as well. + + The data in the images is taken as a snapshot at the time of + invocation. If the images are later changed, this is not reflected + to the titlebar icons. Multiple images are accepted to allow + different images sizes to be provided. The window manager may scale + provided icons to an appropriate size. + + On Windows, the images are packed into a Windows icon structure. + This will override an icon specified to wm_iconbitmap, and vice + versa. + + On X, the images are arranged into the _NET_WM_ICON X property, + which most modern window managers support. An icon specified by + wm_iconbitmap may exist simultaneously. + + On Macintosh, this currently does nothing.iconphotowm_iconpositionSet the position of the icon of this widget to X and Y. Return + a tuple of the current values of X and X if None is given.iconpositionwm_iconwindowSet widget PATHNAME to be displayed instead of icon. Return the current + value if None is given.iconwindowwm_manageThe widget specified will become a stand alone top-level window. + The window will be decorated with the window managers title bar, + etc.managewm_maxsizeSet max WIDTH and HEIGHT for this widget. If the window is gridded + the values are given in grid units. Return the current values if None + is given.wm_minsizeSet min WIDTH and HEIGHT for this widget. If the window is gridded + the values are given in grid units. Return the current values if None + is given.minsizewm_overrideredirectInstruct the window manager to ignore this widget + if BOOLEAN is given with 1. Return the current value if None + is given.overrideredirectwm_positionfromwhoInstruct the window manager that the position of this widget shall + be defined by the user if WHO is "user", and by its own policy if WHO is + "program".positionfromwm_protocolBind function FUNC to command NAME for this widget. + Return the function bound to NAME if None is given. NAME could be + e.g. "WM_SAVE_YOURSELF" or "WM_DELETE_WINDOW".protocolwm_resizableInstruct the window manager whether this width can be resized + in WIDTH or HEIGHT. Both values are boolean values.resizablewm_sizefromInstruct the window manager that the size of this widget shall + be defined by the user if WHO is "user", and by its own policy if WHO is + "program".sizefromwm_statenewstateQuery or set the state of this widget as one of normal, icon, + iconic (see wm_iconwindow), withdrawn, or zoomed (Windows only).wm_titleSet the title of this widget.wm_transientInstruct the window manager that this widget is transient + with regard to widget MASTER.transientwm_withdrawWithdraw this widget from the screen such that it is unmapped + and forgotten by the window manager. Re-draw it with wm_deiconify.withdrawToplevel widget of Tk which represents mostly the main window + of an application. It has an associated Tcl interpreter.screenNamebaseNameuseTksyncuseReturn a new Toplevel widget on screen SCREENNAME. A new Tcl interpreter will + be created. BASENAME will be used for the identification of the profile file (see + readprofile). + It is constructed from sys.argv[0] without extensions if None is given. CLASSNAME + is the name of the widget class._tkloadedbasenamesplitextext.py.pyccreate_loadtkreadprofileloadtktk_versiontk.h version (%s) doesn't match libtk.a version (%s)tcl_versiontcl.h version (%s) doesn't match libtcl.a version (%s)tkerrorWM_DELETE_WINDOWDestroy this and all descendants widgets. This will + end the application of this Tcl interpreter.Internal function. It reads BASENAME.tcl and CLASSNAME.tcl into + the Tcl Interpreter and calls exec on the contents of BASENAME.py and + CLASSNAME.py if such a file exists in the home directory.HOMEenvironhomecurdir.%s.tclclass_tcl.%s.pyclass_pybase_tclbase_pyfrom tkinter import *isfileReport callback exception on sys.stderr. + + Applications may want to override this internal function, and + should when sys.stderr is None.tracebackException in Tkinter callbacklast_typelast_valuelast_tracebackprint_exception__getattr__attrDelegate attribute access to the interpreter objectTclPackGeometry manager Pack. + + Base class to use the methods pack_* in every widget.pack_configurePack a widget in the parent widget. Use as options: + after=widget - pack it after you have packed widget + anchor=NSEW (or subset) - position widget according to + given direction + before=widget - pack it before you will pack widget + expand=bool - expand widget if parent size grows + fill=NONE or X or Y or BOTH - fill widget if widget grows + in=master - use master to contain this widget + in_=master - see 'in' option description + ipadx=amount - add internal padding in x direction + ipady=amount - add internal padding in y direction + padx=amount - add padding in x direction + pady=amount - add padding in y direction + side=TOP or BOTTOM or LEFT or RIGHT - where to add this widget. + pack_forgetUnmap this widget and do not use it for the packing order.pack_infoReturn information about the packing options + for this widget.dinPlaceGeometry manager Place. + + Base class to use the methods place_* in every widget.place_configurePlace a widget in the parent widget. Use as options: + in=master - master relative to which the widget is placed + in_=master - see 'in' option description + x=amount - locate anchor of this widget at position x of master + y=amount - locate anchor of this widget at position y of master + relx=amount - locate anchor of this widget between 0.0 and 1.0 + relative to width of master (1.0 is right edge) + rely=amount - locate anchor of this widget between 0.0 and 1.0 + relative to height of master (1.0 is bottom edge) + anchor=NSEW (or subset) - position anchor according to given direction + width=amount - width of this widget in pixel + height=amount - height of this widget in pixel + relwidth=amount - width of this widget between 0.0 and 1.0 + relative to width of master (1.0 is the same width + as the master) + relheight=amount - height of this widget between 0.0 and 1.0 + relative to height of master (1.0 is the same + height as the master) + bordermode="inside" or "outside" - whether to take border width of + master widget into account + place_forgetUnmap this widget.place_infoReturn information about the placing options + for this widget.GridGeometry manager Grid. + + Base class to use the methods grid_* in every widget.grid_configurePosition a widget in the parent widget in a grid. Use as options: + column=number - use cell identified with given column (starting with 0) + columnspan=number - this widget will span several columns + in=master - use master to contain this widget + in_=master - see 'in' option description + ipadx=amount - add internal padding in x direction + ipady=amount - add internal padding in y direction + padx=amount - add padding in x direction + pady=amount - add padding in y direction + row=number - use cell identified with given row (starting with 0) + rowspan=number - this widget will span several rows + sticky=NSEW - if cell is larger on which sides will this + widget stick to the cell boundary + grid_forgetgrid_removeUnmap this widget but remember the grid options.grid_infoReturn information about the options + for positioning this widget in a grid.BaseWidgetInternal class.Internal function. Sets up information about children.!%s!%s%dwidgetNameConstruct a widget with the parent widget MASTER, a name WIDGETNAME + and appropriate options.classesDestroy this and all descendants widgets._doWidgetInternal class. + + Base class for a widget which can be positioned with the geometry managers + Pack, Place or Grid.ToplevelToplevel widget, e.g. for dialogs.Construct a toplevel widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, class, + colormap, container, cursor, height, highlightbackground, + highlightcolor, highlightthickness, menu, relief, screen, takefocus, + use, visual, width.wmkeyclass_colormapoptButton widget.Construct a button widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, activeforeground, anchor, + background, bitmap, borderwidth, cursor, + disabledforeground, font, foreground + highlightbackground, highlightcolor, + highlightthickness, image, justify, + padx, pady, relief, repeatdelay, + repeatinterval, takefocus, text, + textvariable, underline, wraplength + + WIDGET-SPECIFIC OPTIONS + + command, compound, default, height, + overrelief, state, width + buttonflashFlash the button. + + This is accomplished by redisplaying + the button several times, alternating between active and + normal colors. At the end of the flash the button is left + in the same normal/active state as when the command was + invoked. This command is ignored if the button's state is + disabled. + invokeInvoke the command associated with the button. + + The return value is the return value from the command, + or an empty string if there is no command associated with + the button. This command is ignored if the button's state + is disabled. + CanvasCanvas widget to display graphical elements like lines or text.Construct a canvas widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, closeenough, + confine, cursor, height, highlightbackground, highlightcolor, + highlightthickness, insertbackground, insertborderwidth, + insertofftime, insertontime, insertwidth, offset, relief, + scrollregion, selectbackground, selectborderwidth, selectforeground, + state, takefocus, width, xscrollcommand, xscrollincrement, + yscrollcommand, yscrollincrement.canvasaddtagaddtag_abovenewtagtagOrIdAdd tag NEWTAG to all items above TAGORID.aboveaddtag_allAdd tag NEWTAG to all items.addtag_belowAdd tag NEWTAG to all items below TAGORID.belowaddtag_closesthaloAdd tag NEWTAG to item which is closest to pixel at X, Y. + If several match take the top-most. + All items closer than HALO are considered overlapping (all are + closests). If START is specified the next below this tag is taken.closestaddtag_enclosedx1y1x2y2Add tag NEWTAG to all items in the rectangle defined + by X1,Y1,X2,Y2.enclosedaddtag_overlappingAdd tag NEWTAG to all items which overlap the rectangle + defined by X1,Y1,X2,Y2.overlappingaddtag_withtagAdd tag NEWTAG to all items with TAGORID.withtagReturn a tuple of X1,Y1,X2,Y2 coordinates for a rectangle + which encloses all items with tags specified as arguments.tag_unbindUnbind for all items with TAGORID for event SEQUENCE the + function identified with FUNCID.tag_bindBind to all items with TAGORID at event SEQUENCE a call to function FUNC. + + An additional boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or whether it will + replace the previous function. See bind for the return value.canvasxscreenxgridspacingReturn the canvas x coordinate of pixel position SCREENX rounded + to nearest multiple of GRIDSPACING units.canvasyscreenyReturn the canvas y coordinate of pixel position SCREENY rounded + to nearest multiple of GRIDSPACING units.coordsReturn a list of coordinates for the item given in ARGS._createitemTypecreate_arcCreate arc shaped region with coordinates x1,y1,x2,y2.arccreate_bitmapCreate bitmap with coordinates x1,y1.create_imageCreate image item with coordinates x1,y1.create_lineCreate line with coordinates x1,y1,...,xn,yn.linecreate_ovalCreate oval with coordinates x1,y1,x2,y2.ovalcreate_polygonCreate polygon with coordinates x1,y1,...,xn,yn.polygoncreate_rectangleCreate rectangle with coordinates x1,y1,x2,y2.rectanglecreate_textCreate text with coordinates x1,y1.create_windowCreate window with coordinates x1,y1,x2,y2.dcharsDelete characters of text items identified by tag or id in ARGS (possibly + several times) from FIRST to LAST character (including).Delete items identified by all tag or ids contained in ARGS.dtagDelete tag or id given as last arguments in ARGS from items + identified by first argument in ARGS.find_aboveReturn items above TAGORID.find_allReturn all items.find_belowReturn all items below TAGORID.find_closestReturn item which is closest to pixel at X, Y. + If several match take the top-most. + All items closer than HALO are considered overlapping (all are + closest). If START is specified the next below this tag is taken.find_enclosedReturn all items in rectangle defined + by X1,Y1,X2,Y2.find_overlappingReturn all items which overlap the rectangle + defined by X1,Y1,X2,Y2.find_withtagReturn all items with TAGORID.Set focus to the first item specified in ARGS.gettagsReturn tags associated with the first item specified in ARGS.icursorSet cursor at position POS in the item identified by TAGORID. + In ARGS TAGORID must be first.Return position of cursor as integer in item specified in ARGS.Insert TEXT in item TAGORID at position POS. ARGS must + be TAGORID POS TEXT.itemcgetReturn the resource value for an OPTION for item TAGORID.itemconfigureConfigure resources of an item TAGORID. + + The values for resources are specified as keyword + arguments. To get an overview about + the allowed keyword arguments call the method without arguments. + itemconfigtag_lowerLower an item TAGORID given in ARGS + (optional below another item).moveMove an item TAGORID given in ARGS.Move the items given by TAGORID in the canvas coordinate + space so that the first coordinate pair of the bottommost + item with tag TAGORID is located at position (X,Y). + X and Y may be the empty string, in which case the + corresponding coordinate will be unchanged. All items matching + TAGORID remain in the same positions relative to each other.postscriptPrint the contents of the canvas to a postscript + file. Valid options: colormap, colormode, file, fontmap, + height, pageanchor, pageheight, pagewidth, pagex, pagey, + rotate, width, x, y.tag_raiseRaise an item TAGORID given in ARGS + (optional above another item).scaleScale item TAGORID with XORIGIN, YORIGIN, XSCALE, YSCALE.scan_markRemember the current X, Y coordinates.scanmarkscan_dragtogainAdjust the view of the canvas to GAIN times the + difference between X and Y and the coordinates given in + scan_mark.dragtoselect_adjustAdjust the end of the selection near the cursor of an item TAGORID to index.adjustselect_clearClear the selection if it is in this widget.select_fromSet the fixed end of a selection in item TAGORID to INDEX.fromselect_itemReturn the item which has the selection.select_toSet the variable end of a selection in item TAGORID to INDEX.toReturn the type of the item TAGORID.CheckbuttonCheckbutton widget which is either in on- or off-state.Construct a checkbutton widget with the parent MASTER. + + Valid resource names: activebackground, activeforeground, anchor, + background, bd, bg, bitmap, borderwidth, command, cursor, + disabledforeground, fg, font, foreground, height, + highlightbackground, highlightcolor, highlightthickness, image, + indicatoron, justify, offvalue, onvalue, padx, pady, relief, + selectcolor, selectimage, state, takefocus, text, textvariable, + underline, variable, width, wraplength.checkbuttondeselectPut the button in off-state.Flash the button.Toggle the button and invoke a command if given as resource.Put the button in on-state.toggleToggle the button.EntryEntry widget which allows displaying simple text.Construct an entry widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, cursor, + exportselection, fg, font, foreground, highlightbackground, + highlightcolor, highlightthickness, insertbackground, + insertborderwidth, insertofftime, insertontime, insertwidth, + invalidcommand, invcmd, justify, relief, selectbackground, + selectborderwidth, selectforeground, show, state, takefocus, + textvariable, validate, validatecommand, vcmd, width, + xscrollcommand.entryfirstDelete text from FIRST to LAST (not included).Return the text.Insert cursor at INDEX.Return position of cursor.Insert STRING at INDEX.Adjust the view of the canvas to 10 times the + difference between X and Y and the coordinates given in + scan_mark.selection_adjustAdjust the end of the selection near the cursor to INDEX.selection_fromSet the fixed end of a selection to INDEX.selection_presentReturn True if there are characters selected in the entry, False + otherwise.presentselect_presentselection_rangeSet the selection from START to END (not included).select_rangeselection_toSet the variable end of a selection to INDEX.FrameFrame widget which may contain other widgets and can have a 3D border.Construct a frame widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, class, + colormap, container, cursor, height, highlightbackground, + highlightcolor, highlightthickness, relief, takefocus, visual, width.-classLabelLabel widget which can display text and bitmaps.Construct a label widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, activeforeground, anchor, + background, bitmap, borderwidth, cursor, + disabledforeground, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, image, justify, + padx, pady, relief, takefocus, text, + textvariable, underline, wraplength + + WIDGET-SPECIFIC OPTIONS + + height, state, width + + labelListboxListbox widget which can display a list of strings.Construct a listbox widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, cursor, + exportselection, fg, font, foreground, height, highlightbackground, + highlightcolor, highlightthickness, relief, selectbackground, + selectborderwidth, selectforeground, selectmode, setgrid, takefocus, + width, xscrollcommand, yscrollcommand, listvariable.listboxactivateActivate item identified by INDEX.Return a tuple of X1,Y1,X2,Y2 coordinates for a rectangle + which encloses the item identified by the given index.curselectionReturn the indices of currently selected item.Delete items from FIRST to LAST (included).Get list of items from FIRST to LAST (included).Return index of item identified with INDEX.Insert ELEMENTS at INDEX.nearestGet index of item which is nearest to y coordinate Y.Adjust the view of the listbox to 10 times the + difference between X and Y and the coordinates given in + scan_mark.seeScroll such that INDEX is visible.selection_anchorSet the fixed end oft the selection to INDEX.select_anchorClear the selection from FIRST to LAST (included).selection_includesReturn True if INDEX is part of the selection.includesselect_includesselection_setSet the selection from FIRST to LAST (included) without + changing the currently selected elements.select_setReturn the number of elements in the listbox.Return the resource value for an ITEM and an OPTION.Configure resources of an ITEM. + + The values for resources are specified as keyword arguments. + To get an overview about the allowed keyword arguments + call the method without arguments. + Valid resource names: background, bg, foreground, fg, + selectbackground, selectforeground.MenuMenu widget which allows displaying menu bars, pull-down menus and pop-up menus.Construct menu widget with the parent MASTER. + + Valid resource names: activebackground, activeborderwidth, + activeforeground, background, bd, bg, borderwidth, cursor, + disabledforeground, fg, font, foreground, postcommand, relief, + selectcolor, takefocus, tearoff, tearoffcommand, title, type.menutk_popupPost the menu at position X,Y with entry ENTRY.Activate entry at INDEX.add_cascadeAdd hierarchical menu item.cascadeadd_checkbuttonAdd checkbutton menu item.add_commandAdd command menu item.add_radiobuttonAddd radio menu item.radiobuttonadd_separatorAdd separator.separatorinsert_cascadeAdd hierarchical menu item at INDEX.insert_checkbuttonAdd checkbutton menu item at INDEX.insert_commandAdd command menu item at INDEX.insert_radiobuttonAddd radio menu item at INDEX.insert_separatorAdd separator at INDEX.index1index2Delete menu items between INDEX1 and INDEX2 (included).num_index1num_index2entryconfigentrycgetReturn the resource value of a menu item for OPTION at INDEX.entryconfigureConfigure a menu item at INDEX.Return the index of a menu item identified by INDEX.Invoke a menu item identified by INDEX and execute + the associated command.postDisplay a menu at position X,Y.Return the type of the menu item at INDEX.unpostUnmap a menu.xpositionReturn the x-position of the leftmost pixel of the menu item + at INDEX.ypositionReturn the y-position of the topmost pixel of the menu item at INDEX.MenubuttonMenubutton widget, obsolete since Tk8.0.menubuttonMessageMessage widget to display multiline text. Obsolete since Label does it too.messageRadiobuttonRadiobutton widget which shows only one of several buttons in on-state.Construct a radiobutton widget with the parent MASTER. + + Valid resource names: activebackground, activeforeground, anchor, + background, bd, bg, bitmap, borderwidth, command, cursor, + disabledforeground, fg, font, foreground, height, + highlightbackground, highlightcolor, highlightthickness, image, + indicatoron, justify, padx, pady, relief, selectcolor, selectimage, + state, takefocus, text, textvariable, underline, value, variable, + width, wraplength.ScaleScale widget which can display a numerical scale.Construct a scale widget with the parent MASTER. + + Valid resource names: activebackground, background, bigincrement, bd, + bg, borderwidth, command, cursor, digits, fg, font, foreground, from, + highlightbackground, highlightcolor, highlightthickness, label, + length, orient, relief, repeatdelay, repeatinterval, resolution, + showvalue, sliderlength, sliderrelief, state, takefocus, + tickinterval, to, troughcolor, variable, width.Get the current value as integer or float.Set the value to VALUE.Return a tuple (X,Y) of the point along the centerline of the + trough that corresponds to VALUE or the current value if None is + given.identifyReturn where the point X,Y lies. Valid return values are "slider", + "though1" and "though2".ScrollbarScrollbar widget which displays a slider at a certain position.Construct a scrollbar widget with the parent MASTER. + + Valid resource names: activebackground, activerelief, + background, bd, bg, borderwidth, command, cursor, + elementborderwidth, highlightbackground, + highlightcolor, highlightthickness, jump, orient, + relief, repeatdelay, repeatinterval, takefocus, + troughcolor, width.scrollbarMarks the element indicated by index as active. + The only index values understood by this method are "arrow1", + "slider", or "arrow2". If any other value is specified then no + element of the scrollbar will be active. If index is not specified, + the method returns the name of the element that is currently active, + or None if no element is active.deltaxdeltayReturn the fractional change of the scrollbar setting if it + would be moved by DELTAX or DELTAY pixels.Return the fractional value which corresponds to a slider + position of X,Y.Return the element under position X,Y as one of + "arrow1","slider","arrow2" or "".Return the current fractional values (upper and lower end) + of the slider position.Set the fractional values of the slider position (upper and + lower ends as value between 0 and 1).TextText widget which can display text in various forms.Construct a text widget with the parent MASTER. + + STANDARD OPTIONS + + background, borderwidth, cursor, + exportselection, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, insertbackground, + insertborderwidth, insertofftime, + insertontime, insertwidth, padx, pady, + relief, selectbackground, + selectborderwidth, selectforeground, + setgrid, takefocus, + xscrollcommand, yscrollcommand, + + WIDGET-SPECIFIC OPTIONS + + autoseparators, height, maxundo, + spacing1, spacing2, spacing3, + state, tabs, undo, width, wrap, + + Return a tuple of (x,y,width,height) which gives the bounding + box of the visible part of the character at the given index.compareopReturn whether between index INDEX1 and index INDEX2 the + relation OP is satisfied. OP is one of <, <=, ==, >=, >, or !=.Counts the number of relevant things between the two indices. + If index1 is after index2, the result will be a negative number + (and this holds for each of the possible options). + + The actual items which are counted depends on the options given by + args. The result is a list of integers, one for the result of each + counting option given. Valid counting options are "chars", + "displaychars", "displayindices", "displaylines", "indices", + "lines", "xpixels" and "ypixels". There is an additional possible + option "update", which if given then all subsequent options ensure + that any possible out of date information is recalculated.argTurn on the internal consistency checks of the B-Tree inside the text + widget according to BOOLEAN.Delete the characters between INDEX1 and INDEX2 (not included).dlineinfoReturn tuple (x,y,width,height,baseline) giving the bounding box + and baseline position of the visible part of the line containing + the character at INDEX.Return the contents of the widget between index1 and index2. + + The type of contents returned in filtered based on the keyword + parameters; if 'all', 'image', 'mark', 'tag', 'text', or 'window' are + given and true, then the corresponding items are returned. The result + is a list of triples of the form (key, value, index). If none of the + keywords are true then 'all' is used by default. + + If the 'command' argument is given, it is called once for each element + of the list of triples, with the values of each triple serving as the + arguments to the function. In this case the list is not returned.func_nameappend_triple-commandeditInternal method + + This method controls the undo mechanism and + the modified flag. The exact behavior of the + command depends on the option argument that + follows the edit argument. The following forms + of the command are currently supported: + + edit_modified, edit_redo, edit_reset, edit_separator + and edit_undo + + edit_modifiedGet or Set the modified flag + + If arg is not specified, returns the modified + flag of the widget. The insert, delete, edit undo and + edit redo commands or the user can set or clear the + modified flag. If boolean is specified, sets the + modified flag of the widget to arg. + modifiededit_redoRedo the last undone edit + + When the undo option is true, reapplies the last + undone edits provided no other edits were done since + then. Generates an error when the redo stack is empty. + Does nothing when the undo option is false. + redoedit_resetClears the undo and redo stacks + resetedit_separatorInserts a separator (boundary) on the undo stack. + + Does nothing when the undo option is false + edit_undoUndoes the last edit action + + If the undo option is true. An edit action is defined + as all the insert and delete commands that are recorded + on the undo stack in between two separators. Generates + an error when the undo stack is empty. Does nothing + when the undo option is false + undoReturn the text from INDEX1 to INDEX2 (not included).image_cgetReturn the value of OPTION of an embedded image at INDEX.image_configureConfigure an embedded image at INDEX.image_createCreate an embedded image at INDEX.Return all names of embedded images in this widget.Return the index in the form line.char for INDEX.charsInsert CHARS before the characters at INDEX. An additional + tag can be given in ARGS. Additional CHARS and tags can follow in ARGS.mark_gravitymarkNamedirectionChange the gravity of a mark MARKNAME to DIRECTION (LEFT or RIGHT). + Return the current value if None is given for DIRECTION.gravitymark_namesReturn all mark names.mark_setSet mark MARKNAME before the character at INDEX.mark_unsetmarkNamesDelete all marks in MARKNAMES.unsetmark_nextReturn the name of the next mark after INDEX.mark_previousReturn the name of the previous mark before INDEX.previouspeer_createnewPathNameCreates a peer text widget with the given newPathName, and any + optional standard configuration options. By default the peer will + have the same start and end line as the parent widget, but + these can be overridden with the standard configuration options.peerpeer_namesReturns a list of peers of this widget (this does not include + the widget itself).Replaces the range of characters between index1 and index2 with + the given characters and tags specified by args. + + See the method insert for some more information about args, and the + method delete for information about the indices.Adjust the view of the text to 10 times the + difference between X and Y and the coordinates given in + scan_mark.stopindexforwardsbackwardsexactregexpnocaseelideSearch PATTERN beginning from INDEX until STOPINDEX. + Return the index of the first character of a match or an + empty string.-forwards-backwards-exact-regexp-nocase-elide-countScroll such that the character at INDEX is visible.tag_addtagNameAdd tag TAGNAME to all characters between INDEX1 and index2 in ARGS. + Additional pairs of indices may follow in ARGS.Unbind for all characters with TAGNAME for event SEQUENCE the + function identified with FUNCID.Bind to all characters with TAGNAME at event SEQUENCE a call to function FUNC. + + An additional boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or whether it will + replace the previous function. See bind for the return value.tag_cgetReturn the value of OPTION for tag TAGNAME.tag_configureConfigure a tag TAGNAME.tag_configtag_deletetagNamesDelete all tags in TAGNAMES.Change the priority of tag TAGNAME such that it is lower + than the priority of BELOWTHIS.tag_namesReturn a list of all tag names.tag_nextrangeReturn a list of start and end index for the first sequence of + characters between INDEX1 and INDEX2 which all have tag TAGNAME. + The text is searched forward from INDEX1.nextrangetag_prevrangeReturn a list of start and end index for the first sequence of + characters between INDEX1 and INDEX2 which all have tag TAGNAME. + The text is searched backwards from INDEX1.prevrangeChange the priority of tag TAGNAME such that it is higher + than the priority of ABOVETHIS.tag_rangesReturn a list of ranges of text which have tag TAGNAME.rangestag_removeRemove tag TAGNAME from all characters between INDEX1 and INDEX2.window_cgetReturn the value of OPTION of an embedded window at INDEX.window_configureConfigure an embedded window at INDEX.window_configwindow_createCreate a window at INDEX.window_namesReturn all names of embedded windows in this widget.yview_pickplaceObsolete function, use see.-pickplace_setitInternal class. It wraps the command in the widget OptionMenu.var__value__var__callbackOptionMenuOptionMenu which allows the user to select a value from a menu.Construct an optionmenu widget with the parent MASTER, with + the resource textvariable set to VARIABLE, the initially selected + value VALUE, the other menu values VALUES and an additional + keyword argument command.borderwidthtextvariableindicatoronRAISEDreliefhighlightthicknesstk_optionMenutearoff__menumenunameunknown option -Destroy this widget and the associated menu.ImageBase class for images._last_idimgtypecreate imagepyimage%rConfigure the image.Return the height of the image.Return the type of the image, e.g. "photo" or "bitmap".Return the width of the image.PhotoImageWidget which can display images in PGM, PPM, GIF, PNG format.Create an image with NAME. + + Valid resource names: data, format, file, gamma, height, palette, + width.photoblankDisplay a transparent image.Return the value of OPTION.Return a new PhotoImage with the same image as this widget.destImagezoomReturn a new PhotoImage with the same image as this widget + but zoom it with a factor of x in the X direction and y in the Y + direction. If y is not given, the default value is the same as x. + -zoomsubsampleReturn a new PhotoImage based on the same image as this widget + but use only every Xth or Yth pixel. If y is not given, the + default value is the same as x. + -subsampleReturn the color (red, green, blue) of the pixel at X,Y.putPut row formatted colors to image starting from + position TO, e.g. image.put("{red green} {blue yellow}", to=(4,6))-tofrom_coordsWrite image to file FILENAME in FORMAT starting from + position FROM_COORDS.-format-fromtransparency_getReturn True if the pixel at x,y is transparent.transparencytransparency_setSet the transparency of the pixel at x,y.BitmapImageWidget which can display images in XBM format.Create a bitmap with NAME. + + Valid resource names: background, data, file, foreground, maskdata, maskfile.use image_names()use image_types()Spinboxspinbox widget.Construct a spinbox widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, background, borderwidth, + cursor, exportselection, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, insertbackground, + insertborderwidth, insertofftime, + insertontime, insertwidth, justify, relief, + repeatdelay, repeatinterval, + selectbackground, selectborderwidth + selectforeground, takefocus, textvariable + xscrollcommand. + + WIDGET-SPECIFIC OPTIONS + + buttonbackground, buttoncursor, + buttondownrelief, buttonuprelief, + command, disabledbackground, + disabledforeground, format, from, + invalidcommand, increment, + readonlybackground, state, to, + validate, validatecommand values, + width, wrap, + spinboxReturn a tuple of X1,Y1,X2,Y2 coordinates for a + rectangle which encloses the character given by index. + + The first two elements of the list give the x and y + coordinates of the upper-left corner of the screen + area covered by the character (in pixels relative + to the widget) and the last two elements give the + width and height of the character, in pixels. The + bounding box may refer to a region outside the + visible area of the window. + Delete one or more elements of the spinbox. + + First is the index of the first character to delete, + and last is the index of the character just after + the last one to delete. If last isn't specified it + defaults to first+1, i.e. a single character is + deleted. This command returns an empty string. + Returns the spinbox's stringAlter the position of the insertion cursor. + + The insertion cursor will be displayed just before + the character given by index. Returns an empty string + Returns the name of the widget at position x, y + + Return value is one of: none, buttondown, buttonup, entry + Returns the numerical index corresponding to index + Insert string s at index + + Returns an empty string. + Causes the specified element to be invoked + + The element could be buttondown or buttonup + triggering the action associated with it. + Records x and the current view in the spinbox window; + + used in conjunction with later scan dragto commands. + Typically this command is associated with a mouse button + press in the widget. It returns an empty string. + Compute the difference between the given x argument + and the x argument to the last scan mark command + + It then adjusts the view left or right by 10 times the + difference in x-coordinates. This command is typically + associated with mouse motion events in the widget, to + produce the effect of dragging the spinbox at high speed + through the window. The return value is an empty string. + Locate the end of the selection nearest to the character + given by index, + + Then adjust that end of the selection to be at index + (i.e including but not going beyond index). The other + end of the selection is made the anchor point for future + select to commands. If the selection isn't currently in + the spinbox, then a new selection is created to include + the characters between index and the most recent selection + anchor point, inclusive. + Clear the selection + + If the selection isn't in this widget then the + command has no effect. + selection_elementSets or gets the currently selected element. + + If a spinbutton element is specified, it will be + displayed depressed. + Return True if there are characters selected in the spinbox, False + otherwise.LabelFramelabelframe widget.Construct a labelframe widget with the parent MASTER. + + STANDARD OPTIONS + + borderwidth, cursor, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, padx, pady, relief, + takefocus, text + + WIDGET-SPECIFIC OPTIONS + + background, class, colormap, container, + height, labelanchor, labelwidget, + visual, width + labelframePanedWindowpanedwindow widget.Construct a panedwindow widget with the parent MASTER. + + STANDARD OPTIONS + + background, borderwidth, cursor, height, + orient, relief, width + + WIDGET-SPECIFIC OPTIONS + + handlepad, handlesize, opaqueresize, + sashcursor, sashpad, sashrelief, + sashwidth, showhandle, + panedwindowAdd a child widget to the panedwindow in a new pane. + + The child argument is the name of the child widget + followed by pairs of arguments that specify how to + manage the windows. The possible options and values + are the ones accepted by the paneconfigure method. + Remove the pane containing child from the panedwindow + + All geometry management options for child will be forgotten. + Identify the panedwindow component at point x, y + + If the point is over a sash or a sash handle, the result + is a two element list containing the index of the sash or + handle, and a word indicating whether it is over a sash + or a handle, such as {0 sash} or {2 handle}. If the point + is over any other part of the panedwindow, the result is + an empty list. + proxyproxy_coordReturn the x and y pair of the most recent proxy location + coordproxy_forgetRemove the proxy from the display. + proxy_placePlace the proxy at the given x and y coordinates. + sashsash_coordReturn the current x and y pair for the sash given by index. + + Index must be an integer between 0 and 1 less than the + number of panes in the panedwindow. The coordinates given are + those of the top left corner of the region containing the sash. + pathName sash dragto index x y This command computes the + difference between the given coordinates and the coordinates + given to the last sash coord command for the given sash. It then + moves that sash the computed difference. The return value is the + empty string. + sash_markRecords x and y for the sash given by index; + + Used in conjunction with later dragto commands to move the sash. + sash_placePlace the sash given by index at the given coordinates + panecgetQuery a management option for window. + + Option may be any value allowed by the paneconfigure subcommand + paneconfigureQuery or modify the management options for window. + + If no option is specified, returns a list describing all + of the available options for pathName. If option is + specified with no value, then the command returns a list + describing the one named option (this list will be identical + to the corresponding sublist of the value returned if no + option is specified). If one or more option-value pairs are + specified, then the command modifies the given widget + option(s) to have the given value(s); in this case the + command returns an empty string. The following options + are supported: + + after window + Insert the window after the window specified. window + should be the name of a window already managed by pathName. + before window + Insert the window before the window specified. window + should be the name of a window already managed by pathName. + height size + Specify a height for the window. The height will be the + outer dimension of the window including its border, if + any. If size is an empty string, or if -height is not + specified, then the height requested internally by the + window will be used initially; the height may later be + adjusted by the movement of sashes in the panedwindow. + Size may be any value accepted by Tk_GetPixels. + minsize n + Specifies that the size of the window cannot be made + less than n. This constraint only affects the size of + the widget in the paned dimension -- the x dimension + for horizontal panedwindows, the y dimension for + vertical panedwindows. May be any value accepted by + Tk_GetPixels. + padx n + Specifies a non-negative value indicating how much + extra space to leave on each side of the window in + the X-direction. The value may have any of the forms + accepted by Tk_GetPixels. + pady n + Specifies a non-negative value indicating how much + extra space to leave on each side of the window in + the Y-direction. The value may have any of the forms + accepted by Tk_GetPixels. + sticky style + If a window's pane is larger than the requested + dimensions of the window, this option may be used + to position (or stretch) the window within its pane. + Style is a string that contains zero or more of the + characters n, s, e or w. The string can optionally + contains spaces or commas, but they are ignored. Each + letter refers to a side (north, south, east, or west) + that the window will "stick" to. If both n and s + (or e and w) are specified, the window will be + stretched to fill the entire height (or width) of + its cavity. + width size + Specify a width for the window. The width will be + the outer dimension of the window including its + border, if any. If size is an empty string, or + if -width is not specified, then the width requested + internally by the window will be used initially; the + width may later be adjusted by the movement of sashes + in the panedwindow. Size may be any value accepted by + Tk_GetPixels. + + paneconfigpanesReturns an ordered list of the child panes._testThis is Tcl/Tk version %s +This should be a cedilla: çClick me![%s]QUIT# If this fails your Python may not be configured for Tk# add '\' before special characters and spaces# undocumented# widget usually is known# serial and time are not very interesting# keysym_num duplicates keysym# x_root and y_root mostly duplicate x and y# Delete, so any use of _default_root will immediately raise an exception.# Rebind before deletion, so repeated calls will not fail.# check for type of NAME parameter to override weird error message# raised from Modules/_tkinter.c:SetVar like:# TypeError: setvar() takes exactly 3 arguments (2 given)#print '- Tkinter: deleted command', name# TODO: Add deprecation warning# Methods defined on both toplevel and interior widgets# used for generating child widget names# XXX font command?# XXX b/w compat# XXX b/w compat?# I'd rather use time.sleep(ms*0.001)# Clipboard handling:# XXX grab current w/o window argument# Tcl sometimes returns extra windows, e.g. for# menus; those need to be skipped# Missing: (a, c, d, m, o, v, B, R)# serial field: valid for all events# number of button: ButtonPress and ButtonRelease events only# height field: Configure, ConfigureRequest, Create,# ResizeRequest, and Expose events only# keycode field: KeyPress and KeyRelease events only# time field: "valid for events that contain a time field"# width field: Configure, ConfigureRequest, Create, ResizeRequest,# and Expose events only# x field: "valid for events that contain an x field"# y field: "valid for events that contain a y field"# keysym as decimal: KeyPress and KeyRelease events only# x_root, y_root fields: ButtonPress, ButtonRelease, KeyPress,# KeyRelease, and Motion events# These used to be defined in Widget:# Pack methods that apply to the master# Place method that applies to the master# Grid methods that apply to the master# new in Tk 8.5# Support for the "event" command, new in Tk 4.2.# By Case Roole.# Image related commands# Tk needs a list of windows here# to avoid recursions in the getattr code in case of failure, we# ensure that self.tk is always _something_.# Issue #16248: Honor the -E flag to avoid code injection.# Version sanity checks# Under unknown circumstances, tcl_version gets coerced to float# Create and register the tkerror and exit commands# We need to inline parts of _register here, _ register# would register differently-named commands.# Ideally, the classes Pack, Place and Grid disappear, the# pack/place/grid methods are defined on the Widget class, and# everybody uses w.pack_whatever(...) instead of Pack.whatever(w,# ...), with pack(), place() and grid() being short for# pack_configure(), place_configure() and grid_columnconfigure(), and# forget() being short for pack_forget(). As a practical matter, I'm# afraid that there is too much code out there that may be using the# Pack, Place or Grid class, so I leave them intact -- but only as# backwards compatibility features. Also note that those methods that# take a master as argument (e.g. pack_propagate) have been moved to# the Misc class (which now incorporates all methods common between# toplevel and interior widgets). Again, for compatibility, these are# copied into the Pack, Place or Grid class.# Thanks to Masazumi Yoshikawa (yosikawa@isi.edu)# XXX Obsolete -- better use self.tk.call directly!# TBD: a hack needed because some keys# are not valid as keyword arguments# XXX Should use _flatten on args# Args: (val, val, ..., cnf={})# lower, tkraise/lift hide Misc.lower, Misc.tkraise/lift,# so the preferred name for them is tag_lower, tag_raise# (similar to tag_bind, and similar to the Text widget);# unfortunately can't delete the old ones yet (maybe in 1.6)# Never call the dump command without the -command flag, since the# output could involve Tcl quoting and would be a pain to parse# right. Instead just set the command to build a list of triples# as if we had done the parsing.## new in tk8.4# (Image commands are new in 8.0)# 'command' is the only supported keyword# tk itself would use image# May happen if the root was destroyed# XXX config# XXX copy -from, -to, ...?# XXX read#################################################################################################################################################### Test:# The following three commands are needed so the window pops# up on top on Windows...b'Wrapper functions for Tcl/Tk. + +Tkinter provides classes which allow the display, positioning and +control of widgets. Toplevel widgets are Tk and Toplevel. Other +widgets are Frame, Label, Entry, Text, Canvas, Button, Radiobutton, +Checkbutton, Scale, Listbox, Scrollbar, OptionMenu, Spinbox +LabelFrame and PanedWindow. + +Properties of the widgets are specified with keyword arguments. +Keyword arguments have the same name as the corresponding resource +under Tk. + +Widgets are positioned with one of the geometry managers Place, Pack +or Grid. These managers can be called with methods place, pack, grid +available in every Widget. + +Actions are bound to events by resources (e.g. keyword argument +command) or with the method bind. + +Example (Hello, World): +import tkinter +from tkinter.constants import * +tk = tkinter.Tk() +frame = tkinter.Frame(tk, relief=RIDGE, borderwidth=2) +frame.pack(fill=BOTH,expand=1) +label = tkinter.Label(frame, text="Hello, World") +label.pack(fill=X, expand=1) +button = tkinter.Button(frame,text="Exit",command=tk.destroy) +button.pack(side=BOTTOM) +tk.mainloop() +'u'Wrapper functions for Tcl/Tk. + +Tkinter provides classes which allow the display, positioning and +control of widgets. Toplevel widgets are Tk and Toplevel. Other +widgets are Frame, Label, Entry, Text, Canvas, Button, Radiobutton, +Checkbutton, Scale, Listbox, Scrollbar, OptionMenu, Spinbox +LabelFrame and PanedWindow. + +Properties of the widgets are specified with keyword arguments. +Keyword arguments have the same name as the corresponding resource +under Tk. + +Widgets are positioned with one of the geometry managers Place, Pack +or Grid. These managers can be called with methods place, pack, grid +available in every Widget. + +Actions are bound to events by resources (e.g. keyword argument +command) or with the method bind. + +Example (Hello, World): +import tkinter +from tkinter.constants import * +tk = tkinter.Tk() +frame = tkinter.Frame(tk, relief=RIDGE, borderwidth=2) +frame.pack(fill=BOTH,expand=1) +label = tkinter.Label(frame, text="Hello, World") +label.pack(fill=X, expand=1) +button = tkinter.Button(frame,text="Exit",command=tk.destroy) +button.pack(side=BOTTOM) +tk.mainloop() +'b'([\\{}])'u'([\\{}])'b'([\s])'u'([\s])'b'Internal function.'u'Internal function.'b'{%s}'u'{%s}'b'\\\1'u'\\\1'b'\n'u'\n'b'\'u'\'b'_cnfmerge: fallback due to:'u'_cnfmerge: fallback due to:'b'Return a properly formatted dict built from Tcl list pairs. + + If cut_minus is True, the supposed '-' prefix will be removed from + keys. If conv is specified, it is used to convert values. + + Tcl list is expected to contain an even number of elements. + 'u'Return a properly formatted dict built from Tcl list pairs. + + If cut_minus is True, the supposed '-' prefix will be removed from + keys. If conv is specified, it is used to convert values. + + Tcl list is expected to contain an even number of elements. + 'b'Tcl list representing a dict is expected to contain an even number of elements'u'Tcl list representing a dict is expected to contain an even number of elements'b'4'u'4'b'5'u'5'b'6'u'6'b'7'u'7'b'8'u'8'b'9'u'9'b'10'u'10'b'11'u'11'b'12'u'12'b'13'u'13'b'14'u'14'b'15'u'15'b'16'u'16'b'17'u'17'b'18'u'18'b'19'u'19'b'20'u'20'b'21'u'21'b'22'u'22'b'23'u'23'b'24'u'24'b'25'u'25'b'26'u'26'b'27'u'27'b'28'u'28'b'29'u'29'b'30'u'30'b'31'u'31'b'32'u'32'b'33'u'33'b'34'u'34'b'35'u'35'b'36'u'36'b'37'u'37'b'38'u'38'b'Container for the properties of an event. + + Instances of this type are generated if one of the following events occurs: + + KeyPress, KeyRelease - for keyboard events + ButtonPress, ButtonRelease, Motion, Enter, Leave, MouseWheel - for mouse events + Visibility, Unmap, Map, Expose, FocusIn, FocusOut, Circulate, + Colormap, Gravity, Reparent, Property, Destroy, Activate, + Deactivate - for window events. + + If a callback function for one of these events is registered + using bind, bind_all, bind_class, or tag_bind, the callback is + called with an Event as first argument. It will have the + following attributes (in braces are the event types for which + the attribute is valid): + + serial - serial number of event + num - mouse button pressed (ButtonPress, ButtonRelease) + focus - whether the window has the focus (Enter, Leave) + height - height of the exposed window (Configure, Expose) + width - width of the exposed window (Configure, Expose) + keycode - keycode of the pressed key (KeyPress, KeyRelease) + state - state of the event as a number (ButtonPress, ButtonRelease, + Enter, KeyPress, KeyRelease, + Leave, Motion) + state - state as a string (Visibility) + time - when the event occurred + x - x-position of the mouse + y - y-position of the mouse + x_root - x-position of the mouse on the screen + (ButtonPress, ButtonRelease, KeyPress, KeyRelease, Motion) + y_root - y-position of the mouse on the screen + (ButtonPress, ButtonRelease, KeyPress, KeyRelease, Motion) + char - pressed character (KeyPress, KeyRelease) + send_event - see X/Windows documentation + keysym - keysym of the event as a string (KeyPress, KeyRelease) + keysym_num - keysym of the event as a number (KeyPress, KeyRelease) + type - type of the event as a number + widget - widget in which the event occurred + delta - delta of wheel movement (MouseWheel) + 'u'Container for the properties of an event. + + Instances of this type are generated if one of the following events occurs: + + KeyPress, KeyRelease - for keyboard events + ButtonPress, ButtonRelease, Motion, Enter, Leave, MouseWheel - for mouse events + Visibility, Unmap, Map, Expose, FocusIn, FocusOut, Circulate, + Colormap, Gravity, Reparent, Property, Destroy, Activate, + Deactivate - for window events. + + If a callback function for one of these events is registered + using bind, bind_all, bind_class, or tag_bind, the callback is + called with an Event as first argument. It will have the + following attributes (in braces are the event types for which + the attribute is valid): + + serial - serial number of event + num - mouse button pressed (ButtonPress, ButtonRelease) + focus - whether the window has the focus (Enter, Leave) + height - height of the exposed window (Configure, Expose) + width - width of the exposed window (Configure, Expose) + keycode - keycode of the pressed key (KeyPress, KeyRelease) + state - state of the event as a number (ButtonPress, ButtonRelease, + Enter, KeyPress, KeyRelease, + Leave, Motion) + state - state as a string (Visibility) + time - when the event occurred + x - x-position of the mouse + y - y-position of the mouse + x_root - x-position of the mouse on the screen + (ButtonPress, ButtonRelease, KeyPress, KeyRelease, Motion) + y_root - y-position of the mouse on the screen + (ButtonPress, ButtonRelease, KeyPress, KeyRelease, Motion) + char - pressed character (KeyPress, KeyRelease) + send_event - see X/Windows documentation + keysym - keysym of the event as a string (KeyPress, KeyRelease) + keysym_num - keysym of the event as a number (KeyPress, KeyRelease) + type - type of the event as a number + widget - widget in which the event occurred + delta - delta of wheel movement (MouseWheel) + 'b'??'u'??'b'char'u'char'b'send_event'u'send_event'b'state'u'state'b'Shift'u'Shift'b'Lock'u'Lock'b'Control'u'Control'b'Mod1'u'Mod1'b'Mod2'u'Mod2'b'Mod3'u'Mod3'b'Mod4'u'Mod4'b'Mod5'u'Mod5'b'Button1'u'Button1'b'Button2'u'Button2'b'Button3'u'Button3'b'Button4'u'Button4'b'Button5'u'Button5'b'|'u'|'b'delta'u'delta'b'keysym'u'keysym'b'keycode'u'keycode'b'num'u'num'b'focus'u'focus'b'x'u'x'b'y'u'y'b'width'u'width'b'height'u'height'b'<%s event%s>'u'<%s event%s>'b'name'u'name'b' %s=%s'u' %s=%s'b'Inhibit setting of default root window. + + Call this function to inhibit that the first instance of + Tk is used for windows without an explicit parent window. + 'u'Inhibit setting of default root window. + + Call this function to inhibit that the first instance of + Tk is used for windows without an explicit parent window. + 'b'No master specified and tkinter is configured to not support default root'u'No master specified and tkinter is configured to not support default root'b'Too early to 'u'Too early to 'b': no default root window'u': no default root window'b'Internal function. Calling it will raise the exception SystemExit.'u'Internal function. Calling it will raise the exception SystemExit.'b'Class to define value holders for e.g. buttons. + + Subclasses StringVar, IntVar, DoubleVar, BooleanVar are specializations + that constrain the type of the value returned from get().'u'Class to define value holders for e.g. buttons. + + Subclasses StringVar, IntVar, DoubleVar, BooleanVar are specializations + that constrain the type of the value returned from get().'b'Construct a variable + + MASTER can be given as master widget. + VALUE is an optional value (defaults to "") + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'u'Construct a variable + + MASTER can be given as master widget. + VALUE is an optional value (defaults to "") + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'b'name must be a string'u'name must be a string'b'create variable'u'create variable'b'PY_VAR'u'PY_VAR'b'info'u'info'b'exists'u'exists'b'Unset the variable in Tcl.'u'Unset the variable in Tcl.'b'Return the name of the variable in Tcl.'u'Return the name of the variable in Tcl.'b'Set the variable to VALUE.'u'Set the variable to VALUE.'b'Return value of variable.'u'Return value of variable.'b'Define a trace callback for the variable. + + Mode is one of "read", "write", "unset", or a list or tuple of + such strings. + Callback must be a function which is called when the variable is + read, written or unset. + + Return the name of the callback. + 'u'Define a trace callback for the variable. + + Mode is one of "read", "write", "unset", or a list or tuple of + such strings. + Callback must be a function which is called when the variable is + read, written or unset. + + Return the name of the callback. + 'b'trace'u'trace'b'add'u'add'b'variable'u'variable'b'Delete the trace callback for a variable. + + Mode is one of "read", "write", "unset" or a list or tuple of + such strings. Must be same as were specified in trace_add(). + cbname is the name of the callback returned from trace_add(). + 'u'Delete the trace callback for a variable. + + Mode is one of "read", "write", "unset" or a list or tuple of + such strings. Must be same as were specified in trace_add(). + cbname is the name of the callback returned from trace_add(). + 'b'remove'u'remove'b'Return all trace callback information.'u'Return all trace callback information.'b'Define a trace callback for the variable. + + MODE is one of "r", "w", "u" for read, write, undefine. + CALLBACK must be a function which is called when + the variable is read, written or undefined. + + Return the name of the callback. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_add() instead. + 'u'Define a trace callback for the variable. + + MODE is one of "r", "w", "u" for read, write, undefine. + CALLBACK must be a function which is called when + the variable is read, written or undefined. + + Return the name of the callback. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_add() instead. + 'b'Delete the trace callback for a variable. + + MODE is one of "r", "w", "u" for read, write, undefine. + CBNAME is the name of the callback returned from trace_variable or trace. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_remove() instead. + 'u'Delete the trace callback for a variable. + + MODE is one of "r", "w", "u" for read, write, undefine. + CBNAME is the name of the callback returned from trace_variable or trace. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_remove() instead. + 'b'vdelete'u'vdelete'b'Return all trace callback information. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_info() instead. + 'u'Return all trace callback information. + + This deprecated method wraps a deprecated Tcl method that will + likely be removed in the future. Use trace_info() instead. + 'b'vinfo'u'vinfo'b'Value holder for strings variables.'u'Value holder for strings variables.'b'Construct a string variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to "") + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'u'Construct a string variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to "") + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'b'Return value of variable as string.'u'Return value of variable as string.'b'Value holder for integer variables.'u'Value holder for integer variables.'b'Construct an integer variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to 0) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'u'Construct an integer variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to 0) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'b'Return the value of the variable as an integer.'u'Return the value of the variable as an integer.'b'Value holder for float variables.'u'Value holder for float variables.'b'Construct a float variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to 0.0) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'u'Construct a float variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to 0.0) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'b'Return the value of the variable as a float.'u'Return the value of the variable as a float.'b'Value holder for boolean variables.'u'Value holder for boolean variables.'b'Construct a boolean variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to False) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'u'Construct a boolean variable. + + MASTER can be given as master widget. + VALUE is an optional value (defaults to False) + NAME is an optional Tcl name (defaults to PY_VARnum). + + If NAME matches an existing variable and VALUE is omitted + then the existing value is retained. + 'b'Return the value of the variable as a bool.'u'Return the value of the variable as a bool.'b'invalid literal for getboolean()'u'invalid literal for getboolean()'b'Run the main loop of Tcl.'u'Run the main loop of Tcl.'b'run the main loop'u'run the main loop'b'Convert Tcl object to True or False.'u'Convert Tcl object to True or False.'b'use getboolean()'u'use getboolean()'b'Internal class. + + Base class which defines methods common for interior widgets.'u'Internal class. + + Base class which defines methods common for interior widgets.'b'Internal function. + + Delete all Tcl commands created for + this widget in the Tcl interpreter.'u'Internal function. + + Delete all Tcl commands created for + this widget in the Tcl interpreter.'b'Internal function. + + Delete the Tcl command provided in NAME.'u'Internal function. + + Delete the Tcl command provided in NAME.'b'Set Tcl internal variable, whether the look and feel + should adhere to Motif. + + A parameter of 1 means adhere to Motif (e.g. no color + change if mouse passes over slider). + Returns the set value.'u'Set Tcl internal variable, whether the look and feel + should adhere to Motif. + + A parameter of 1 means adhere to Motif (e.g. no color + change if mouse passes over slider). + Returns the set value.'b'set'u'set'b'tk_strictMotif'u'tk_strictMotif'b'Change the color scheme to light brown as used in Tk 3.6 and before.'u'Change the color scheme to light brown as used in Tk 3.6 and before.'b'tk_bisque'u'tk_bisque'b'Set a new color scheme for all widget elements. + + A single color as argument will cause that all colors of Tk + widget elements are derived from this. + Alternatively several keyword parameters and its associated + colors can be given. The following keywords are valid: + activeBackground, foreground, selectColor, + activeForeground, highlightBackground, selectBackground, + background, highlightColor, selectForeground, + disabledForeground, insertBackground, troughColor.'u'Set a new color scheme for all widget elements. + + A single color as argument will cause that all colors of Tk + widget elements are derived from this. + Alternatively several keyword parameters and its associated + colors can be given. The following keywords are valid: + activeBackground, foreground, selectColor, + activeForeground, highlightBackground, selectBackground, + background, highlightColor, selectForeground, + disabledForeground, insertBackground, troughColor.'b'tk_setPalette'u'tk_setPalette'b'Wait until the variable is modified. + + A parameter of type IntVar, StringVar, DoubleVar or + BooleanVar must be given.'u'Wait until the variable is modified. + + A parameter of type IntVar, StringVar, DoubleVar or + BooleanVar must be given.'b'tkwait'u'tkwait'b'Wait until a WIDGET is destroyed. + + If no parameter is given self is used.'u'Wait until a WIDGET is destroyed. + + If no parameter is given self is used.'b'window'u'window'b'Wait until the visibility of a WIDGET changes + (e.g. it appears). + + If no parameter is given self is used.'u'Wait until the visibility of a WIDGET changes + (e.g. it appears). + + If no parameter is given self is used.'b'visibility'u'visibility'b'1'u'1'b'Set Tcl variable NAME to VALUE.'u'Set Tcl variable NAME to VALUE.'b'Return value of Tcl variable NAME.'u'Return value of Tcl variable NAME.'b'Return a boolean value for Tcl boolean values true and false given as parameter.'u'Return a boolean value for Tcl boolean values true and false given as parameter.'b'Direct input focus to this widget. + + If the application currently does not have the focus + this widget will get the focus if the application gets + the focus through the window manager.'u'Direct input focus to this widget. + + If the application currently does not have the focus + this widget will get the focus if the application gets + the focus through the window manager.'b'Direct input focus to this widget even if the + application does not have the focus. Use with + caution!'u'Direct input focus to this widget even if the + application does not have the focus. Use with + caution!'b'-force'u'-force'b'Return the widget which has currently the focus in the + application. + + Use focus_displayof to allow working with several + displays. Return None if application does not have + the focus.'u'Return the widget which has currently the focus in the + application. + + Use focus_displayof to allow working with several + displays. Return None if application does not have + the focus.'b'none'u'none'b'Return the widget which has currently the focus on the + display where this widget is located. + + Return None if the application does not have the focus.'u'Return the widget which has currently the focus on the + display where this widget is located. + + Return None if the application does not have the focus.'b'-displayof'u'-displayof'b'Return the widget which would have the focus if top level + for this widget gets the focus from the window manager.'u'Return the widget which would have the focus if top level + for this widget gets the focus from the window manager.'b'-lastfor'u'-lastfor'b'The widget under mouse will get automatically focus. Can not + be disabled easily.'u'The widget under mouse will get automatically focus. Can not + be disabled easily.'b'tk_focusFollowsMouse'u'tk_focusFollowsMouse'b'Return the next widget in the focus order which follows + widget which has currently the focus. + + The focus order first goes to the next child, then to + the children of the child recursively and then to the + next sibling which is higher in the stacking order. A + widget is omitted if it has the takefocus resource set + to 0.'u'Return the next widget in the focus order which follows + widget which has currently the focus. + + The focus order first goes to the next child, then to + the children of the child recursively and then to the + next sibling which is higher in the stacking order. A + widget is omitted if it has the takefocus resource set + to 0.'b'tk_focusNext'u'tk_focusNext'b'Return previous widget in the focus order. See tk_focusNext for details.'u'Return previous widget in the focus order. See tk_focusNext for details.'b'tk_focusPrev'u'tk_focusPrev'b'Call function once after given time. + + MS specifies the time in milliseconds. FUNC gives the + function which shall be called. Additional parameters + are given as parameters to the function call. Return + identifier to cancel scheduling with after_cancel.'u'Call function once after given time. + + MS specifies the time in milliseconds. FUNC gives the + function which shall be called. Additional parameters + are given as parameters to the function call. Return + identifier to cancel scheduling with after_cancel.'b'after'u'after'b'Call FUNC once if the Tcl main loop has no event to + process. + + Return an identifier to cancel the scheduling with + after_cancel.'u'Call FUNC once if the Tcl main loop has no event to + process. + + Return an identifier to cancel the scheduling with + after_cancel.'b'idle'u'idle'b'Cancel scheduling of function identified with ID. + + Identifier returned by after or after_idle must be + given as first parameter. + 'u'Cancel scheduling of function identified with ID. + + Identifier returned by after or after_idle must be + given as first parameter. + 'b'id must be a valid identifier returned from after or after_idle'u'id must be a valid identifier returned from after or after_idle'b'cancel'u'cancel'b'Ring a display's bell.'u'Ring a display's bell.'b'bell'u'bell'b'Retrieve data from the clipboard on window's display. + + The window keyword defaults to the root window of the Tkinter + application. + + The type keyword specifies the form in which the data is + to be returned and should be an atom name such as STRING + or FILE_NAME. Type defaults to STRING, except on X11, where the default + is to try UTF8_STRING and fall back to STRING. + + This command is equivalent to: + + selection_get(CLIPBOARD) + 'u'Retrieve data from the clipboard on window's display. + + The window keyword defaults to the root window of the Tkinter + application. + + The type keyword specifies the form in which the data is + to be returned and should be an atom name such as STRING + or FILE_NAME. Type defaults to STRING, except on X11, where the default + is to try UTF8_STRING and fall back to STRING. + + This command is equivalent to: + + selection_get(CLIPBOARD) + 'b'type'u'type'b'x11'u'x11'b'UTF8_STRING'u'UTF8_STRING'b'clipboard'u'clipboard'b'get'u'get'b'Clear the data in the Tk clipboard. + + A widget specified for the optional displayof keyword + argument specifies the target display.'u'Clear the data in the Tk clipboard. + + A widget specified for the optional displayof keyword + argument specifies the target display.'b'displayof'u'displayof'b'clear'u'clear'b'Append STRING to the Tk clipboard. + + A widget specified at the optional displayof keyword + argument specifies the target display. The clipboard + can be retrieved with selection_get.'u'Append STRING to the Tk clipboard. + + A widget specified at the optional displayof keyword + argument specifies the target display. The clipboard + can be retrieved with selection_get.'b'append'u'append'b'--'u'--'b'Return widget which has currently the grab in this application + or None.'u'Return widget which has currently the grab in this application + or None.'b'grab'u'grab'b'current'u'current'b'Release grab for this widget if currently set.'u'Release grab for this widget if currently set.'b'release'u'release'b'Set grab for this widget. + + A grab directs all events to this and descendant + widgets in the application.'u'Set grab for this widget. + + A grab directs all events to this and descendant + widgets in the application.'b'Set global grab for this widget. + + A global grab directs all events to this and + descendant widgets on the display. Use with caution - + other applications do not get events anymore.'u'Set global grab for this widget. + + A global grab directs all events to this and + descendant widgets on the display. Use with caution - + other applications do not get events anymore.'b'-global'u'-global'b'Return None, "local" or "global" if this widget has + no, a local or a global grab.'u'Return None, "local" or "global" if this widget has + no, a local or a global grab.'b'status'u'status'b'Set a VALUE (second parameter) for an option + PATTERN (first parameter). + + An optional third parameter gives the numeric priority + (defaults to 80).'u'Set a VALUE (second parameter) for an option + PATTERN (first parameter). + + An optional third parameter gives the numeric priority + (defaults to 80).'b'option'u'option'b'Clear the option database. + + It will be reloaded if option_add is called.'u'Clear the option database. + + It will be reloaded if option_add is called.'b'Return the value for an option NAME for this widget + with CLASSNAME. + + Values with higher priority override lower values.'u'Return the value for an option NAME for this widget + with CLASSNAME. + + Values with higher priority override lower values.'b'Read file FILENAME into the option database. + + An optional second parameter gives the numeric + priority.'u'Read file FILENAME into the option database. + + An optional second parameter gives the numeric + priority.'b'readfile'u'readfile'b'Clear the current X selection.'u'Clear the current X selection.'b'selection'u'selection'b'Return the contents of the current X selection. + + A keyword parameter selection specifies the name of + the selection and defaults to PRIMARY. A keyword + parameter displayof specifies a widget on the display + to use. A keyword parameter type specifies the form of data to be + fetched, defaulting to STRING except on X11, where UTF8_STRING is tried + before STRING.'u'Return the contents of the current X selection. + + A keyword parameter selection specifies the name of + the selection and defaults to PRIMARY. A keyword + parameter displayof specifies a widget on the display + to use. A keyword parameter type specifies the form of data to be + fetched, defaulting to STRING except on X11, where UTF8_STRING is tried + before STRING.'b'Specify a function COMMAND to call if the X + selection owned by this widget is queried by another + application. + + This function must return the contents of the + selection. The function will be called with the + arguments OFFSET and LENGTH which allows the chunking + of very long selections. The following keyword + parameters can be provided: + selection - name of the selection (default PRIMARY), + type - type of the selection (e.g. STRING, FILE_NAME).'u'Specify a function COMMAND to call if the X + selection owned by this widget is queried by another + application. + + This function must return the contents of the + selection. The function will be called with the + arguments OFFSET and LENGTH which allows the chunking + of very long selections. The following keyword + parameters can be provided: + selection - name of the selection (default PRIMARY), + type - type of the selection (e.g. STRING, FILE_NAME).'b'handle'u'handle'b'Become owner of X selection. + + A keyword parameter selection specifies the name of + the selection (default PRIMARY).'u'Become owner of X selection. + + A keyword parameter selection specifies the name of + the selection (default PRIMARY).'b'own'u'own'b'Return owner of X selection. + + The following keyword parameter can + be provided: + selection - name of the selection (default PRIMARY), + type - type of the selection (e.g. STRING, FILE_NAME).'u'Return owner of X selection. + + The following keyword parameter can + be provided: + selection - name of the selection (default PRIMARY), + type - type of the selection (e.g. STRING, FILE_NAME).'b'Send Tcl command CMD to different interpreter INTERP to be executed.'u'Send Tcl command CMD to different interpreter INTERP to be executed.'b'send'u'send'b'Lower this widget in the stacking order.'u'Lower this widget in the stacking order.'b'lower'u'lower'b'Raise this widget in the stacking order.'u'Raise this widget in the stacking order.'b'raise'u'raise'b'Return integer which represents atom NAME.'u'Return integer which represents atom NAME.'b'winfo'u'winfo'b'atom'u'atom'b'Return name of atom with identifier ID.'u'Return name of atom with identifier ID.'b'atomname'u'atomname'b'Return number of cells in the colormap for this widget.'u'Return number of cells in the colormap for this widget.'b'cells'u'cells'b'Return a list of all widgets which are children of this widget.'u'Return a list of all widgets which are children of this widget.'b'children'u'children'b'Return window class name of this widget.'u'Return window class name of this widget.'b'class'u'class'b'Return True if at the last color request the colormap was full.'u'Return True if at the last color request the colormap was full.'b'colormapfull'u'colormapfull'b'Return the widget which is at the root coordinates ROOTX, ROOTY.'u'Return the widget which is at the root coordinates ROOTX, ROOTY.'b'containing'u'containing'b'Return the number of bits per pixel.'u'Return the number of bits per pixel.'b'depth'u'depth'b'Return true if this widget exists.'u'Return true if this widget exists.'b'Return the number of pixels for the given distance NUMBER + (e.g. "3c") as float.'u'Return the number of pixels for the given distance NUMBER + (e.g. "3c") as float.'b'fpixels'u'fpixels'b'Return geometry string for this widget in the form "widthxheight+X+Y".'u'Return geometry string for this widget in the form "widthxheight+X+Y".'b'geometry'u'geometry'b'Return height of this widget.'u'Return height of this widget.'b'Return identifier ID for this widget.'u'Return identifier ID for this widget.'b'Return the name of all Tcl interpreters for this display.'u'Return the name of all Tcl interpreters for this display.'b'interps'u'interps'b'Return true if this widget is mapped.'u'Return true if this widget is mapped.'b'ismapped'u'ismapped'b'Return the window manager name for this widget.'u'Return the window manager name for this widget.'b'manager'u'manager'b'Return the name of this widget.'u'Return the name of this widget.'b'Return the name of the parent of this widget.'u'Return the name of the parent of this widget.'b'parent'u'parent'b'Return the pathname of the widget given by ID.'u'Return the pathname of the widget given by ID.'b'pathname'u'pathname'b'Rounded integer value of winfo_fpixels.'u'Rounded integer value of winfo_fpixels.'b'pixels'u'pixels'b'Return the x coordinate of the pointer on the root window.'u'Return the x coordinate of the pointer on the root window.'b'pointerx'u'pointerx'b'Return a tuple of x and y coordinates of the pointer on the root window.'u'Return a tuple of x and y coordinates of the pointer on the root window.'b'pointerxy'u'pointerxy'b'Return the y coordinate of the pointer on the root window.'u'Return the y coordinate of the pointer on the root window.'b'pointery'u'pointery'b'Return requested height of this widget.'u'Return requested height of this widget.'b'reqheight'u'reqheight'b'Return requested width of this widget.'u'Return requested width of this widget.'b'reqwidth'u'reqwidth'b'Return a tuple of integer RGB values in range(65536) for color in this widget.'u'Return a tuple of integer RGB values in range(65536) for color in this widget.'b'rgb'u'rgb'b'Return x coordinate of upper left corner of this widget on the + root window.'u'Return x coordinate of upper left corner of this widget on the + root window.'b'rootx'u'rootx'b'Return y coordinate of upper left corner of this widget on the + root window.'u'Return y coordinate of upper left corner of this widget on the + root window.'b'rooty'u'rooty'b'Return the screen name of this widget.'u'Return the screen name of this widget.'b'screen'u'screen'b'Return the number of the cells in the colormap of the screen + of this widget.'u'Return the number of the cells in the colormap of the screen + of this widget.'b'screencells'u'screencells'b'Return the number of bits per pixel of the root window of the + screen of this widget.'u'Return the number of bits per pixel of the root window of the + screen of this widget.'b'screendepth'u'screendepth'b'Return the number of pixels of the height of the screen of this widget + in pixel.'u'Return the number of pixels of the height of the screen of this widget + in pixel.'b'screenheight'u'screenheight'b'Return the number of pixels of the height of the screen of + this widget in mm.'u'Return the number of pixels of the height of the screen of + this widget in mm.'b'screenmmheight'u'screenmmheight'b'Return the number of pixels of the width of the screen of + this widget in mm.'u'Return the number of pixels of the width of the screen of + this widget in mm.'b'screenmmwidth'u'screenmmwidth'b'Return one of the strings directcolor, grayscale, pseudocolor, + staticcolor, staticgray, or truecolor for the default + colormodel of this screen.'u'Return one of the strings directcolor, grayscale, pseudocolor, + staticcolor, staticgray, or truecolor for the default + colormodel of this screen.'b'screenvisual'u'screenvisual'b'Return the number of pixels of the width of the screen of + this widget in pixel.'u'Return the number of pixels of the width of the screen of + this widget in pixel.'b'screenwidth'u'screenwidth'b'Return information of the X-Server of the screen of this widget in + the form "XmajorRminor vendor vendorVersion".'u'Return information of the X-Server of the screen of this widget in + the form "XmajorRminor vendor vendorVersion".'b'server'u'server'b'Return the toplevel widget of this widget.'u'Return the toplevel widget of this widget.'b'toplevel'u'toplevel'b'Return true if the widget and all its higher ancestors are mapped.'u'Return true if the widget and all its higher ancestors are mapped.'b'viewable'u'viewable'b'Return one of the strings directcolor, grayscale, pseudocolor, + staticcolor, staticgray, or truecolor for the + colormodel of this widget.'u'Return one of the strings directcolor, grayscale, pseudocolor, + staticcolor, staticgray, or truecolor for the + colormodel of this widget.'b'visual'u'visual'b'Return the X identifier for the visual for this widget.'u'Return the X identifier for the visual for this widget.'b'visualid'u'visualid'b'Return a list of all visuals available for the screen + of this widget. + + Each item in the list consists of a visual name (see winfo_visual), a + depth and if includeids is true is given also the X identifier.'u'Return a list of all visuals available for the screen + of this widget. + + Each item in the list consists of a visual name (see winfo_visual), a + depth and if includeids is true is given also the X identifier.'b'visualsavailable'u'visualsavailable'b'includeids'u'includeids'b'Return the height of the virtual root window associated with this + widget in pixels. If there is no virtual root window return the + height of the screen.'u'Return the height of the virtual root window associated with this + widget in pixels. If there is no virtual root window return the + height of the screen.'b'vrootheight'u'vrootheight'b'Return the width of the virtual root window associated with this + widget in pixel. If there is no virtual root window return the + width of the screen.'u'Return the width of the virtual root window associated with this + widget in pixel. If there is no virtual root window return the + width of the screen.'b'vrootwidth'u'vrootwidth'b'Return the x offset of the virtual root relative to the root + window of the screen of this widget.'u'Return the x offset of the virtual root relative to the root + window of the screen of this widget.'b'vrootx'u'vrootx'b'Return the y offset of the virtual root relative to the root + window of the screen of this widget.'u'Return the y offset of the virtual root relative to the root + window of the screen of this widget.'b'vrooty'u'vrooty'b'Return the width of this widget.'u'Return the width of this widget.'b'Return the x coordinate of the upper left corner of this widget + in the parent.'u'Return the x coordinate of the upper left corner of this widget + in the parent.'b'Return the y coordinate of the upper left corner of this widget + in the parent.'u'Return the y coordinate of the upper left corner of this widget + in the parent.'b'Enter event loop until all pending events have been processed by Tcl.'u'Enter event loop until all pending events have been processed by Tcl.'b'update'u'update'b'Enter event loop until all idle callbacks have been called. This + will update the display of windows but not process events caused by + the user.'u'Enter event loop until all idle callbacks have been called. This + will update the display of windows but not process events caused by + the user.'b'idletasks'u'idletasks'b'Set or get the list of bindtags for this widget. + + With no argument return the list of all bindtags associated with + this widget. With a list of strings as argument the bindtags are + set to this list. The bindtags determine in which order events are + processed (see bind).'u'Set or get the list of bindtags for this widget. + + With no argument return the list of all bindtags associated with + this widget. With a list of strings as argument the bindtags are + set to this list. The bindtags determine in which order events are + processed (see bind).'b'bindtags'u'bindtags'b'%sif {"[%s %s]" == "break"} break +'u'%sif {"[%s %s]" == "break"} break +'b'+'u'+'b'Bind to this widget at event SEQUENCE a call to function FUNC. + + SEQUENCE is a string of concatenated event + patterns. An event pattern is of the form + where MODIFIER is one + of Control, Mod2, M2, Shift, Mod3, M3, Lock, Mod4, M4, + Button1, B1, Mod5, M5 Button2, B2, Meta, M, Button3, + B3, Alt, Button4, B4, Double, Button5, B5 Triple, + Mod1, M1. TYPE is one of Activate, Enter, Map, + ButtonPress, Button, Expose, Motion, ButtonRelease + FocusIn, MouseWheel, Circulate, FocusOut, Property, + Colormap, Gravity Reparent, Configure, KeyPress, Key, + Unmap, Deactivate, KeyRelease Visibility, Destroy, + Leave and DETAIL is the button number for ButtonPress, + ButtonRelease and DETAIL is the Keysym for KeyPress and + KeyRelease. Examples are + for pressing Control and mouse button 1 or + for pressing A and the Alt key (KeyPress can be omitted). + An event pattern can also be a virtual event of the form + <> where AString can be arbitrary. This + event can be generated by event_generate. + If events are concatenated they must appear shortly + after each other. + + FUNC will be called if the event sequence occurs with an + instance of Event as argument. If the return value of FUNC is + "break" no further bound function is invoked. + + An additional boolean parameter ADD specifies whether FUNC will + be called additionally to the other bound function or whether + it will replace the previous function. + + Bind will return an identifier to allow deletion of the bound function with + unbind without memory leak. + + If FUNC or SEQUENCE is omitted the bound function or list + of bound events are returned.'u'Bind to this widget at event SEQUENCE a call to function FUNC. + + SEQUENCE is a string of concatenated event + patterns. An event pattern is of the form + where MODIFIER is one + of Control, Mod2, M2, Shift, Mod3, M3, Lock, Mod4, M4, + Button1, B1, Mod5, M5 Button2, B2, Meta, M, Button3, + B3, Alt, Button4, B4, Double, Button5, B5 Triple, + Mod1, M1. TYPE is one of Activate, Enter, Map, + ButtonPress, Button, Expose, Motion, ButtonRelease + FocusIn, MouseWheel, Circulate, FocusOut, Property, + Colormap, Gravity Reparent, Configure, KeyPress, Key, + Unmap, Deactivate, KeyRelease Visibility, Destroy, + Leave and DETAIL is the button number for ButtonPress, + ButtonRelease and DETAIL is the Keysym for KeyPress and + KeyRelease. Examples are + for pressing Control and mouse button 1 or + for pressing A and the Alt key (KeyPress can be omitted). + An event pattern can also be a virtual event of the form + <> where AString can be arbitrary. This + event can be generated by event_generate. + If events are concatenated they must appear shortly + after each other. + + FUNC will be called if the event sequence occurs with an + instance of Event as argument. If the return value of FUNC is + "break" no further bound function is invoked. + + An additional boolean parameter ADD specifies whether FUNC will + be called additionally to the other bound function or whether + it will replace the previous function. + + Bind will return an identifier to allow deletion of the bound function with + unbind without memory leak. + + If FUNC or SEQUENCE is omitted the bound function or list + of bound events are returned.'b'bind'u'bind'b'Unbind for this widget for event SEQUENCE the + function identified with FUNCID.'u'Unbind for this widget for event SEQUENCE the + function identified with FUNCID.'b'Bind to all widgets at an event SEQUENCE a call to function FUNC. + An additional boolean parameter ADD specifies whether FUNC will + be called additionally to the other bound function or whether + it will replace the previous function. See bind for the return value.'u'Bind to all widgets at an event SEQUENCE a call to function FUNC. + An additional boolean parameter ADD specifies whether FUNC will + be called additionally to the other bound function or whether + it will replace the previous function. See bind for the return value.'b'all'b'Unbind for all widgets for event SEQUENCE all functions.'u'Unbind for all widgets for event SEQUENCE all functions.'b'Bind to widgets with bindtag CLASSNAME at event + SEQUENCE a call of function FUNC. An additional + boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or + whether it will replace the previous function. See bind for + the return value.'u'Bind to widgets with bindtag CLASSNAME at event + SEQUENCE a call of function FUNC. An additional + boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or + whether it will replace the previous function. See bind for + the return value.'b'Unbind for all widgets with bindtag CLASSNAME for event SEQUENCE + all functions.'u'Unbind for all widgets with bindtag CLASSNAME for event SEQUENCE + all functions.'b'Call the mainloop of Tk.'u'Call the mainloop of Tk.'b'Quit the Tcl interpreter. All widgets will be destroyed.'u'Quit the Tcl interpreter. All widgets will be destroyed.'b'tk'u'tk'b'windowingsystem'u'windowingsystem'b'Return the Tkinter instance of a widget identified by + its Tcl name NAME.'u'Return the Tkinter instance of a widget identified by + its Tcl name NAME.'b'Return a newly created Tcl function. If this + function is called, the Python function FUNC will + be executed. An optional function SUBST can + be given which will be executed before FUNC.'u'Return a newly created Tcl function. If this + function is called, the Python function FUNC will + be executed. An optional function SUBST can + be given which will be executed before FUNC.'b'%#'u'%#'b'%b'u'%b'b'%f'u'%f'b'%h'u'%h'b'%k'u'%k'b'%s'u'%s'b'%t'u'%t'b'%w'u'%w'b'%x'u'%x'b'%y'u'%y'b'%A'u'%A'b'%E'u'%E'b'%K'u'%K'b'%N'u'%N'b'%W'u'%W'b'%T'u'%T'b'%X'u'%X'b'%Y'u'%Y'b'%D'u'%D'b'Tk changed behavior in 8.4.2, returning "??" rather more often.'u'Tk changed behavior in 8.4.2, returning "??" rather more often.'b'Call Tcl configure command and return the result as a dict.'u'Call Tcl configure command and return the result as a dict.'b'Configure resources of a widget. + + The values for resources are specified as keyword + arguments. To get an overview about + the allowed keyword arguments call the method keys. + 'u'Configure resources of a widget. + + The values for resources are specified as keyword + arguments. To get an overview about + the allowed keyword arguments call the method keys. + 'b'configure'u'configure'b'Return the resource value for a KEY given as string.'u'Return the resource value for a KEY given as string.'b'cget'u'cget'b'Return a list of all resource names of this widget.'u'Return a list of all resource names of this widget.'b'Return the window path name of this widget.'u'Return the window path name of this widget.'b'<%s.%s object %s>'u'<%s.%s object %s>'b'_noarg_'u'_noarg_'b'Set or get the status for propagation of geometry information. + + A boolean argument specifies whether the geometry information + of the slaves will determine the size of this widget. If no argument + is given the current setting will be returned. + 'u'Set or get the status for propagation of geometry information. + + A boolean argument specifies whether the geometry information + of the slaves will determine the size of this widget. If no argument + is given the current setting will be returned. + 'b'pack'u'pack'b'propagate'u'propagate'b'Return a list of all slaves of this widget + in its packing order.'u'Return a list of all slaves of this widget + in its packing order.'b'slaves'u'slaves'b'place'u'place'b'The anchor value controls how to place the grid within the + master when no row/column has any weight. + + The default anchor is nw.'u'The anchor value controls how to place the grid within the + master when no row/column has any weight. + + The default anchor is nw.'b'grid'u'grid'b'anchor'u'anchor'b'Return a tuple of integer coordinates for the bounding + box of this widget controlled by the geometry manager grid. + + If COLUMN, ROW is given the bounding box applies from + the cell with row and column 0 to the specified + cell. If COL2 and ROW2 are given the bounding box + starts at that cell. + + The returned integers specify the offset of the upper left + corner in the master widget and the width and height. + 'u'Return a tuple of integer coordinates for the bounding + box of this widget controlled by the geometry manager grid. + + If COLUMN, ROW is given the bounding box applies from + the cell with row and column 0 to the specified + cell. If COL2 and ROW2 are given the bounding box + starts at that cell. + + The returned integers specify the offset of the upper left + corner in the master widget and the width and height. + 'b'bbox'u'bbox'b'Configure column INDEX of a grid. + + Valid resources are minsize (minimum size of the column), + weight (how much does additional space propagate to this column) + and pad (how much space to let additionally).'u'Configure column INDEX of a grid. + + Valid resources are minsize (minimum size of the column), + weight (how much does additional space propagate to this column) + and pad (how much space to let additionally).'b'columnconfigure'u'columnconfigure'b'Return a tuple of column and row which identify the cell + at which the pixel at position X and Y inside the master + widget is located.'u'Return a tuple of column and row which identify the cell + at which the pixel at position X and Y inside the master + widget is located.'b'location'u'location'b'Set or get the status for propagation of geometry information. + + A boolean argument specifies whether the geometry information + of the slaves will determine the size of this widget. If no argument + is given, the current setting will be returned. + 'u'Set or get the status for propagation of geometry information. + + A boolean argument specifies whether the geometry information + of the slaves will determine the size of this widget. If no argument + is given, the current setting will be returned. + 'b'Configure row INDEX of a grid. + + Valid resources are minsize (minimum size of the row), + weight (how much does additional space propagate to this row) + and pad (how much space to let additionally).'u'Configure row INDEX of a grid. + + Valid resources are minsize (minimum size of the row), + weight (how much does additional space propagate to this row) + and pad (how much space to let additionally).'b'rowconfigure'u'rowconfigure'b'Return a tuple of the number of column and rows in the grid.'u'Return a tuple of the number of column and rows in the grid.'b'size'u'size'b'-row'u'-row'b'-column'u'-column'b'Bind a virtual event VIRTUAL (of the form <>) + to an event SEQUENCE such that the virtual event is triggered + whenever SEQUENCE occurs.'u'Bind a virtual event VIRTUAL (of the form <>) + to an event SEQUENCE such that the virtual event is triggered + whenever SEQUENCE occurs.'b'event'u'event'b'Unbind a virtual event VIRTUAL from SEQUENCE.'u'Unbind a virtual event VIRTUAL from SEQUENCE.'b'delete'u'delete'b'Generate an event SEQUENCE. Additional + keyword arguments specify parameter of the event + (e.g. x, y, rootx, rooty).'u'Generate an event SEQUENCE. Additional + keyword arguments specify parameter of the event + (e.g. x, y, rootx, rooty).'b'generate'u'generate'b'-%s'u'-%s'b'Return a list of all virtual events or the information + about the SEQUENCE bound to the virtual event VIRTUAL.'u'Return a list of all virtual events or the information + about the SEQUENCE bound to the virtual event VIRTUAL.'b'Return a list of all existing image names.'u'Return a list of all existing image names.'b'image'u'image'b'names'u'names'b'Return a list of all available image types (e.g. photo bitmap).'u'Return a list of all available image types (e.g. photo bitmap).'b'types'u'types'b'Internal class. Stores function to call when some user + defined Tcl function is called e.g. after an event occurred.'u'Internal class. Stores function to call when some user + defined Tcl function is called e.g. after an event occurred.'b'Store FUNC, SUBST and WIDGET as members.'u'Store FUNC, SUBST and WIDGET as members.'b'Apply first function SUBST to arguments, than FUNC.'u'Apply first function SUBST to arguments, than FUNC.'b'Mix-in class for querying and changing the horizontal position + of a widget's window.'u'Mix-in class for querying and changing the horizontal position + of a widget's window.'b'Query and change the horizontal position of the view.'u'Query and change the horizontal position of the view.'b'xview'u'xview'b'Adjusts the view in the window so that FRACTION of the + total width of the canvas is off-screen to the left.'u'Adjusts the view in the window so that FRACTION of the + total width of the canvas is off-screen to the left.'b'moveto'u'moveto'b'Shift the x-view according to NUMBER which is measured in "units" + or "pages" (WHAT).'u'Shift the x-view according to NUMBER which is measured in "units" + or "pages" (WHAT).'b'scroll'u'scroll'b'Mix-in class for querying and changing the vertical position + of a widget's window.'u'Mix-in class for querying and changing the vertical position + of a widget's window.'b'Query and change the vertical position of the view.'u'Query and change the vertical position of the view.'b'yview'u'yview'b'Adjusts the view in the window so that FRACTION of the + total height of the canvas is off-screen to the top.'u'Adjusts the view in the window so that FRACTION of the + total height of the canvas is off-screen to the top.'b'Shift the y-view according to NUMBER which is measured in + "units" or "pages" (WHAT).'u'Shift the y-view according to NUMBER which is measured in + "units" or "pages" (WHAT).'b'Provides functions for the communication with the window manager.'u'Provides functions for the communication with the window manager.'b'Instruct the window manager to set the aspect ratio (width/height) + of this widget to be between MINNUMER/MINDENOM and MAXNUMER/MAXDENOM. Return a tuple + of the actual values if no argument is given.'u'Instruct the window manager to set the aspect ratio (width/height) + of this widget to be between MINNUMER/MINDENOM and MAXNUMER/MAXDENOM. Return a tuple + of the actual values if no argument is given.'b'wm'u'wm'b'aspect'u'aspect'b'This subcommand returns or sets platform specific attributes + + The first form returns a list of the platform specific flags and + their values. The second form returns the value for the specific + option. The third form sets one or more of the values. The values + are as follows: + + On Windows, -disabled gets or sets whether the window is in a + disabled state. -toolwindow gets or sets the style of the window + to toolwindow (as defined in the MSDN). -topmost gets or sets + whether this is a topmost window (displays above all other + windows). + + On Macintosh, XXXXX + + On Unix, there are currently no special attribute values. + 'u'This subcommand returns or sets platform specific attributes + + The first form returns a list of the platform specific flags and + their values. The second form returns the value for the specific + option. The third form sets one or more of the values. The values + are as follows: + + On Windows, -disabled gets or sets whether the window is in a + disabled state. -toolwindow gets or sets the style of the window + to toolwindow (as defined in the MSDN). -topmost gets or sets + whether this is a topmost window (displays above all other + windows). + + On Macintosh, XXXXX + + On Unix, there are currently no special attribute values. + 'b'attributes'u'attributes'b'Store NAME in WM_CLIENT_MACHINE property of this widget. Return + current value.'u'Store NAME in WM_CLIENT_MACHINE property of this widget. Return + current value.'b'client'u'client'b'Store list of window names (WLIST) into WM_COLORMAPWINDOWS property + of this widget. This list contains windows whose colormaps differ from their + parents. Return current list of widgets if WLIST is empty.'u'Store list of window names (WLIST) into WM_COLORMAPWINDOWS property + of this widget. This list contains windows whose colormaps differ from their + parents. Return current list of widgets if WLIST is empty.'b'colormapwindows'u'colormapwindows'b'Store VALUE in WM_COMMAND property. It is the command + which shall be used to invoke the application. Return current + command if VALUE is None.'u'Store VALUE in WM_COMMAND property. It is the command + which shall be used to invoke the application. Return current + command if VALUE is None.'b'command'u'command'b'Deiconify this widget. If it was never mapped it will not be mapped. + On Windows it will raise this widget and give it the focus.'u'Deiconify this widget. If it was never mapped it will not be mapped. + On Windows it will raise this widget and give it the focus.'b'deiconify'u'deiconify'b'Set focus model to MODEL. "active" means that this widget will claim + the focus itself, "passive" means that the window manager shall give + the focus. Return current focus model if MODEL is None.'u'Set focus model to MODEL. "active" means that this widget will claim + the focus itself, "passive" means that the window manager shall give + the focus. Return current focus model if MODEL is None.'b'focusmodel'u'focusmodel'b'The window will be unmapped from the screen and will no longer + be managed by wm. toplevel windows will be treated like frame + windows once they are no longer managed by wm, however, the menu + option configuration will be remembered and the menus will return + once the widget is managed again.'u'The window will be unmapped from the screen and will no longer + be managed by wm. toplevel windows will be treated like frame + windows once they are no longer managed by wm, however, the menu + option configuration will be remembered and the menus will return + once the widget is managed again.'b'forget'u'forget'b'Return identifier for decorative frame of this widget if present.'u'Return identifier for decorative frame of this widget if present.'b'Set geometry to NEWGEOMETRY of the form =widthxheight+x+y. Return + current value if None is given.'u'Set geometry to NEWGEOMETRY of the form =widthxheight+x+y. Return + current value if None is given.'b'Instruct the window manager that this widget shall only be + resized on grid boundaries. WIDTHINC and HEIGHTINC are the width and + height of a grid unit in pixels. BASEWIDTH and BASEHEIGHT are the + number of grid units requested in Tk_GeometryRequest.'u'Instruct the window manager that this widget shall only be + resized on grid boundaries. WIDTHINC and HEIGHTINC are the width and + height of a grid unit in pixels. BASEWIDTH and BASEHEIGHT are the + number of grid units requested in Tk_GeometryRequest.'b'Set the group leader widgets for related widgets to PATHNAME. Return + the group leader of this widget if None is given.'u'Set the group leader widgets for related widgets to PATHNAME. Return + the group leader of this widget if None is given.'b'group'u'group'b'Set bitmap for the iconified widget to BITMAP. Return + the bitmap if None is given. + + Under Windows, the DEFAULT parameter can be used to set the icon + for the widget and any descendents that don't have an icon set + explicitly. DEFAULT can be the relative path to a .ico file + (example: root.iconbitmap(default='myicon.ico') ). See Tk + documentation for more information.'u'Set bitmap for the iconified widget to BITMAP. Return + the bitmap if None is given. + + Under Windows, the DEFAULT parameter can be used to set the icon + for the widget and any descendents that don't have an icon set + explicitly. DEFAULT can be the relative path to a .ico file + (example: root.iconbitmap(default='myicon.ico') ). See Tk + documentation for more information.'b'iconbitmap'u'iconbitmap'b'-default'u'-default'b'Display widget as icon.'u'Display widget as icon.'b'iconify'u'iconify'b'Set mask for the icon bitmap of this widget. Return the + mask if None is given.'u'Set mask for the icon bitmap of this widget. Return the + mask if None is given.'b'iconmask'u'iconmask'b'Set the name of the icon for this widget. Return the name if + None is given.'u'Set the name of the icon for this widget. Return the name if + None is given.'b'iconname'u'iconname'b'Sets the titlebar icon for this window based on the named photo + images passed through args. If default is True, this is applied to + all future created toplevels as well. + + The data in the images is taken as a snapshot at the time of + invocation. If the images are later changed, this is not reflected + to the titlebar icons. Multiple images are accepted to allow + different images sizes to be provided. The window manager may scale + provided icons to an appropriate size. + + On Windows, the images are packed into a Windows icon structure. + This will override an icon specified to wm_iconbitmap, and vice + versa. + + On X, the images are arranged into the _NET_WM_ICON X property, + which most modern window managers support. An icon specified by + wm_iconbitmap may exist simultaneously. + + On Macintosh, this currently does nothing.'u'Sets the titlebar icon for this window based on the named photo + images passed through args. If default is True, this is applied to + all future created toplevels as well. + + The data in the images is taken as a snapshot at the time of + invocation. If the images are later changed, this is not reflected + to the titlebar icons. Multiple images are accepted to allow + different images sizes to be provided. The window manager may scale + provided icons to an appropriate size. + + On Windows, the images are packed into a Windows icon structure. + This will override an icon specified to wm_iconbitmap, and vice + versa. + + On X, the images are arranged into the _NET_WM_ICON X property, + which most modern window managers support. An icon specified by + wm_iconbitmap may exist simultaneously. + + On Macintosh, this currently does nothing.'b'iconphoto'u'iconphoto'b'Set the position of the icon of this widget to X and Y. Return + a tuple of the current values of X and X if None is given.'u'Set the position of the icon of this widget to X and Y. Return + a tuple of the current values of X and X if None is given.'b'iconposition'u'iconposition'b'Set widget PATHNAME to be displayed instead of icon. Return the current + value if None is given.'u'Set widget PATHNAME to be displayed instead of icon. Return the current + value if None is given.'b'iconwindow'u'iconwindow'b'The widget specified will become a stand alone top-level window. + The window will be decorated with the window managers title bar, + etc.'u'The widget specified will become a stand alone top-level window. + The window will be decorated with the window managers title bar, + etc.'b'manage'u'manage'b'Set max WIDTH and HEIGHT for this widget. If the window is gridded + the values are given in grid units. Return the current values if None + is given.'u'Set max WIDTH and HEIGHT for this widget. If the window is gridded + the values are given in grid units. Return the current values if None + is given.'b'maxsize'u'maxsize'b'Set min WIDTH and HEIGHT for this widget. If the window is gridded + the values are given in grid units. Return the current values if None + is given.'u'Set min WIDTH and HEIGHT for this widget. If the window is gridded + the values are given in grid units. Return the current values if None + is given.'b'minsize'u'minsize'b'Instruct the window manager to ignore this widget + if BOOLEAN is given with 1. Return the current value if None + is given.'u'Instruct the window manager to ignore this widget + if BOOLEAN is given with 1. Return the current value if None + is given.'b'overrideredirect'u'overrideredirect'b'Instruct the window manager that the position of this widget shall + be defined by the user if WHO is "user", and by its own policy if WHO is + "program".'u'Instruct the window manager that the position of this widget shall + be defined by the user if WHO is "user", and by its own policy if WHO is + "program".'b'positionfrom'u'positionfrom'b'Bind function FUNC to command NAME for this widget. + Return the function bound to NAME if None is given. NAME could be + e.g. "WM_SAVE_YOURSELF" or "WM_DELETE_WINDOW".'u'Bind function FUNC to command NAME for this widget. + Return the function bound to NAME if None is given. NAME could be + e.g. "WM_SAVE_YOURSELF" or "WM_DELETE_WINDOW".'b'protocol'u'protocol'b'Instruct the window manager whether this width can be resized + in WIDTH or HEIGHT. Both values are boolean values.'u'Instruct the window manager whether this width can be resized + in WIDTH or HEIGHT. Both values are boolean values.'b'resizable'u'resizable'b'Instruct the window manager that the size of this widget shall + be defined by the user if WHO is "user", and by its own policy if WHO is + "program".'u'Instruct the window manager that the size of this widget shall + be defined by the user if WHO is "user", and by its own policy if WHO is + "program".'b'sizefrom'u'sizefrom'b'Query or set the state of this widget as one of normal, icon, + iconic (see wm_iconwindow), withdrawn, or zoomed (Windows only).'u'Query or set the state of this widget as one of normal, icon, + iconic (see wm_iconwindow), withdrawn, or zoomed (Windows only).'b'Set the title of this widget.'u'Set the title of this widget.'b'title'u'title'b'Instruct the window manager that this widget is transient + with regard to widget MASTER.'u'Instruct the window manager that this widget is transient + with regard to widget MASTER.'b'transient'u'transient'b'Withdraw this widget from the screen such that it is unmapped + and forgotten by the window manager. Re-draw it with wm_deiconify.'u'Withdraw this widget from the screen such that it is unmapped + and forgotten by the window manager. Re-draw it with wm_deiconify.'b'withdraw'u'withdraw'b'Toplevel widget of Tk which represents mostly the main window + of an application. It has an associated Tcl interpreter.'u'Toplevel widget of Tk which represents mostly the main window + of an application. It has an associated Tcl interpreter.'b'Tk'u'Tk'b'Return a new Toplevel widget on screen SCREENNAME. A new Tcl interpreter will + be created. BASENAME will be used for the identification of the profile file (see + readprofile). + It is constructed from sys.argv[0] without extensions if None is given. CLASSNAME + is the name of the widget class.'u'Return a new Toplevel widget on screen SCREENNAME. A new Tcl interpreter will + be created. BASENAME will be used for the identification of the profile file (see + readprofile). + It is constructed from sys.argv[0] without extensions if None is given. CLASSNAME + is the name of the widget class.'b'.py'u'.py'b'.pyc'u'.pyc'b'tk_version'u'tk_version'b'tk.h version (%s) doesn't match libtk.a version (%s)'u'tk.h version (%s) doesn't match libtk.a version (%s)'b'tcl_version'u'tcl_version'b'tcl.h version (%s) doesn't match libtcl.a version (%s)'u'tcl.h version (%s) doesn't match libtcl.a version (%s)'b'tkerror'u'tkerror'b'exit'u'exit'b'WM_DELETE_WINDOW'u'WM_DELETE_WINDOW'b'Destroy this and all descendants widgets. This will + end the application of this Tcl interpreter.'u'Destroy this and all descendants widgets. This will + end the application of this Tcl interpreter.'b'destroy'u'destroy'b'Internal function. It reads BASENAME.tcl and CLASSNAME.tcl into + the Tcl Interpreter and calls exec on the contents of BASENAME.py and + CLASSNAME.py if such a file exists in the home directory.'u'Internal function. It reads BASENAME.tcl and CLASSNAME.tcl into + the Tcl Interpreter and calls exec on the contents of BASENAME.py and + CLASSNAME.py if such a file exists in the home directory.'b'HOME'u'HOME'b'.%s.tcl'u'.%s.tcl'b'.%s.py'u'.%s.py'b'self'u'self'b'from tkinter import *'u'from tkinter import *'b'source'u'source'b'Report callback exception on sys.stderr. + + Applications may want to override this internal function, and + should when sys.stderr is None.'u'Report callback exception on sys.stderr. + + Applications may want to override this internal function, and + should when sys.stderr is None.'b'Exception in Tkinter callback'u'Exception in Tkinter callback'b'Delegate attribute access to the interpreter object'u'Delegate attribute access to the interpreter object'b'Geometry manager Pack. + + Base class to use the methods pack_* in every widget.'u'Geometry manager Pack. + + Base class to use the methods pack_* in every widget.'b'Pack a widget in the parent widget. Use as options: + after=widget - pack it after you have packed widget + anchor=NSEW (or subset) - position widget according to + given direction + before=widget - pack it before you will pack widget + expand=bool - expand widget if parent size grows + fill=NONE or X or Y or BOTH - fill widget if widget grows + in=master - use master to contain this widget + in_=master - see 'in' option description + ipadx=amount - add internal padding in x direction + ipady=amount - add internal padding in y direction + padx=amount - add padding in x direction + pady=amount - add padding in y direction + side=TOP or BOTTOM or LEFT or RIGHT - where to add this widget. + 'u'Pack a widget in the parent widget. Use as options: + after=widget - pack it after you have packed widget + anchor=NSEW (or subset) - position widget according to + given direction + before=widget - pack it before you will pack widget + expand=bool - expand widget if parent size grows + fill=NONE or X or Y or BOTH - fill widget if widget grows + in=master - use master to contain this widget + in_=master - see 'in' option description + ipadx=amount - add internal padding in x direction + ipady=amount - add internal padding in y direction + padx=amount - add padding in x direction + pady=amount - add padding in y direction + side=TOP or BOTTOM or LEFT or RIGHT - where to add this widget. + 'b'Unmap this widget and do not use it for the packing order.'u'Unmap this widget and do not use it for the packing order.'b'Return information about the packing options + for this widget.'u'Return information about the packing options + for this widget.'b'in'u'in'b'Geometry manager Place. + + Base class to use the methods place_* in every widget.'u'Geometry manager Place. + + Base class to use the methods place_* in every widget.'b'Place a widget in the parent widget. Use as options: + in=master - master relative to which the widget is placed + in_=master - see 'in' option description + x=amount - locate anchor of this widget at position x of master + y=amount - locate anchor of this widget at position y of master + relx=amount - locate anchor of this widget between 0.0 and 1.0 + relative to width of master (1.0 is right edge) + rely=amount - locate anchor of this widget between 0.0 and 1.0 + relative to height of master (1.0 is bottom edge) + anchor=NSEW (or subset) - position anchor according to given direction + width=amount - width of this widget in pixel + height=amount - height of this widget in pixel + relwidth=amount - width of this widget between 0.0 and 1.0 + relative to width of master (1.0 is the same width + as the master) + relheight=amount - height of this widget between 0.0 and 1.0 + relative to height of master (1.0 is the same + height as the master) + bordermode="inside" or "outside" - whether to take border width of + master widget into account + 'u'Place a widget in the parent widget. Use as options: + in=master - master relative to which the widget is placed + in_=master - see 'in' option description + x=amount - locate anchor of this widget at position x of master + y=amount - locate anchor of this widget at position y of master + relx=amount - locate anchor of this widget between 0.0 and 1.0 + relative to width of master (1.0 is right edge) + rely=amount - locate anchor of this widget between 0.0 and 1.0 + relative to height of master (1.0 is bottom edge) + anchor=NSEW (or subset) - position anchor according to given direction + width=amount - width of this widget in pixel + height=amount - height of this widget in pixel + relwidth=amount - width of this widget between 0.0 and 1.0 + relative to width of master (1.0 is the same width + as the master) + relheight=amount - height of this widget between 0.0 and 1.0 + relative to height of master (1.0 is the same + height as the master) + bordermode="inside" or "outside" - whether to take border width of + master widget into account + 'b'Unmap this widget.'u'Unmap this widget.'b'Return information about the placing options + for this widget.'u'Return information about the placing options + for this widget.'b'Geometry manager Grid. + + Base class to use the methods grid_* in every widget.'u'Geometry manager Grid. + + Base class to use the methods grid_* in every widget.'b'Position a widget in the parent widget in a grid. Use as options: + column=number - use cell identified with given column (starting with 0) + columnspan=number - this widget will span several columns + in=master - use master to contain this widget + in_=master - see 'in' option description + ipadx=amount - add internal padding in x direction + ipady=amount - add internal padding in y direction + padx=amount - add padding in x direction + pady=amount - add padding in y direction + row=number - use cell identified with given row (starting with 0) + rowspan=number - this widget will span several rows + sticky=NSEW - if cell is larger on which sides will this + widget stick to the cell boundary + 'u'Position a widget in the parent widget in a grid. Use as options: + column=number - use cell identified with given column (starting with 0) + columnspan=number - this widget will span several columns + in=master - use master to contain this widget + in_=master - see 'in' option description + ipadx=amount - add internal padding in x direction + ipady=amount - add internal padding in y direction + padx=amount - add padding in x direction + pady=amount - add padding in y direction + row=number - use cell identified with given row (starting with 0) + rowspan=number - this widget will span several rows + sticky=NSEW - if cell is larger on which sides will this + widget stick to the cell boundary + 'b'Unmap this widget but remember the grid options.'u'Unmap this widget but remember the grid options.'b'Return information about the options + for positioning this widget in a grid.'u'Return information about the options + for positioning this widget in a grid.'b'Internal class.'u'Internal class.'b'Internal function. Sets up information about children.'u'Internal function. Sets up information about children.'b'!%s'u'!%s'b'!%s%d'u'!%s%d'b'Construct a widget with the parent widget MASTER, a name WIDGETNAME + and appropriate options.'u'Construct a widget with the parent widget MASTER, a name WIDGETNAME + and appropriate options.'b'Destroy this and all descendants widgets.'u'Destroy this and all descendants widgets.'b'Internal class. + + Base class for a widget which can be positioned with the geometry managers + Pack, Place or Grid.'u'Internal class. + + Base class for a widget which can be positioned with the geometry managers + Pack, Place or Grid.'b'Toplevel widget, e.g. for dialogs.'u'Toplevel widget, e.g. for dialogs.'b'Construct a toplevel widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, class, + colormap, container, cursor, height, highlightbackground, + highlightcolor, highlightthickness, menu, relief, screen, takefocus, + use, visual, width.'u'Construct a toplevel widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, class, + colormap, container, cursor, height, highlightbackground, + highlightcolor, highlightthickness, menu, relief, screen, takefocus, + use, visual, width.'b'class_'u'class_'b'colormap'u'colormap'b'Button widget.'u'Button widget.'b'Construct a button widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, activeforeground, anchor, + background, bitmap, borderwidth, cursor, + disabledforeground, font, foreground + highlightbackground, highlightcolor, + highlightthickness, image, justify, + padx, pady, relief, repeatdelay, + repeatinterval, takefocus, text, + textvariable, underline, wraplength + + WIDGET-SPECIFIC OPTIONS + + command, compound, default, height, + overrelief, state, width + 'u'Construct a button widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, activeforeground, anchor, + background, bitmap, borderwidth, cursor, + disabledforeground, font, foreground + highlightbackground, highlightcolor, + highlightthickness, image, justify, + padx, pady, relief, repeatdelay, + repeatinterval, takefocus, text, + textvariable, underline, wraplength + + WIDGET-SPECIFIC OPTIONS + + command, compound, default, height, + overrelief, state, width + 'b'button'u'button'b'Flash the button. + + This is accomplished by redisplaying + the button several times, alternating between active and + normal colors. At the end of the flash the button is left + in the same normal/active state as when the command was + invoked. This command is ignored if the button's state is + disabled. + 'u'Flash the button. + + This is accomplished by redisplaying + the button several times, alternating between active and + normal colors. At the end of the flash the button is left + in the same normal/active state as when the command was + invoked. This command is ignored if the button's state is + disabled. + 'b'flash'u'flash'b'Invoke the command associated with the button. + + The return value is the return value from the command, + or an empty string if there is no command associated with + the button. This command is ignored if the button's state + is disabled. + 'u'Invoke the command associated with the button. + + The return value is the return value from the command, + or an empty string if there is no command associated with + the button. This command is ignored if the button's state + is disabled. + 'b'invoke'u'invoke'b'Canvas widget to display graphical elements like lines or text.'u'Canvas widget to display graphical elements like lines or text.'b'Construct a canvas widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, closeenough, + confine, cursor, height, highlightbackground, highlightcolor, + highlightthickness, insertbackground, insertborderwidth, + insertofftime, insertontime, insertwidth, offset, relief, + scrollregion, selectbackground, selectborderwidth, selectforeground, + state, takefocus, width, xscrollcommand, xscrollincrement, + yscrollcommand, yscrollincrement.'u'Construct a canvas widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, closeenough, + confine, cursor, height, highlightbackground, highlightcolor, + highlightthickness, insertbackground, insertborderwidth, + insertofftime, insertontime, insertwidth, offset, relief, + scrollregion, selectbackground, selectborderwidth, selectforeground, + state, takefocus, width, xscrollcommand, xscrollincrement, + yscrollcommand, yscrollincrement.'b'canvas'u'canvas'b'addtag'u'addtag'b'Add tag NEWTAG to all items above TAGORID.'u'Add tag NEWTAG to all items above TAGORID.'b'above'u'above'b'Add tag NEWTAG to all items.'u'Add tag NEWTAG to all items.'b'Add tag NEWTAG to all items below TAGORID.'u'Add tag NEWTAG to all items below TAGORID.'b'below'u'below'b'Add tag NEWTAG to item which is closest to pixel at X, Y. + If several match take the top-most. + All items closer than HALO are considered overlapping (all are + closests). If START is specified the next below this tag is taken.'u'Add tag NEWTAG to item which is closest to pixel at X, Y. + If several match take the top-most. + All items closer than HALO are considered overlapping (all are + closests). If START is specified the next below this tag is taken.'b'closest'u'closest'b'Add tag NEWTAG to all items in the rectangle defined + by X1,Y1,X2,Y2.'u'Add tag NEWTAG to all items in the rectangle defined + by X1,Y1,X2,Y2.'b'enclosed'u'enclosed'b'Add tag NEWTAG to all items which overlap the rectangle + defined by X1,Y1,X2,Y2.'u'Add tag NEWTAG to all items which overlap the rectangle + defined by X1,Y1,X2,Y2.'b'overlapping'u'overlapping'b'Add tag NEWTAG to all items with TAGORID.'u'Add tag NEWTAG to all items with TAGORID.'b'withtag'u'withtag'b'Return a tuple of X1,Y1,X2,Y2 coordinates for a rectangle + which encloses all items with tags specified as arguments.'u'Return a tuple of X1,Y1,X2,Y2 coordinates for a rectangle + which encloses all items with tags specified as arguments.'b'Unbind for all items with TAGORID for event SEQUENCE the + function identified with FUNCID.'u'Unbind for all items with TAGORID for event SEQUENCE the + function identified with FUNCID.'b'Bind to all items with TAGORID at event SEQUENCE a call to function FUNC. + + An additional boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or whether it will + replace the previous function. See bind for the return value.'u'Bind to all items with TAGORID at event SEQUENCE a call to function FUNC. + + An additional boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or whether it will + replace the previous function. See bind for the return value.'b'Return the canvas x coordinate of pixel position SCREENX rounded + to nearest multiple of GRIDSPACING units.'u'Return the canvas x coordinate of pixel position SCREENX rounded + to nearest multiple of GRIDSPACING units.'b'canvasx'u'canvasx'b'Return the canvas y coordinate of pixel position SCREENY rounded + to nearest multiple of GRIDSPACING units.'u'Return the canvas y coordinate of pixel position SCREENY rounded + to nearest multiple of GRIDSPACING units.'b'canvasy'u'canvasy'b'Return a list of coordinates for the item given in ARGS.'u'Return a list of coordinates for the item given in ARGS.'b'coords'u'coords'b'create'u'create'b'Create arc shaped region with coordinates x1,y1,x2,y2.'u'Create arc shaped region with coordinates x1,y1,x2,y2.'b'arc'u'arc'b'Create bitmap with coordinates x1,y1.'u'Create bitmap with coordinates x1,y1.'b'bitmap'u'bitmap'b'Create image item with coordinates x1,y1.'u'Create image item with coordinates x1,y1.'b'Create line with coordinates x1,y1,...,xn,yn.'u'Create line with coordinates x1,y1,...,xn,yn.'b'line'u'line'b'Create oval with coordinates x1,y1,x2,y2.'u'Create oval with coordinates x1,y1,x2,y2.'b'oval'u'oval'b'Create polygon with coordinates x1,y1,...,xn,yn.'u'Create polygon with coordinates x1,y1,...,xn,yn.'b'polygon'u'polygon'b'Create rectangle with coordinates x1,y1,x2,y2.'u'Create rectangle with coordinates x1,y1,x2,y2.'b'rectangle'u'rectangle'b'Create text with coordinates x1,y1.'u'Create text with coordinates x1,y1.'b'Create window with coordinates x1,y1,x2,y2.'u'Create window with coordinates x1,y1,x2,y2.'b'Delete characters of text items identified by tag or id in ARGS (possibly + several times) from FIRST to LAST character (including).'u'Delete characters of text items identified by tag or id in ARGS (possibly + several times) from FIRST to LAST character (including).'b'dchars'u'dchars'b'Delete items identified by all tag or ids contained in ARGS.'u'Delete items identified by all tag or ids contained in ARGS.'b'Delete tag or id given as last arguments in ARGS from items + identified by first argument in ARGS.'u'Delete tag or id given as last arguments in ARGS from items + identified by first argument in ARGS.'b'dtag'u'dtag'b'find'u'find'b'Return items above TAGORID.'u'Return items above TAGORID.'b'Return all items.'u'Return all items.'b'Return all items below TAGORID.'u'Return all items below TAGORID.'b'Return item which is closest to pixel at X, Y. + If several match take the top-most. + All items closer than HALO are considered overlapping (all are + closest). If START is specified the next below this tag is taken.'u'Return item which is closest to pixel at X, Y. + If several match take the top-most. + All items closer than HALO are considered overlapping (all are + closest). If START is specified the next below this tag is taken.'b'Return all items in rectangle defined + by X1,Y1,X2,Y2.'u'Return all items in rectangle defined + by X1,Y1,X2,Y2.'b'Return all items which overlap the rectangle + defined by X1,Y1,X2,Y2.'u'Return all items which overlap the rectangle + defined by X1,Y1,X2,Y2.'b'Return all items with TAGORID.'u'Return all items with TAGORID.'b'Set focus to the first item specified in ARGS.'u'Set focus to the first item specified in ARGS.'b'Return tags associated with the first item specified in ARGS.'u'Return tags associated with the first item specified in ARGS.'b'gettags'u'gettags'b'Set cursor at position POS in the item identified by TAGORID. + In ARGS TAGORID must be first.'u'Set cursor at position POS in the item identified by TAGORID. + In ARGS TAGORID must be first.'b'icursor'u'icursor'b'Return position of cursor as integer in item specified in ARGS.'u'Return position of cursor as integer in item specified in ARGS.'b'index'u'index'b'Insert TEXT in item TAGORID at position POS. ARGS must + be TAGORID POS TEXT.'u'Insert TEXT in item TAGORID at position POS. ARGS must + be TAGORID POS TEXT.'b'insert'u'insert'b'Return the resource value for an OPTION for item TAGORID.'u'Return the resource value for an OPTION for item TAGORID.'b'itemcget'u'itemcget'b'Configure resources of an item TAGORID. + + The values for resources are specified as keyword + arguments. To get an overview about + the allowed keyword arguments call the method without arguments. + 'u'Configure resources of an item TAGORID. + + The values for resources are specified as keyword + arguments. To get an overview about + the allowed keyword arguments call the method without arguments. + 'b'itemconfigure'u'itemconfigure'b'Lower an item TAGORID given in ARGS + (optional below another item).'u'Lower an item TAGORID given in ARGS + (optional below another item).'b'Move an item TAGORID given in ARGS.'u'Move an item TAGORID given in ARGS.'b'move'u'move'b'Move the items given by TAGORID in the canvas coordinate + space so that the first coordinate pair of the bottommost + item with tag TAGORID is located at position (X,Y). + X and Y may be the empty string, in which case the + corresponding coordinate will be unchanged. All items matching + TAGORID remain in the same positions relative to each other.'u'Move the items given by TAGORID in the canvas coordinate + space so that the first coordinate pair of the bottommost + item with tag TAGORID is located at position (X,Y). + X and Y may be the empty string, in which case the + corresponding coordinate will be unchanged. All items matching + TAGORID remain in the same positions relative to each other.'b'Print the contents of the canvas to a postscript + file. Valid options: colormap, colormode, file, fontmap, + height, pageanchor, pageheight, pagewidth, pagex, pagey, + rotate, width, x, y.'u'Print the contents of the canvas to a postscript + file. Valid options: colormap, colormode, file, fontmap, + height, pageanchor, pageheight, pagewidth, pagex, pagey, + rotate, width, x, y.'b'postscript'u'postscript'b'Raise an item TAGORID given in ARGS + (optional above another item).'u'Raise an item TAGORID given in ARGS + (optional above another item).'b'Scale item TAGORID with XORIGIN, YORIGIN, XSCALE, YSCALE.'u'Scale item TAGORID with XORIGIN, YORIGIN, XSCALE, YSCALE.'b'scale'u'scale'b'Remember the current X, Y coordinates.'u'Remember the current X, Y coordinates.'b'scan'u'scan'b'mark'u'mark'b'Adjust the view of the canvas to GAIN times the + difference between X and Y and the coordinates given in + scan_mark.'u'Adjust the view of the canvas to GAIN times the + difference between X and Y and the coordinates given in + scan_mark.'b'dragto'u'dragto'b'Adjust the end of the selection near the cursor of an item TAGORID to index.'u'Adjust the end of the selection near the cursor of an item TAGORID to index.'b'select'u'select'b'adjust'u'adjust'b'Clear the selection if it is in this widget.'u'Clear the selection if it is in this widget.'b'Set the fixed end of a selection in item TAGORID to INDEX.'u'Set the fixed end of a selection in item TAGORID to INDEX.'b'from'u'from'b'Return the item which has the selection.'u'Return the item which has the selection.'b'item'u'item'b'Set the variable end of a selection in item TAGORID to INDEX.'u'Set the variable end of a selection in item TAGORID to INDEX.'b'to'u'to'b'Return the type of the item TAGORID.'u'Return the type of the item TAGORID.'b'Checkbutton widget which is either in on- or off-state.'u'Checkbutton widget which is either in on- or off-state.'b'Construct a checkbutton widget with the parent MASTER. + + Valid resource names: activebackground, activeforeground, anchor, + background, bd, bg, bitmap, borderwidth, command, cursor, + disabledforeground, fg, font, foreground, height, + highlightbackground, highlightcolor, highlightthickness, image, + indicatoron, justify, offvalue, onvalue, padx, pady, relief, + selectcolor, selectimage, state, takefocus, text, textvariable, + underline, variable, width, wraplength.'u'Construct a checkbutton widget with the parent MASTER. + + Valid resource names: activebackground, activeforeground, anchor, + background, bd, bg, bitmap, borderwidth, command, cursor, + disabledforeground, fg, font, foreground, height, + highlightbackground, highlightcolor, highlightthickness, image, + indicatoron, justify, offvalue, onvalue, padx, pady, relief, + selectcolor, selectimage, state, takefocus, text, textvariable, + underline, variable, width, wraplength.'b'checkbutton'u'checkbutton'b'Put the button in off-state.'u'Put the button in off-state.'b'deselect'u'deselect'b'Flash the button.'u'Flash the button.'b'Toggle the button and invoke a command if given as resource.'u'Toggle the button and invoke a command if given as resource.'b'Put the button in on-state.'u'Put the button in on-state.'b'Toggle the button.'u'Toggle the button.'b'toggle'u'toggle'b'Entry widget which allows displaying simple text.'u'Entry widget which allows displaying simple text.'b'Construct an entry widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, cursor, + exportselection, fg, font, foreground, highlightbackground, + highlightcolor, highlightthickness, insertbackground, + insertborderwidth, insertofftime, insertontime, insertwidth, + invalidcommand, invcmd, justify, relief, selectbackground, + selectborderwidth, selectforeground, show, state, takefocus, + textvariable, validate, validatecommand, vcmd, width, + xscrollcommand.'u'Construct an entry widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, cursor, + exportselection, fg, font, foreground, highlightbackground, + highlightcolor, highlightthickness, insertbackground, + insertborderwidth, insertofftime, insertontime, insertwidth, + invalidcommand, invcmd, justify, relief, selectbackground, + selectborderwidth, selectforeground, show, state, takefocus, + textvariable, validate, validatecommand, vcmd, width, + xscrollcommand.'b'entry'u'entry'b'Delete text from FIRST to LAST (not included).'u'Delete text from FIRST to LAST (not included).'b'Return the text.'u'Return the text.'b'Insert cursor at INDEX.'u'Insert cursor at INDEX.'b'Return position of cursor.'u'Return position of cursor.'b'Insert STRING at INDEX.'u'Insert STRING at INDEX.'b'Adjust the view of the canvas to 10 times the + difference between X and Y and the coordinates given in + scan_mark.'u'Adjust the view of the canvas to 10 times the + difference between X and Y and the coordinates given in + scan_mark.'b'Adjust the end of the selection near the cursor to INDEX.'u'Adjust the end of the selection near the cursor to INDEX.'b'Set the fixed end of a selection to INDEX.'u'Set the fixed end of a selection to INDEX.'b'Return True if there are characters selected in the entry, False + otherwise.'u'Return True if there are characters selected in the entry, False + otherwise.'b'present'u'present'b'Set the selection from START to END (not included).'u'Set the selection from START to END (not included).'b'range'u'range'b'Set the variable end of a selection to INDEX.'u'Set the variable end of a selection to INDEX.'b'Frame widget which may contain other widgets and can have a 3D border.'u'Frame widget which may contain other widgets and can have a 3D border.'b'Construct a frame widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, class, + colormap, container, cursor, height, highlightbackground, + highlightcolor, highlightthickness, relief, takefocus, visual, width.'u'Construct a frame widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, class, + colormap, container, cursor, height, highlightbackground, + highlightcolor, highlightthickness, relief, takefocus, visual, width.'b'-class'u'-class'b'Label widget which can display text and bitmaps.'u'Label widget which can display text and bitmaps.'b'Construct a label widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, activeforeground, anchor, + background, bitmap, borderwidth, cursor, + disabledforeground, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, image, justify, + padx, pady, relief, takefocus, text, + textvariable, underline, wraplength + + WIDGET-SPECIFIC OPTIONS + + height, state, width + + 'u'Construct a label widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, activeforeground, anchor, + background, bitmap, borderwidth, cursor, + disabledforeground, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, image, justify, + padx, pady, relief, takefocus, text, + textvariable, underline, wraplength + + WIDGET-SPECIFIC OPTIONS + + height, state, width + + 'b'label'u'label'b'Listbox widget which can display a list of strings.'u'Listbox widget which can display a list of strings.'b'Construct a listbox widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, cursor, + exportselection, fg, font, foreground, height, highlightbackground, + highlightcolor, highlightthickness, relief, selectbackground, + selectborderwidth, selectforeground, selectmode, setgrid, takefocus, + width, xscrollcommand, yscrollcommand, listvariable.'u'Construct a listbox widget with the parent MASTER. + + Valid resource names: background, bd, bg, borderwidth, cursor, + exportselection, fg, font, foreground, height, highlightbackground, + highlightcolor, highlightthickness, relief, selectbackground, + selectborderwidth, selectforeground, selectmode, setgrid, takefocus, + width, xscrollcommand, yscrollcommand, listvariable.'b'listbox'u'listbox'b'Activate item identified by INDEX.'u'Activate item identified by INDEX.'b'activate'u'activate'b'Return a tuple of X1,Y1,X2,Y2 coordinates for a rectangle + which encloses the item identified by the given index.'u'Return a tuple of X1,Y1,X2,Y2 coordinates for a rectangle + which encloses the item identified by the given index.'b'Return the indices of currently selected item.'u'Return the indices of currently selected item.'b'curselection'u'curselection'b'Delete items from FIRST to LAST (included).'u'Delete items from FIRST to LAST (included).'b'Get list of items from FIRST to LAST (included).'u'Get list of items from FIRST to LAST (included).'b'Return index of item identified with INDEX.'u'Return index of item identified with INDEX.'b'Insert ELEMENTS at INDEX.'u'Insert ELEMENTS at INDEX.'b'Get index of item which is nearest to y coordinate Y.'u'Get index of item which is nearest to y coordinate Y.'b'nearest'u'nearest'b'Adjust the view of the listbox to 10 times the + difference between X and Y and the coordinates given in + scan_mark.'u'Adjust the view of the listbox to 10 times the + difference between X and Y and the coordinates given in + scan_mark.'b'Scroll such that INDEX is visible.'u'Scroll such that INDEX is visible.'b'see'u'see'b'Set the fixed end oft the selection to INDEX.'u'Set the fixed end oft the selection to INDEX.'b'Clear the selection from FIRST to LAST (included).'u'Clear the selection from FIRST to LAST (included).'b'Return True if INDEX is part of the selection.'u'Return True if INDEX is part of the selection.'b'includes'u'includes'b'Set the selection from FIRST to LAST (included) without + changing the currently selected elements.'u'Set the selection from FIRST to LAST (included) without + changing the currently selected elements.'b'Return the number of elements in the listbox.'u'Return the number of elements in the listbox.'b'Return the resource value for an ITEM and an OPTION.'u'Return the resource value for an ITEM and an OPTION.'b'Configure resources of an ITEM. + + The values for resources are specified as keyword arguments. + To get an overview about the allowed keyword arguments + call the method without arguments. + Valid resource names: background, bg, foreground, fg, + selectbackground, selectforeground.'u'Configure resources of an ITEM. + + The values for resources are specified as keyword arguments. + To get an overview about the allowed keyword arguments + call the method without arguments. + Valid resource names: background, bg, foreground, fg, + selectbackground, selectforeground.'b'Menu widget which allows displaying menu bars, pull-down menus and pop-up menus.'u'Menu widget which allows displaying menu bars, pull-down menus and pop-up menus.'b'Construct menu widget with the parent MASTER. + + Valid resource names: activebackground, activeborderwidth, + activeforeground, background, bd, bg, borderwidth, cursor, + disabledforeground, fg, font, foreground, postcommand, relief, + selectcolor, takefocus, tearoff, tearoffcommand, title, type.'u'Construct menu widget with the parent MASTER. + + Valid resource names: activebackground, activeborderwidth, + activeforeground, background, bd, bg, borderwidth, cursor, + disabledforeground, fg, font, foreground, postcommand, relief, + selectcolor, takefocus, tearoff, tearoffcommand, title, type.'b'menu'u'menu'b'Post the menu at position X,Y with entry ENTRY.'u'Post the menu at position X,Y with entry ENTRY.'b'tk_popup'u'tk_popup'b'Activate entry at INDEX.'u'Activate entry at INDEX.'b'Add hierarchical menu item.'u'Add hierarchical menu item.'b'cascade'u'cascade'b'Add checkbutton menu item.'u'Add checkbutton menu item.'b'Add command menu item.'u'Add command menu item.'b'Addd radio menu item.'u'Addd radio menu item.'b'radiobutton'u'radiobutton'b'Add separator.'u'Add separator.'b'separator'u'separator'b'Add hierarchical menu item at INDEX.'u'Add hierarchical menu item at INDEX.'b'Add checkbutton menu item at INDEX.'u'Add checkbutton menu item at INDEX.'b'Add command menu item at INDEX.'u'Add command menu item at INDEX.'b'Addd radio menu item at INDEX.'u'Addd radio menu item at INDEX.'b'Add separator at INDEX.'u'Add separator at INDEX.'b'Delete menu items between INDEX1 and INDEX2 (included).'u'Delete menu items between INDEX1 and INDEX2 (included).'b'Return the resource value of a menu item for OPTION at INDEX.'u'Return the resource value of a menu item for OPTION at INDEX.'b'entrycget'u'entrycget'b'Configure a menu item at INDEX.'u'Configure a menu item at INDEX.'b'entryconfigure'u'entryconfigure'b'Return the index of a menu item identified by INDEX.'u'Return the index of a menu item identified by INDEX.'b'Invoke a menu item identified by INDEX and execute + the associated command.'u'Invoke a menu item identified by INDEX and execute + the associated command.'b'Display a menu at position X,Y.'u'Display a menu at position X,Y.'b'post'u'post'b'Return the type of the menu item at INDEX.'u'Return the type of the menu item at INDEX.'b'Unmap a menu.'u'Unmap a menu.'b'unpost'u'unpost'b'Return the x-position of the leftmost pixel of the menu item + at INDEX.'u'Return the x-position of the leftmost pixel of the menu item + at INDEX.'b'xposition'u'xposition'b'Return the y-position of the topmost pixel of the menu item at INDEX.'u'Return the y-position of the topmost pixel of the menu item at INDEX.'b'yposition'u'yposition'b'Menubutton widget, obsolete since Tk8.0.'u'Menubutton widget, obsolete since Tk8.0.'b'menubutton'u'menubutton'b'Message widget to display multiline text. Obsolete since Label does it too.'u'Message widget to display multiline text. Obsolete since Label does it too.'b'message'u'message'b'Radiobutton widget which shows only one of several buttons in on-state.'u'Radiobutton widget which shows only one of several buttons in on-state.'b'Construct a radiobutton widget with the parent MASTER. + + Valid resource names: activebackground, activeforeground, anchor, + background, bd, bg, bitmap, borderwidth, command, cursor, + disabledforeground, fg, font, foreground, height, + highlightbackground, highlightcolor, highlightthickness, image, + indicatoron, justify, padx, pady, relief, selectcolor, selectimage, + state, takefocus, text, textvariable, underline, value, variable, + width, wraplength.'u'Construct a radiobutton widget with the parent MASTER. + + Valid resource names: activebackground, activeforeground, anchor, + background, bd, bg, bitmap, borderwidth, command, cursor, + disabledforeground, fg, font, foreground, height, + highlightbackground, highlightcolor, highlightthickness, image, + indicatoron, justify, padx, pady, relief, selectcolor, selectimage, + state, takefocus, text, textvariable, underline, value, variable, + width, wraplength.'b'Scale widget which can display a numerical scale.'u'Scale widget which can display a numerical scale.'b'Construct a scale widget with the parent MASTER. + + Valid resource names: activebackground, background, bigincrement, bd, + bg, borderwidth, command, cursor, digits, fg, font, foreground, from, + highlightbackground, highlightcolor, highlightthickness, label, + length, orient, relief, repeatdelay, repeatinterval, resolution, + showvalue, sliderlength, sliderrelief, state, takefocus, + tickinterval, to, troughcolor, variable, width.'u'Construct a scale widget with the parent MASTER. + + Valid resource names: activebackground, background, bigincrement, bd, + bg, borderwidth, command, cursor, digits, fg, font, foreground, from, + highlightbackground, highlightcolor, highlightthickness, label, + length, orient, relief, repeatdelay, repeatinterval, resolution, + showvalue, sliderlength, sliderrelief, state, takefocus, + tickinterval, to, troughcolor, variable, width.'b'Get the current value as integer or float.'u'Get the current value as integer or float.'b'Set the value to VALUE.'u'Set the value to VALUE.'b'Return a tuple (X,Y) of the point along the centerline of the + trough that corresponds to VALUE or the current value if None is + given.'u'Return a tuple (X,Y) of the point along the centerline of the + trough that corresponds to VALUE or the current value if None is + given.'b'Return where the point X,Y lies. Valid return values are "slider", + "though1" and "though2".'u'Return where the point X,Y lies. Valid return values are "slider", + "though1" and "though2".'b'identify'u'identify'b'Scrollbar widget which displays a slider at a certain position.'u'Scrollbar widget which displays a slider at a certain position.'b'Construct a scrollbar widget with the parent MASTER. + + Valid resource names: activebackground, activerelief, + background, bd, bg, borderwidth, command, cursor, + elementborderwidth, highlightbackground, + highlightcolor, highlightthickness, jump, orient, + relief, repeatdelay, repeatinterval, takefocus, + troughcolor, width.'u'Construct a scrollbar widget with the parent MASTER. + + Valid resource names: activebackground, activerelief, + background, bd, bg, borderwidth, command, cursor, + elementborderwidth, highlightbackground, + highlightcolor, highlightthickness, jump, orient, + relief, repeatdelay, repeatinterval, takefocus, + troughcolor, width.'b'scrollbar'u'scrollbar'b'Marks the element indicated by index as active. + The only index values understood by this method are "arrow1", + "slider", or "arrow2". If any other value is specified then no + element of the scrollbar will be active. If index is not specified, + the method returns the name of the element that is currently active, + or None if no element is active.'u'Marks the element indicated by index as active. + The only index values understood by this method are "arrow1", + "slider", or "arrow2". If any other value is specified then no + element of the scrollbar will be active. If index is not specified, + the method returns the name of the element that is currently active, + or None if no element is active.'b'Return the fractional change of the scrollbar setting if it + would be moved by DELTAX or DELTAY pixels.'u'Return the fractional change of the scrollbar setting if it + would be moved by DELTAX or DELTAY pixels.'b'Return the fractional value which corresponds to a slider + position of X,Y.'u'Return the fractional value which corresponds to a slider + position of X,Y.'b'fraction'u'fraction'b'Return the element under position X,Y as one of + "arrow1","slider","arrow2" or "".'u'Return the element under position X,Y as one of + "arrow1","slider","arrow2" or "".'b'Return the current fractional values (upper and lower end) + of the slider position.'u'Return the current fractional values (upper and lower end) + of the slider position.'b'Set the fractional values of the slider position (upper and + lower ends as value between 0 and 1).'u'Set the fractional values of the slider position (upper and + lower ends as value between 0 and 1).'b'Text widget which can display text in various forms.'u'Text widget which can display text in various forms.'b'Construct a text widget with the parent MASTER. + + STANDARD OPTIONS + + background, borderwidth, cursor, + exportselection, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, insertbackground, + insertborderwidth, insertofftime, + insertontime, insertwidth, padx, pady, + relief, selectbackground, + selectborderwidth, selectforeground, + setgrid, takefocus, + xscrollcommand, yscrollcommand, + + WIDGET-SPECIFIC OPTIONS + + autoseparators, height, maxundo, + spacing1, spacing2, spacing3, + state, tabs, undo, width, wrap, + + 'u'Construct a text widget with the parent MASTER. + + STANDARD OPTIONS + + background, borderwidth, cursor, + exportselection, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, insertbackground, + insertborderwidth, insertofftime, + insertontime, insertwidth, padx, pady, + relief, selectbackground, + selectborderwidth, selectforeground, + setgrid, takefocus, + xscrollcommand, yscrollcommand, + + WIDGET-SPECIFIC OPTIONS + + autoseparators, height, maxundo, + spacing1, spacing2, spacing3, + state, tabs, undo, width, wrap, + + 'b'Return a tuple of (x,y,width,height) which gives the bounding + box of the visible part of the character at the given index.'u'Return a tuple of (x,y,width,height) which gives the bounding + box of the visible part of the character at the given index.'b'Return whether between index INDEX1 and index INDEX2 the + relation OP is satisfied. OP is one of <, <=, ==, >=, >, or !=.'u'Return whether between index INDEX1 and index INDEX2 the + relation OP is satisfied. OP is one of <, <=, ==, >=, >, or !=.'b'compare'u'compare'b'Counts the number of relevant things between the two indices. + If index1 is after index2, the result will be a negative number + (and this holds for each of the possible options). + + The actual items which are counted depends on the options given by + args. The result is a list of integers, one for the result of each + counting option given. Valid counting options are "chars", + "displaychars", "displayindices", "displaylines", "indices", + "lines", "xpixels" and "ypixels". There is an additional possible + option "update", which if given then all subsequent options ensure + that any possible out of date information is recalculated.'u'Counts the number of relevant things between the two indices. + If index1 is after index2, the result will be a negative number + (and this holds for each of the possible options). + + The actual items which are counted depends on the options given by + args. The result is a list of integers, one for the result of each + counting option given. Valid counting options are "chars", + "displaychars", "displayindices", "displaylines", "indices", + "lines", "xpixels" and "ypixels". There is an additional possible + option "update", which if given then all subsequent options ensure + that any possible out of date information is recalculated.'b'count'u'count'b'Turn on the internal consistency checks of the B-Tree inside the text + widget according to BOOLEAN.'u'Turn on the internal consistency checks of the B-Tree inside the text + widget according to BOOLEAN.'b'debug'u'debug'b'Delete the characters between INDEX1 and INDEX2 (not included).'u'Delete the characters between INDEX1 and INDEX2 (not included).'b'Return tuple (x,y,width,height,baseline) giving the bounding box + and baseline position of the visible part of the line containing + the character at INDEX.'u'Return tuple (x,y,width,height,baseline) giving the bounding box + and baseline position of the visible part of the line containing + the character at INDEX.'b'dlineinfo'u'dlineinfo'b'Return the contents of the widget between index1 and index2. + + The type of contents returned in filtered based on the keyword + parameters; if 'all', 'image', 'mark', 'tag', 'text', or 'window' are + given and true, then the corresponding items are returned. The result + is a list of triples of the form (key, value, index). If none of the + keywords are true then 'all' is used by default. + + If the 'command' argument is given, it is called once for each element + of the list of triples, with the values of each triple serving as the + arguments to the function. In this case the list is not returned.'u'Return the contents of the widget between index1 and index2. + + The type of contents returned in filtered based on the keyword + parameters; if 'all', 'image', 'mark', 'tag', 'text', or 'window' are + given and true, then the corresponding items are returned. The result + is a list of triples of the form (key, value, index). If none of the + keywords are true then 'all' is used by default. + + If the 'command' argument is given, it is called once for each element + of the list of triples, with the values of each triple serving as the + arguments to the function. In this case the list is not returned.'b'-command'u'-command'b'Internal method + + This method controls the undo mechanism and + the modified flag. The exact behavior of the + command depends on the option argument that + follows the edit argument. The following forms + of the command are currently supported: + + edit_modified, edit_redo, edit_reset, edit_separator + and edit_undo + + 'u'Internal method + + This method controls the undo mechanism and + the modified flag. The exact behavior of the + command depends on the option argument that + follows the edit argument. The following forms + of the command are currently supported: + + edit_modified, edit_redo, edit_reset, edit_separator + and edit_undo + + 'b'edit'u'edit'b'Get or Set the modified flag + + If arg is not specified, returns the modified + flag of the widget. The insert, delete, edit undo and + edit redo commands or the user can set or clear the + modified flag. If boolean is specified, sets the + modified flag of the widget to arg. + 'u'Get or Set the modified flag + + If arg is not specified, returns the modified + flag of the widget. The insert, delete, edit undo and + edit redo commands or the user can set or clear the + modified flag. If boolean is specified, sets the + modified flag of the widget to arg. + 'b'modified'u'modified'b'Redo the last undone edit + + When the undo option is true, reapplies the last + undone edits provided no other edits were done since + then. Generates an error when the redo stack is empty. + Does nothing when the undo option is false. + 'u'Redo the last undone edit + + When the undo option is true, reapplies the last + undone edits provided no other edits were done since + then. Generates an error when the redo stack is empty. + Does nothing when the undo option is false. + 'b'redo'u'redo'b'Clears the undo and redo stacks + 'u'Clears the undo and redo stacks + 'b'reset'u'reset'b'Inserts a separator (boundary) on the undo stack. + + Does nothing when the undo option is false + 'u'Inserts a separator (boundary) on the undo stack. + + Does nothing when the undo option is false + 'b'Undoes the last edit action + + If the undo option is true. An edit action is defined + as all the insert and delete commands that are recorded + on the undo stack in between two separators. Generates + an error when the undo stack is empty. Does nothing + when the undo option is false + 'u'Undoes the last edit action + + If the undo option is true. An edit action is defined + as all the insert and delete commands that are recorded + on the undo stack in between two separators. Generates + an error when the undo stack is empty. Does nothing + when the undo option is false + 'b'undo'u'undo'b'Return the text from INDEX1 to INDEX2 (not included).'u'Return the text from INDEX1 to INDEX2 (not included).'b'Return the value of OPTION of an embedded image at INDEX.'u'Return the value of OPTION of an embedded image at INDEX.'b'Configure an embedded image at INDEX.'u'Configure an embedded image at INDEX.'b'Create an embedded image at INDEX.'u'Create an embedded image at INDEX.'b'Return all names of embedded images in this widget.'u'Return all names of embedded images in this widget.'b'Return the index in the form line.char for INDEX.'u'Return the index in the form line.char for INDEX.'b'Insert CHARS before the characters at INDEX. An additional + tag can be given in ARGS. Additional CHARS and tags can follow in ARGS.'u'Insert CHARS before the characters at INDEX. An additional + tag can be given in ARGS. Additional CHARS and tags can follow in ARGS.'b'Change the gravity of a mark MARKNAME to DIRECTION (LEFT or RIGHT). + Return the current value if None is given for DIRECTION.'u'Change the gravity of a mark MARKNAME to DIRECTION (LEFT or RIGHT). + Return the current value if None is given for DIRECTION.'b'gravity'u'gravity'b'Return all mark names.'u'Return all mark names.'b'Set mark MARKNAME before the character at INDEX.'u'Set mark MARKNAME before the character at INDEX.'b'Delete all marks in MARKNAMES.'u'Delete all marks in MARKNAMES.'b'unset'u'unset'b'Return the name of the next mark after INDEX.'u'Return the name of the next mark after INDEX.'b'next'u'next'b'Return the name of the previous mark before INDEX.'u'Return the name of the previous mark before INDEX.'b'previous'u'previous'b'Creates a peer text widget with the given newPathName, and any + optional standard configuration options. By default the peer will + have the same start and end line as the parent widget, but + these can be overridden with the standard configuration options.'u'Creates a peer text widget with the given newPathName, and any + optional standard configuration options. By default the peer will + have the same start and end line as the parent widget, but + these can be overridden with the standard configuration options.'b'peer'u'peer'b'Returns a list of peers of this widget (this does not include + the widget itself).'u'Returns a list of peers of this widget (this does not include + the widget itself).'b'Replaces the range of characters between index1 and index2 with + the given characters and tags specified by args. + + See the method insert for some more information about args, and the + method delete for information about the indices.'u'Replaces the range of characters between index1 and index2 with + the given characters and tags specified by args. + + See the method insert for some more information about args, and the + method delete for information about the indices.'b'replace'u'replace'b'Adjust the view of the text to 10 times the + difference between X and Y and the coordinates given in + scan_mark.'u'Adjust the view of the text to 10 times the + difference between X and Y and the coordinates given in + scan_mark.'b'Search PATTERN beginning from INDEX until STOPINDEX. + Return the index of the first character of a match or an + empty string.'u'Search PATTERN beginning from INDEX until STOPINDEX. + Return the index of the first character of a match or an + empty string.'b'search'u'search'b'-forwards'u'-forwards'b'-backwards'u'-backwards'b'-exact'u'-exact'b'-regexp'u'-regexp'b'-nocase'u'-nocase'b'-elide'u'-elide'b'-count'u'-count'b'Scroll such that the character at INDEX is visible.'u'Scroll such that the character at INDEX is visible.'b'Add tag TAGNAME to all characters between INDEX1 and index2 in ARGS. + Additional pairs of indices may follow in ARGS.'u'Add tag TAGNAME to all characters between INDEX1 and index2 in ARGS. + Additional pairs of indices may follow in ARGS.'b'Unbind for all characters with TAGNAME for event SEQUENCE the + function identified with FUNCID.'u'Unbind for all characters with TAGNAME for event SEQUENCE the + function identified with FUNCID.'b'Bind to all characters with TAGNAME at event SEQUENCE a call to function FUNC. + + An additional boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or whether it will + replace the previous function. See bind for the return value.'u'Bind to all characters with TAGNAME at event SEQUENCE a call to function FUNC. + + An additional boolean parameter ADD specifies whether FUNC will be + called additionally to the other bound function or whether it will + replace the previous function. See bind for the return value.'b'Return the value of OPTION for tag TAGNAME.'u'Return the value of OPTION for tag TAGNAME.'b'Configure a tag TAGNAME.'u'Configure a tag TAGNAME.'b'Delete all tags in TAGNAMES.'u'Delete all tags in TAGNAMES.'b'Change the priority of tag TAGNAME such that it is lower + than the priority of BELOWTHIS.'u'Change the priority of tag TAGNAME such that it is lower + than the priority of BELOWTHIS.'b'Return a list of all tag names.'u'Return a list of all tag names.'b'Return a list of start and end index for the first sequence of + characters between INDEX1 and INDEX2 which all have tag TAGNAME. + The text is searched forward from INDEX1.'u'Return a list of start and end index for the first sequence of + characters between INDEX1 and INDEX2 which all have tag TAGNAME. + The text is searched forward from INDEX1.'b'nextrange'u'nextrange'b'Return a list of start and end index for the first sequence of + characters between INDEX1 and INDEX2 which all have tag TAGNAME. + The text is searched backwards from INDEX1.'u'Return a list of start and end index for the first sequence of + characters between INDEX1 and INDEX2 which all have tag TAGNAME. + The text is searched backwards from INDEX1.'b'prevrange'u'prevrange'b'Change the priority of tag TAGNAME such that it is higher + than the priority of ABOVETHIS.'u'Change the priority of tag TAGNAME such that it is higher + than the priority of ABOVETHIS.'b'Return a list of ranges of text which have tag TAGNAME.'u'Return a list of ranges of text which have tag TAGNAME.'b'ranges'u'ranges'b'Remove tag TAGNAME from all characters between INDEX1 and INDEX2.'u'Remove tag TAGNAME from all characters between INDEX1 and INDEX2.'b'Return the value of OPTION of an embedded window at INDEX.'u'Return the value of OPTION of an embedded window at INDEX.'b'Configure an embedded window at INDEX.'u'Configure an embedded window at INDEX.'b'Create a window at INDEX.'u'Create a window at INDEX.'b'Return all names of embedded windows in this widget.'u'Return all names of embedded windows in this widget.'b'Obsolete function, use see.'u'Obsolete function, use see.'b'-pickplace'u'-pickplace'b'Internal class. It wraps the command in the widget OptionMenu.'u'Internal class. It wraps the command in the widget OptionMenu.'b'OptionMenu which allows the user to select a value from a menu.'u'OptionMenu which allows the user to select a value from a menu.'b'Construct an optionmenu widget with the parent MASTER, with + the resource textvariable set to VARIABLE, the initially selected + value VALUE, the other menu values VALUES and an additional + keyword argument command.'u'Construct an optionmenu widget with the parent MASTER, with + the resource textvariable set to VARIABLE, the initially selected + value VALUE, the other menu values VALUES and an additional + keyword argument command.'b'borderwidth'u'borderwidth'b'textvariable'u'textvariable'b'indicatoron'u'indicatoron'b'relief'u'relief'b'c'u'c'b'highlightthickness'u'highlightthickness'b'tk_optionMenu'u'tk_optionMenu'b'unknown option -'u'unknown option -'b'Destroy this widget and the associated menu.'u'Destroy this widget and the associated menu.'b'Base class for images.'u'Base class for images.'b'create image'u'create image'b'pyimage%r'u'pyimage%r'b'Configure the image.'u'Configure the image.'b'config'u'config'b'Return the height of the image.'u'Return the height of the image.'b'Return the type of the image, e.g. "photo" or "bitmap".'u'Return the type of the image, e.g. "photo" or "bitmap".'b'Return the width of the image.'u'Return the width of the image.'b'Widget which can display images in PGM, PPM, GIF, PNG format.'u'Widget which can display images in PGM, PPM, GIF, PNG format.'b'Create an image with NAME. + + Valid resource names: data, format, file, gamma, height, palette, + width.'u'Create an image with NAME. + + Valid resource names: data, format, file, gamma, height, palette, + width.'b'photo'u'photo'b'Display a transparent image.'u'Display a transparent image.'b'blank'u'blank'b'Return the value of OPTION.'u'Return the value of OPTION.'b'Return a new PhotoImage with the same image as this widget.'u'Return a new PhotoImage with the same image as this widget.'b'copy'u'copy'b'Return a new PhotoImage with the same image as this widget + but zoom it with a factor of x in the X direction and y in the Y + direction. If y is not given, the default value is the same as x. + 'u'Return a new PhotoImage with the same image as this widget + but zoom it with a factor of x in the X direction and y in the Y + direction. If y is not given, the default value is the same as x. + 'b'-zoom'u'-zoom'b'Return a new PhotoImage based on the same image as this widget + but use only every Xth or Yth pixel. If y is not given, the + default value is the same as x. + 'u'Return a new PhotoImage based on the same image as this widget + but use only every Xth or Yth pixel. If y is not given, the + default value is the same as x. + 'b'-subsample'u'-subsample'b'Return the color (red, green, blue) of the pixel at X,Y.'u'Return the color (red, green, blue) of the pixel at X,Y.'b'Put row formatted colors to image starting from + position TO, e.g. image.put("{red green} {blue yellow}", to=(4,6))'u'Put row formatted colors to image starting from + position TO, e.g. image.put("{red green} {blue yellow}", to=(4,6))'b'put'u'put'b'-to'u'-to'b'Write image to file FILENAME in FORMAT starting from + position FROM_COORDS.'u'Write image to file FILENAME in FORMAT starting from + position FROM_COORDS.'b'write'u'write'b'-format'u'-format'b'-from'u'-from'b'Return True if the pixel at x,y is transparent.'u'Return True if the pixel at x,y is transparent.'b'transparency'u'transparency'b'Set the transparency of the pixel at x,y.'u'Set the transparency of the pixel at x,y.'b'Widget which can display images in XBM format.'u'Widget which can display images in XBM format.'b'Create a bitmap with NAME. + + Valid resource names: background, data, file, foreground, maskdata, maskfile.'u'Create a bitmap with NAME. + + Valid resource names: background, data, file, foreground, maskdata, maskfile.'b'use image_names()'u'use image_names()'b'use image_types()'u'use image_types()'b'spinbox widget.'u'spinbox widget.'b'Construct a spinbox widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, background, borderwidth, + cursor, exportselection, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, insertbackground, + insertborderwidth, insertofftime, + insertontime, insertwidth, justify, relief, + repeatdelay, repeatinterval, + selectbackground, selectborderwidth + selectforeground, takefocus, textvariable + xscrollcommand. + + WIDGET-SPECIFIC OPTIONS + + buttonbackground, buttoncursor, + buttondownrelief, buttonuprelief, + command, disabledbackground, + disabledforeground, format, from, + invalidcommand, increment, + readonlybackground, state, to, + validate, validatecommand values, + width, wrap, + 'u'Construct a spinbox widget with the parent MASTER. + + STANDARD OPTIONS + + activebackground, background, borderwidth, + cursor, exportselection, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, insertbackground, + insertborderwidth, insertofftime, + insertontime, insertwidth, justify, relief, + repeatdelay, repeatinterval, + selectbackground, selectborderwidth + selectforeground, takefocus, textvariable + xscrollcommand. + + WIDGET-SPECIFIC OPTIONS + + buttonbackground, buttoncursor, + buttondownrelief, buttonuprelief, + command, disabledbackground, + disabledforeground, format, from, + invalidcommand, increment, + readonlybackground, state, to, + validate, validatecommand values, + width, wrap, + 'b'spinbox'u'spinbox'b'Return a tuple of X1,Y1,X2,Y2 coordinates for a + rectangle which encloses the character given by index. + + The first two elements of the list give the x and y + coordinates of the upper-left corner of the screen + area covered by the character (in pixels relative + to the widget) and the last two elements give the + width and height of the character, in pixels. The + bounding box may refer to a region outside the + visible area of the window. + 'u'Return a tuple of X1,Y1,X2,Y2 coordinates for a + rectangle which encloses the character given by index. + + The first two elements of the list give the x and y + coordinates of the upper-left corner of the screen + area covered by the character (in pixels relative + to the widget) and the last two elements give the + width and height of the character, in pixels. The + bounding box may refer to a region outside the + visible area of the window. + 'b'Delete one or more elements of the spinbox. + + First is the index of the first character to delete, + and last is the index of the character just after + the last one to delete. If last isn't specified it + defaults to first+1, i.e. a single character is + deleted. This command returns an empty string. + 'u'Delete one or more elements of the spinbox. + + First is the index of the first character to delete, + and last is the index of the character just after + the last one to delete. If last isn't specified it + defaults to first+1, i.e. a single character is + deleted. This command returns an empty string. + 'b'Returns the spinbox's string'u'Returns the spinbox's string'b'Alter the position of the insertion cursor. + + The insertion cursor will be displayed just before + the character given by index. Returns an empty string + 'u'Alter the position of the insertion cursor. + + The insertion cursor will be displayed just before + the character given by index. Returns an empty string + 'b'Returns the name of the widget at position x, y + + Return value is one of: none, buttondown, buttonup, entry + 'u'Returns the name of the widget at position x, y + + Return value is one of: none, buttondown, buttonup, entry + 'b'Returns the numerical index corresponding to index + 'u'Returns the numerical index corresponding to index + 'b'Insert string s at index + + Returns an empty string. + 'u'Insert string s at index + + Returns an empty string. + 'b'Causes the specified element to be invoked + + The element could be buttondown or buttonup + triggering the action associated with it. + 'u'Causes the specified element to be invoked + + The element could be buttondown or buttonup + triggering the action associated with it. + 'b'Records x and the current view in the spinbox window; + + used in conjunction with later scan dragto commands. + Typically this command is associated with a mouse button + press in the widget. It returns an empty string. + 'u'Records x and the current view in the spinbox window; + + used in conjunction with later scan dragto commands. + Typically this command is associated with a mouse button + press in the widget. It returns an empty string. + 'b'Compute the difference between the given x argument + and the x argument to the last scan mark command + + It then adjusts the view left or right by 10 times the + difference in x-coordinates. This command is typically + associated with mouse motion events in the widget, to + produce the effect of dragging the spinbox at high speed + through the window. The return value is an empty string. + 'u'Compute the difference between the given x argument + and the x argument to the last scan mark command + + It then adjusts the view left or right by 10 times the + difference in x-coordinates. This command is typically + associated with mouse motion events in the widget, to + produce the effect of dragging the spinbox at high speed + through the window. The return value is an empty string. + 'b'Locate the end of the selection nearest to the character + given by index, + + Then adjust that end of the selection to be at index + (i.e including but not going beyond index). The other + end of the selection is made the anchor point for future + select to commands. If the selection isn't currently in + the spinbox, then a new selection is created to include + the characters between index and the most recent selection + anchor point, inclusive. + 'u'Locate the end of the selection nearest to the character + given by index, + + Then adjust that end of the selection to be at index + (i.e including but not going beyond index). The other + end of the selection is made the anchor point for future + select to commands. If the selection isn't currently in + the spinbox, then a new selection is created to include + the characters between index and the most recent selection + anchor point, inclusive. + 'b'Clear the selection + + If the selection isn't in this widget then the + command has no effect. + 'u'Clear the selection + + If the selection isn't in this widget then the + command has no effect. + 'b'Sets or gets the currently selected element. + + If a spinbutton element is specified, it will be + displayed depressed. + 'u'Sets or gets the currently selected element. + + If a spinbutton element is specified, it will be + displayed depressed. + 'b'element'u'element'b'Return True if there are characters selected in the spinbox, False + otherwise.'u'Return True if there are characters selected in the spinbox, False + otherwise.'b'labelframe widget.'u'labelframe widget.'b'Construct a labelframe widget with the parent MASTER. + + STANDARD OPTIONS + + borderwidth, cursor, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, padx, pady, relief, + takefocus, text + + WIDGET-SPECIFIC OPTIONS + + background, class, colormap, container, + height, labelanchor, labelwidget, + visual, width + 'u'Construct a labelframe widget with the parent MASTER. + + STANDARD OPTIONS + + borderwidth, cursor, font, foreground, + highlightbackground, highlightcolor, + highlightthickness, padx, pady, relief, + takefocus, text + + WIDGET-SPECIFIC OPTIONS + + background, class, colormap, container, + height, labelanchor, labelwidget, + visual, width + 'b'labelframe'u'labelframe'b'panedwindow widget.'u'panedwindow widget.'b'Construct a panedwindow widget with the parent MASTER. + + STANDARD OPTIONS + + background, borderwidth, cursor, height, + orient, relief, width + + WIDGET-SPECIFIC OPTIONS + + handlepad, handlesize, opaqueresize, + sashcursor, sashpad, sashrelief, + sashwidth, showhandle, + 'u'Construct a panedwindow widget with the parent MASTER. + + STANDARD OPTIONS + + background, borderwidth, cursor, height, + orient, relief, width + + WIDGET-SPECIFIC OPTIONS + + handlepad, handlesize, opaqueresize, + sashcursor, sashpad, sashrelief, + sashwidth, showhandle, + 'b'panedwindow'u'panedwindow'b'Add a child widget to the panedwindow in a new pane. + + The child argument is the name of the child widget + followed by pairs of arguments that specify how to + manage the windows. The possible options and values + are the ones accepted by the paneconfigure method. + 'u'Add a child widget to the panedwindow in a new pane. + + The child argument is the name of the child widget + followed by pairs of arguments that specify how to + manage the windows. The possible options and values + are the ones accepted by the paneconfigure method. + 'b'Remove the pane containing child from the panedwindow + + All geometry management options for child will be forgotten. + 'u'Remove the pane containing child from the panedwindow + + All geometry management options for child will be forgotten. + 'b'Identify the panedwindow component at point x, y + + If the point is over a sash or a sash handle, the result + is a two element list containing the index of the sash or + handle, and a word indicating whether it is over a sash + or a handle, such as {0 sash} or {2 handle}. If the point + is over any other part of the panedwindow, the result is + an empty list. + 'u'Identify the panedwindow component at point x, y + + If the point is over a sash or a sash handle, the result + is a two element list containing the index of the sash or + handle, and a word indicating whether it is over a sash + or a handle, such as {0 sash} or {2 handle}. If the point + is over any other part of the panedwindow, the result is + an empty list. + 'b'proxy'u'proxy'b'Return the x and y pair of the most recent proxy location + 'u'Return the x and y pair of the most recent proxy location + 'b'coord'u'coord'b'Remove the proxy from the display. + 'u'Remove the proxy from the display. + 'b'Place the proxy at the given x and y coordinates. + 'u'Place the proxy at the given x and y coordinates. + 'b'sash'u'sash'b'Return the current x and y pair for the sash given by index. + + Index must be an integer between 0 and 1 less than the + number of panes in the panedwindow. The coordinates given are + those of the top left corner of the region containing the sash. + pathName sash dragto index x y This command computes the + difference between the given coordinates and the coordinates + given to the last sash coord command for the given sash. It then + moves that sash the computed difference. The return value is the + empty string. + 'u'Return the current x and y pair for the sash given by index. + + Index must be an integer between 0 and 1 less than the + number of panes in the panedwindow. The coordinates given are + those of the top left corner of the region containing the sash. + pathName sash dragto index x y This command computes the + difference between the given coordinates and the coordinates + given to the last sash coord command for the given sash. It then + moves that sash the computed difference. The return value is the + empty string. + 'b'Records x and y for the sash given by index; + + Used in conjunction with later dragto commands to move the sash. + 'u'Records x and y for the sash given by index; + + Used in conjunction with later dragto commands to move the sash. + 'b'Place the sash given by index at the given coordinates + 'u'Place the sash given by index at the given coordinates + 'b'Query a management option for window. + + Option may be any value allowed by the paneconfigure subcommand + 'u'Query a management option for window. + + Option may be any value allowed by the paneconfigure subcommand + 'b'panecget'u'panecget'b'Query or modify the management options for window. + + If no option is specified, returns a list describing all + of the available options for pathName. If option is + specified with no value, then the command returns a list + describing the one named option (this list will be identical + to the corresponding sublist of the value returned if no + option is specified). If one or more option-value pairs are + specified, then the command modifies the given widget + option(s) to have the given value(s); in this case the + command returns an empty string. The following options + are supported: + + after window + Insert the window after the window specified. window + should be the name of a window already managed by pathName. + before window + Insert the window before the window specified. window + should be the name of a window already managed by pathName. + height size + Specify a height for the window. The height will be the + outer dimension of the window including its border, if + any. If size is an empty string, or if -height is not + specified, then the height requested internally by the + window will be used initially; the height may later be + adjusted by the movement of sashes in the panedwindow. + Size may be any value accepted by Tk_GetPixels. + minsize n + Specifies that the size of the window cannot be made + less than n. This constraint only affects the size of + the widget in the paned dimension -- the x dimension + for horizontal panedwindows, the y dimension for + vertical panedwindows. May be any value accepted by + Tk_GetPixels. + padx n + Specifies a non-negative value indicating how much + extra space to leave on each side of the window in + the X-direction. The value may have any of the forms + accepted by Tk_GetPixels. + pady n + Specifies a non-negative value indicating how much + extra space to leave on each side of the window in + the Y-direction. The value may have any of the forms + accepted by Tk_GetPixels. + sticky style + If a window's pane is larger than the requested + dimensions of the window, this option may be used + to position (or stretch) the window within its pane. + Style is a string that contains zero or more of the + characters n, s, e or w. The string can optionally + contains spaces or commas, but they are ignored. Each + letter refers to a side (north, south, east, or west) + that the window will "stick" to. If both n and s + (or e and w) are specified, the window will be + stretched to fill the entire height (or width) of + its cavity. + width size + Specify a width for the window. The width will be + the outer dimension of the window including its + border, if any. If size is an empty string, or + if -width is not specified, then the width requested + internally by the window will be used initially; the + width may later be adjusted by the movement of sashes + in the panedwindow. Size may be any value accepted by + Tk_GetPixels. + + 'u'Query or modify the management options for window. + + If no option is specified, returns a list describing all + of the available options for pathName. If option is + specified with no value, then the command returns a list + describing the one named option (this list will be identical + to the corresponding sublist of the value returned if no + option is specified). If one or more option-value pairs are + specified, then the command modifies the given widget + option(s) to have the given value(s); in this case the + command returns an empty string. The following options + are supported: + + after window + Insert the window after the window specified. window + should be the name of a window already managed by pathName. + before window + Insert the window before the window specified. window + should be the name of a window already managed by pathName. + height size + Specify a height for the window. The height will be the + outer dimension of the window including its border, if + any. If size is an empty string, or if -height is not + specified, then the height requested internally by the + window will be used initially; the height may later be + adjusted by the movement of sashes in the panedwindow. + Size may be any value accepted by Tk_GetPixels. + minsize n + Specifies that the size of the window cannot be made + less than n. This constraint only affects the size of + the widget in the paned dimension -- the x dimension + for horizontal panedwindows, the y dimension for + vertical panedwindows. May be any value accepted by + Tk_GetPixels. + padx n + Specifies a non-negative value indicating how much + extra space to leave on each side of the window in + the X-direction. The value may have any of the forms + accepted by Tk_GetPixels. + pady n + Specifies a non-negative value indicating how much + extra space to leave on each side of the window in + the Y-direction. The value may have any of the forms + accepted by Tk_GetPixels. + sticky style + If a window's pane is larger than the requested + dimensions of the window, this option may be used + to position (or stretch) the window within its pane. + Style is a string that contains zero or more of the + characters n, s, e or w. The string can optionally + contains spaces or commas, but they are ignored. Each + letter refers to a side (north, south, east, or west) + that the window will "stick" to. If both n and s + (or e and w) are specified, the window will be + stretched to fill the entire height (or width) of + its cavity. + width size + Specify a width for the window. The width will be + the outer dimension of the window including its + border, if any. If size is an empty string, or + if -width is not specified, then the width requested + internally by the window will be used initially; the + width may later be adjusted by the movement of sashes + in the panedwindow. Size may be any value accepted by + Tk_GetPixels. + + 'b'paneconfigure'u'paneconfigure'b'Returns an ordered list of the child panes.'u'Returns an ordered list of the child panes.'b'panes'u'panes'b'This is Tcl/Tk version %s'u'This is Tcl/Tk version %s'b' +This should be a cedilla: ç'u' +This should be a cedilla: ç'b'Click me!'u'Click me!'b'[%s]'u'[%s]'b'QUIT'u'QUIT'u'tkinter.__init__'u'tkinter'Execute computations asynchronously using threads or processes.Brian Quinlan (brian@sweetapp.com)__author__concurrent.futures._baseFIRST_COMPLETEDFIRST_EXCEPTIONALL_COMPLETEDCancelledErrorInvalidStateErrorBrokenExecutorFutureExecutorwaitas_completedProcessPoolExecutorThreadPoolExecutorprocesspethreadtemodule has no attribute # Copyright 2009 Brian Quinlan. All Rights Reserved.b'Execute computations asynchronously using threads or processes.'u'Execute computations asynchronously using threads or processes.'b'Brian Quinlan (brian@sweetapp.com)'u'Brian Quinlan (brian@sweetapp.com)'b'FIRST_COMPLETED'u'FIRST_COMPLETED'b'FIRST_EXCEPTION'u'FIRST_EXCEPTION'b'ALL_COMPLETED'u'ALL_COMPLETED'b'CancelledError'u'CancelledError'b'TimeoutError'u'TimeoutError'b'BrokenExecutor'u'BrokenExecutor'b'Future'u'Future'b'Executor'u'Executor'b'wait'u'wait'b'as_completed'u'as_completed'b'ProcessPoolExecutor'u'ProcessPoolExecutor'b'ThreadPoolExecutor'u'ThreadPoolExecutor'b'__author__'u'__author__'b'__doc__'u'__doc__'b'module 'u'module 'b' has no attribute 'u' has no attribute 'u'concurrent.futures.__init__'u'concurrent.futures'u'concurrent'u'futures.__init__'u'futures'A package for parsing, handling, and generating email messages.base64mimecharsetencodersfeedparserheaderiteratorsmessage_from_filemessage_from_binary_filemessage_from_stringmessage_from_bytesmimequoprimimeutilskwsParse a string into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + email.parserParserparsestrParse a bytes string into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + BytesParserparsebytesfpRead a file and parse its contents into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + Read a binary file and parse its contents into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + # Copyright (C) 2001-2007 Python Software Foundation# Author: Barry Warsaw# Contact: email-sig@python.org# Some convenience routines. Don't import Parser and Message as side-effects# of importing email since those cascadingly import most of the rest of the# email package.b'A package for parsing, handling, and generating email messages.'u'A package for parsing, handling, and generating email messages.'b'base64mime'u'base64mime'b'charset'u'charset'b'encoders'u'encoders'b'errors'u'errors'b'feedparser'u'feedparser'b'generator'u'generator'b'header'u'header'b'iterators'u'iterators'b'message_from_file'u'message_from_file'b'message_from_binary_file'u'message_from_binary_file'b'message_from_string'u'message_from_string'b'message_from_bytes'u'message_from_bytes'b'mime'u'mime'b'parser'u'parser'b'quoprimime'u'quoprimime'b'utils'u'utils'b'Parse a string into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'u'Parse a string into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'b'Parse a bytes string into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'u'Parse a bytes string into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'b'Read a file and parse its contents into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'u'Read a file and parse its contents into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'b'Read a binary file and parse its contents into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'u'Read a binary file and parse its contents into a Message object model. + + Optional _class and strict are passed to the Parser constructor. + 'u'email.__init__'u'email'# Dummy file to make this directory a package.distutils + +The main package for the Python Module Distribution Utilities. Normally +used from a setup script as + + from distutils.core import setup + + setup (...) +b'distutils + +The main package for the Python Module Distribution Utilities. Normally +used from a setup script as + + from distutils.core import setup + + setup (...) +'u'distutils + +The main package for the Python Module Distribution Utilities. Normally +used from a setup script as + + from distutils.core import setup + + setup (...) +'u'distutils.__init__'u'distutils'The pgen2 package.# Copyright 2004-2005 Elemental Security, Inc. All Rights Reserved.b'The pgen2 package.'u'The pgen2 package.'u'lib2to3.pgen2.__init__'u'lib2to3.pgen2'u'lib2to3'u'pgen2.__init__'u'pgen2'#emptyu'lib2to3.__init__' Standard "encodings" Package + + Standard Python encoding modules are stored in this package + directory. + + Codec modules must have names corresponding to normalized encoding + names as defined in the normalize_encoding() function below, e.g. + 'utf-8' must be implemented by the module 'utf_8.py'. + + Each codec module must export the following interface: + + * getregentry() -> codecs.CodecInfo object + The getregentry() API must return a CodecInfo object with encoder, decoder, + incrementalencoder, incrementaldecoder, streamwriter and streamreader + attributes which adhere to the Python Codec Interface Standard. + + In addition, a module may optionally also define the following + APIs which are then used by the package's codec search function: + + * getaliases() -> sequence of encoding name strings to use as aliases + + Alias names returned by getaliases() must be normalized encoding + names as defined by normalize_encoding(). + +Written by Marc-Andre Lemburg (mal@lemburg.com). + +(c) Copyright CNRI, All Rights Reserved. NO WARRANTY. + +codecsaliases--unknown--_unknown_import_tail_aliasesCodecRegistryErrornormalize_encoding Normalize an encoding name. + + Normalization works as follows: all non-alphanumeric + characters except the dot used for Python package names are + collapsed and replaced with a single underscore, e.g. ' -;#' + becomes '_'. Leading and trailing underscores are removed. + + Note that encoding names should be ASCII only. + + punctsearch_functionnorm_encodingaliased_encodingmodnamesmodnameencodings.fromlistmodgetregentryCodecInfomodule "%s" (%s) failed to registerincompatible codecs in module "%s" (%s)getaliasescodecaliasesaliaswin32_alias_mbcs_winapicp%sGetACPansi_code_pageencodings.mbcsencodingsmbcs#"# Cache lookup# Import the module:# First try to find an alias for the normalized encoding# name and lookup the module using the aliased name, then try to# lookup the module using the standard import scheme, i.e. first# try in the encodings package, then at top-level.# Import is absolute to prevent the possibly malicious import of a# module with side-effects that is not in the 'encodings' package.# ImportError may occur because 'encodings.(modname)' does not exist,# or because it imports a name that does not exist (see mbcs and oem)# Not a codec module# Cache misses# Now ask the module for the registry entry# Cache the codec registry entry# Register its aliases (without overwriting previously registered# aliases)# Return the registry entry# Register the search_function in the Python codec registry# Imports may fail while we are shutting downb' Standard "encodings" Package + + Standard Python encoding modules are stored in this package + directory. + + Codec modules must have names corresponding to normalized encoding + names as defined in the normalize_encoding() function below, e.g. + 'utf-8' must be implemented by the module 'utf_8.py'. + + Each codec module must export the following interface: + + * getregentry() -> codecs.CodecInfo object + The getregentry() API must return a CodecInfo object with encoder, decoder, + incrementalencoder, incrementaldecoder, streamwriter and streamreader + attributes which adhere to the Python Codec Interface Standard. + + In addition, a module may optionally also define the following + APIs which are then used by the package's codec search function: + + * getaliases() -> sequence of encoding name strings to use as aliases + + Alias names returned by getaliases() must be normalized encoding + names as defined by normalize_encoding(). + +Written by Marc-Andre Lemburg (mal@lemburg.com). + +(c) Copyright CNRI, All Rights Reserved. NO WARRANTY. + +'u' Standard "encodings" Package + + Standard Python encoding modules are stored in this package + directory. + + Codec modules must have names corresponding to normalized encoding + names as defined in the normalize_encoding() function below, e.g. + 'utf-8' must be implemented by the module 'utf_8.py'. + + Each codec module must export the following interface: + + * getregentry() -> codecs.CodecInfo object + The getregentry() API must return a CodecInfo object with encoder, decoder, + incrementalencoder, incrementaldecoder, streamwriter and streamreader + attributes which adhere to the Python Codec Interface Standard. + + In addition, a module may optionally also define the following + APIs which are then used by the package's codec search function: + + * getaliases() -> sequence of encoding name strings to use as aliases + + Alias names returned by getaliases() must be normalized encoding + names as defined by normalize_encoding(). + +Written by Marc-Andre Lemburg (mal@lemburg.com). + +(c) Copyright CNRI, All Rights Reserved. NO WARRANTY. + +'b'--unknown--'u'--unknown--'b' Normalize an encoding name. + + Normalization works as follows: all non-alphanumeric + characters except the dot used for Python package names are + collapsed and replaced with a single underscore, e.g. ' -;#' + becomes '_'. Leading and trailing underscores are removed. + + Note that encoding names should be ASCII only. + + 'u' Normalize an encoding name. + + Normalization works as follows: all non-alphanumeric + characters except the dot used for Python package names are + collapsed and replaced with a single underscore, e.g. ' -;#' + becomes '_'. Leading and trailing underscores are removed. + + Note that encoding names should be ASCII only. + + 'b'ascii'u'ascii'b'encodings.'u'encodings.'b'module "%s" (%s) failed to register'u'module "%s" (%s) failed to register'b'incompatible codecs in module "%s" (%s)'u'incompatible codecs in module "%s" (%s)'b'win32'u'win32'b'cp%s'u'cp%s'u'encodings.__init__'u'encodings'# This directory is a Python package.u'concurrent.__init__'u'xmlrpc.__init__'u'xmlrpc'# $Id: __init__.py 3375 2008-02-13 08:05:08Z fredrik $# elementtree packageu'xml.etree.__init__'u'etree.__init__' +Logging package for Python. Based on PEP 282 and comments thereto in +comp.lang.python. + +Copyright (C) 2001-2017 Vinay Sajip. All Rights Reserved. + +To use, simply 'import logging' and log away! +weakrefTemplateFormatterStrFormatterBASIC_FORMATBufferingFormatterCRITICALDEBUGERRORFATALFileHandlerFilterHandlerINFOLogRecordLoggerLoggerAdapterNOTSETNullHandlerStreamHandlerWARNWARNINGaddLevelNamebasicConfigcaptureWarningscriticaldisableexceptionfatalgetLevelNamegetLoggergetLoggerClasslogmakeLogRecordsetLoggerClassshutdownwarninggetLogRecordFactorysetLogRecordFactorylastResortraiseExceptionsthreadingVinay Sajip production__status__0.5.1.207 February 2010__date___startTimelogThreadslogMultiprocessinglogProcesses5040_levelToName_nameToLevel + Return the textual or numeric representation of logging level 'level'. + + If the level is one of the predefined levels (CRITICAL, ERROR, WARNING, + INFO, DEBUG) then you get the corresponding string. If you have + associated levels with names using addLevelName then the name you have + associated with 'level' is returned. + + If a numeric value corresponding to one of the defined levels is passed + in, the corresponding string representation is returned. + + If a string representation of the level is passed in, the corresponding + numeric value is returned. + + If no matching numeric or string value is passed in, the string + 'Level %s' % level is returned. + Level %slevelName + Associate 'levelName' with 'level'. + + This is used when converting levels to text during message formatting. + _acquireLock_releaseLockcurrentframeReturn the frame object for the caller's stack frame.tb_framef_backnormcaseco_filename_srcfile_checkLevelrvUnknown level: %rLevel not an integer or a valid string: %rRLock_lock + Acquire the module-level lock for serializing access to shared data. + + This should be released with _releaseLock(). + acquire + Release the module-level lock acquired by calling _acquireLock(). + register_at_fork_register_at_fork_reinit_lockinstanceWeakSet_at_fork_reinit_lock_weakset_after_at_fork_child_reinit_lockscreateLockIgnoring exception from logging atfork._reinit_lock() method:beforeafter_in_childafter_in_parent + A LogRecord instance represents an event being logged. + + LogRecord instances are created every time something is logged. They + contain all the information pertinent to the event being logged. The + main information passed in is in msg and args, which are combined + using str(msg) % args to create the message field of the record. The + record also includes information such as when the record was created, + the source line where the logging call was made, and any exception + information to be logged. + sinfo + Initialize a logging record with interesting information. + ctlevelnamelevelnoUnknown moduleexc_textstack_infofuncNamecreated1000msecsrelativeCreatedget_identcurrent_threadthreadNameprocessNameMainProcessmultiprocessingmpcurrent_processgetpidgetMessage + Return the message for this LogRecord. + + Return the message for this LogRecord after merging any user-supplied + arguments with the message. + _logRecordFactory + Set the factory to be used when instantiating a log record. + + :param factory: A callable which will be called to instantiate + a log record. + + Return the factory to be used when instantiating a log record. + + Make a LogRecord whose attributes are defined by the specified dictionary, + This function is useful for converting a logging event received over + a socket connection (which is sent as a dictionary) into a LogRecord + instance. + _str_formatterPercentStyle%(message)sdefault_format%(asctime)sasctime_format%(asctime)asctime_search%\(\w+\)[#0+ -]*(\*|\d+)?(\.(\*|\d+))?[diouxefgcrsa%]Ivalidation_patternfmt_fmtusesTimevalidateValidate the input format, ensure it matches the correct styleInvalid format '%s' for '%s' style_formatrecordFormatting field not found in record: %sStrFormatStyle{message}{asctime}{asctime^(.?[<>=^])?[+ -]?#?0?(\d+|{\w+})?[,_]?(\.(\d+|{\w+}))?[bcdefgnosx%]?$fmt_spec^(\d+|\w+)(\.\w+|\[[^]]+\])*$field_specValidate the input format, ensure it is the correct string formatting stylefieldsfieldnameconversioninvalid field name/expression: %rrsainvalid conversion: %rbad specifier: %rinvalid format: %sinvalid format: no fieldsStringTemplateStyle${message}${asctime}_tpl$asctimefinditergroupdictnamedbracedinvalid format: bare '$' not allowedsubstitute%(levelname)s:%(name)s:%(message)s%{levelname}:{name}:{message}${levelname}:${name}:${message}_STYLES + Formatter instances are used to convert a LogRecord to text. + + Formatters need to know how a LogRecord is constructed. They are + responsible for converting a LogRecord to (usually) a string which can + be interpreted by either a human or an external system. The base Formatter + allows a formatting string to be specified. If none is supplied, the + style-dependent default value, "%(message)s", "{message}", or + "${message}", is used. + + The Formatter can be initialized with a format string which makes use of + knowledge of the LogRecord attributes - e.g. the default value mentioned + above makes use of the fact that the user's message and arguments are pre- + formatted into a LogRecord's message attribute. Currently, the useful + attributes in a LogRecord are described by: + + %(name)s Name of the logger (logging channel) + %(levelno)s Numeric logging level for the message (DEBUG, INFO, + WARNING, ERROR, CRITICAL) + %(levelname)s Text logging level for the message ("DEBUG", "INFO", + "WARNING", "ERROR", "CRITICAL") + %(pathname)s Full pathname of the source file where the logging + call was issued (if available) + %(filename)s Filename portion of pathname + %(module)s Module (name portion of filename) + %(lineno)d Source line number where the logging call was issued + (if available) + %(funcName)s Function name + %(created)f Time when the LogRecord was created (time.time() + return value) + %(asctime)s Textual time when the LogRecord was created + %(msecs)d Millisecond portion of the creation time + %(relativeCreated)d Time in milliseconds when the LogRecord was created, + relative to the time the logging module was loaded + (typically at application startup time) + %(thread)d Thread ID (if available) + %(threadName)s Thread name (if available) + %(process)d Process ID (if available) + %(message)s The result of record.getMessage(), computed just as + the record is emitted + localtimeconverterdatefmt + Initialize the formatter with specified format strings. + + Initialize the formatter either with the specified format string, or a + default as described above. Allow for specialized date formatting with + the optional datefmt argument. If datefmt is omitted, you get an + ISO8601-like (or RFC 3339-like) format. + + Use a style parameter of '%', '{' or '$' to specify that you want to + use one of %-formatting, :meth:`str.format` (``{}``) formatting or + :class:`string.Template` formatting in your format string. + + .. versionchanged:: 3.2 + Added the ``style`` parameter. + Style must be one of: %s,_style%Y-%m-%d %H:%M:%Sdefault_time_format%s,%03ddefault_msec_formatformatTime + Return the creation time of the specified LogRecord as formatted text. + + This method should be called from format() by a formatter which + wants to make use of a formatted time. This method can be overridden + in formatters to provide for any specific requirement, but the + basic behaviour is as follows: if datefmt (a string) is specified, + it is used with time.strftime() to format the creation time of the + record. Otherwise, an ISO8601-like (or RFC 3339-like) format is used. + The resulting string is returned. This function uses a user-configurable + function to convert the creation time to a tuple. By default, + time.localtime() is used; to change this for a particular formatter + instance, set the 'converter' attribute to a function with the same + signature as time.localtime() or time.gmtime(). To change it for all + formatters, for example if you want all logging times to be shown in GMT, + set the 'converter' attribute in the Formatter class. + strftimeformatExceptionei + Format and return the specified exception information as a string. + + This default implementation just uses + traceback.print_exception() + + Check if the format uses the creation time of the record. + formatMessageformatStack + This method is provided as an extension point for specialized + formatting of stack information. + + The input data is a string as returned from a call to + :func:`traceback.print_stack`, but with the last trailing newline + removed. + + The base implementation just returns the value passed in. + + Format the specified record as text. + + The record's attribute dictionary is used as the operand to a + string formatting operation which yields the returned string. + Before formatting the dictionary, a couple of preparatory steps + are carried out. The message attribute of the record is computed + using LogRecord.getMessage(). If the formatting string uses the + time (as determined by a call to usesTime(), formatTime() is + called to format the event time. If there is exception information, + it is formatted using formatException() and appended to the message. + asctime_defaultFormatter + A formatter suitable for formatting a number of records. + linefmt + Optionally specify a formatter which will be used to format each + individual record. + formatHeaderrecords + Return the header string for the specified records. + formatFooter + Return the footer string for the specified records. + + Format the specified records and return the result as a string. + + Filter instances are used to perform arbitrary filtering of LogRecords. + + Loggers and Handlers can optionally use Filter instances to filter + records as desired. The base filter class only allows events which are + below a certain point in the logger hierarchy. For example, a filter + initialized with "A.B" will allow events logged by loggers "A.B", + "A.B.C", "A.B.C.D", "A.B.D" etc. but not "A.BB", "B.A.B" etc. If + initialized with the empty string, all events are passed. + + Initialize a filter. + + Initialize with the name of the logger which, together with its + children, will have its events allowed through the filter. If no + name is specified, allow every event. + nlen + Determine if the specified record is to be logged. + + Returns True if the record should be logged, or False otherwise. + If deemed appropriate, the record may be modified in-place. + Filterer + A base class for loggers and handlers which allows them to share + common code. + + Initialize the list of filters to be an empty list. + filtersaddFilter + Add the specified filter to this handler. + removeFilter + Remove the specified filter from this handler. + + Determine if a record is loggable by consulting all the filters. + + The default is to allow the record to be logged; any filter can veto + this and the record is then dropped. Returns a zero value if a record + is to be dropped, else non-zero. + + .. versionchanged:: 3.2 + + Allow filters to be just callables. + WeakValueDictionary_handlers_handlerList_removeHandlerRefwr + Remove a handler reference from the internal cleanup list. + handlers_addHandlerRef + Add a handler to the internal cleanup list using a weak reference. + ref + Handler instances dispatch logging events to specific destinations. + + The base handler class. Acts as a placeholder which defines the Handler + interface. Handlers can optionally use Formatter instances to format + records as desired. By default, no formatter is specified; in this case, + the 'raw' message as determined by record.message is logged. + + Initializes the instance - basically setting the formatter to None + and the filter list to empty. + formatterget_nameset_name + Acquire a thread lock for serializing access to the underlying I/O. + + Acquire the I/O thread lock. + + Release the I/O thread lock. + setLevel + Set the logging level of this handler. level must be an int or a str. + + Format the specified record. + + If a formatter is set, use it. Otherwise, use the default formatter + for the module. + emit + Do whatever it takes to actually log the specified logging record. + + This version is intended to be implemented by subclasses and so + raises a NotImplementedError. + emit must be implemented by Handler subclasses'emit must be implemented ''by Handler subclasses' + Conditionally emit the specified logging record. + + Emission depends on filters which may have been added to the handler. + Wrap the actual emission of the record with acquisition/release of + the I/O thread lock. Returns whether the filter passed the record for + emission. + setFormatter + Set the formatter for this handler. + + Ensure all logging output has been flushed. + + This version does nothing and is intended to be implemented by + subclasses. + + Tidy up any resources used by the handler. + + This version removes the handler from an internal map of handlers, + _handlers, which is used for handler lookup by name. Subclasses + should ensure that this gets called from overridden close() + methods. + handleError + Handle errors which occur during an emit() call. + + This method should be called from handlers when an exception is + encountered during an emit() call. If raiseExceptions is false, + exceptions get silently ignored. This is what is mostly wanted + for a logging system - most users will not care about errors in + the logging system, they are more interested in application errors. + You could, however, replace this with a custom handler if you wish. + The record which was being processed is passed in to this method. + --- Logging error --- +Call stack: +f_codeprint_stackLogged from file %s, line %s +Message: %r +Arguments: %s +'Message: %r\n''Arguments: %s\n'Unable to print the message and arguments - possible formatting error. +Use the traceback above to help find the error. +'Unable to print the message and arguments'' - possible formatting error.\nUse the'' traceback above to help find the error.\n'<%s (%s)> + A handler class which writes logging records, appropriately formatted, + to a stream. Note that this class does not close the stream, as + sys.stdout or sys.stderr may be used. + terminator + Initialize the handler. + + If stream is not specified, sys.stderr is used. + + Flushes the stream. + + Emit a record. + + If a formatter is specified, it is used to format the record. + The record is then written to the stream with a trailing newline. If + exception information is present, it is formatted using + traceback.print_exception and appended to the stream. If the stream + has an 'encoding' attribute, it is used to determine how to do the + output to the stream. + setStream + Sets the StreamHandler's stream to the specified value, + if it is different. + + Returns the old stream, if the stream was changed, or None + if it wasn't. + <%s %s(%s)> + A handler class which writes formatted logging records to disk files. + adelay + Open the specified file and use it as the stream for logging. + fspathabspathbaseFilename_open + Closes the stream. + + Open the current base file with the (original) mode and encoding. + Return the resulting stream. + + Emit a record. + + If the stream was not opened because 'delay' was specified in the + constructor, open it before calling the superclass's emit. + <%s %s (%s)>_StderrHandler + This class is like a StreamHandler using sys.stderr, but always uses + whatever sys.stderr is currently set to rather than the value of + sys.stderr at handler construction time. + + Initialize the handler. + _defaultLastResortPlaceHolder + PlaceHolder instances are used in the Manager logger hierarchy to take + the place of nodes for which no loggers have been defined. This class is + intended for internal use only and not as part of the public API. + alogger + Initialize with the specified logger being a child of this placeholder. + loggerMap + Add the specified logger as a child of this placeholder. + klass + Set the class to be used when instantiating a logger. The class should + define __init__() such that only a name argument is required, and the + __init__() should call Logger.__init__() + logger not derived from logging.Logger: _loggerClass + Return the class to be used when instantiating a logger. + Manager + There is [under normal circumstances] just one Manager instance, which + holds the hierarchy of loggers. + rootnode + Initialize the manager with the root node of the logger hierarchy. + emittedNoHandlerWarningloggerDictloggerClasslogRecordFactory_disable + Get a logger with the specified name (channel name), creating it + if it doesn't yet exist. This name is a dot-separated hierarchical + name, such as "a", "a.b", "a.b.c" or similar. + + If a PlaceHolder existed for the specified name [i.e. the logger + didn't exist but a child of it did], replace it with the created + logger and fix up the parent/child references which pointed to the + placeholder to now point to the logger. + A logger name must be a stringph_fixupChildren_fixupParents + Set the class to be used when instantiating a logger with this Manager. + + Set the factory to be used when instantiating a log record with this + Manager. + + Ensure that there are either loggers or placeholders all the way + from the specified logger to the root of the logger hierarchy. + substr + Ensure that children of the placeholder ph are connected to the + specified logger. + namelen_clear_cache + Clear the cache for all loggers in loggerDict + Called when level changes are made + logger + Instances of the Logger class represent a single logging channel. A + "logging channel" indicates an area of an application. Exactly how an + "area" is defined is up to the application developer. Since an + application can have any number of areas, logging channels are identified + by a unique string. Application areas can be nested (e.g. an area + of "input processing" might include sub-areas "read CSV files", "read + XLS files" and "read Gnumeric files"). To cater for this natural nesting, + channel names are organized into a namespace hierarchy where levels are + separated by periods, much like the Java or Python package namespace. So + in the instance given above, channel names might be "input" for the upper + level, and "input.csv", "input.xls" and "input.gnu" for the sub-levels. + There is no arbitrary limit to the depth of nesting. + + Initialize the logger with a name and an optional level. + disabled + Set the logging level of this logger. level must be an int or a str. + + Log 'msg % args' with severity 'DEBUG'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.debug("Houston, we have a %s", "thorny problem", exc_info=1) + isEnabledFor_log + Log 'msg % args' with severity 'INFO'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.info("Houston, we have a %s", "interesting problem", exc_info=1) + + Log 'msg % args' with severity 'WARNING'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.warning("Houston, we have a %s", "bit of a problem", exc_info=1) + The 'warn' method is deprecated, use 'warning' instead"The 'warn' method is deprecated, ""use 'warning' instead" + Log 'msg % args' with severity 'ERROR'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.error("Houston, we have a %s", "major problem", exc_info=1) + + Convenience method for logging an ERROR with exception information. + + Log 'msg % args' with severity 'CRITICAL'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.critical("Houston, we have a %s", "major disaster", exc_info=1) + + Log 'msg % args' with the integer severity 'level'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.log(level, "We have a %s", "mysterious problem", exc_info=1) + level must be an integerfindCaller + Find the stack frame of the caller so that we can note the source + file name, line number and function name. + orig_f(unknown file)(unknown function)coStack (most recent call last): +f_linenoco_namemakeRecordfnlno + A factory method which can be overridden in subclasses to create + specialized LogRecords. + Attempt to overwrite %r in LogRecord + Low-level logging routine which creates a LogRecord and then calls + all the handlers of this logger to handle the record. + + Call the handlers for the specified record. + + This method is used for unpickled records received from a socket, as + well as those created locally. Logger-level filtering is applied. + callHandlersaddHandlerhdlr + Add the specified handler to this logger. + removeHandler + Remove the specified handler from this logger. + hasHandlers + See if this logger has any handlers configured. + + Loop through all handlers for this logger and its parents in the + logger hierarchy. Return True if a handler was found, else False. + Stop searching up the hierarchy whenever a logger with the "propagate" + attribute set to zero is found - that will be the last logger which + is checked for the existence of handlers. + + Pass a record to all relevant handlers. + + Loop through all handlers for this logger and its parents in the + logger hierarchy. If no handler was found, output a one-off error + message to sys.stderr. Stop searching up the hierarchy whenever a + logger with the "propagate" attribute set to zero is found - that + will be the last logger whose handlers are called. + foundNo handlers could be found for logger "%s" +"No handlers could be found for logger"" \"%s\"\n"getEffectiveLevel + Get the effective level for this logger. + + Loop through this logger and its parents in the logger hierarchy, + looking for a non-zero logging level. Return the first one found. + + Is this logger enabled for level 'level'? + is_enabledgetChild + Get a logger which is a descendant to this one. + + This is a convenience method, such that + + logging.getLogger('abc').getChild('def.ghi') + + is the same as + + logging.getLogger('abc.def.ghi') + + It's useful, for example, when the parent logger is named using + __name__ rather than a literal string. + picklePicklingErrorlogger cannot be pickledRootLogger + A root logger is not that different to any other logger, except that + it must have a logging level and there is only one instance of it in + the hierarchy. + + Initialize the logger with the name "root". + + An adapter for loggers which makes it easier to specify contextual + information in logging output. + + Initialize the adapter with a logger and a dict-like object which + provides contextual information. This constructor signature allows + easy stacking of LoggerAdapters, if so desired. + + You can effectively pass keyword arguments as shown in the + following example: + + adapter = LoggerAdapter(someLogger, dict(p1=v1, p2="v2")) + + Process the logging message and keyword arguments passed in to + a logging call to insert contextual information. You can either + manipulate the message itself, the keyword args or both. Return + the message and kwargs modified (or not) to suit your needs. + + Normally, you'll only need to override this one method in a + LoggerAdapter subclass for your specific needs. + + Delegate a debug call to the underlying logger. + + Delegate an info call to the underlying logger. + + Delegate a warning call to the underlying logger. + + Delegate an error call to the underlying logger. + + Delegate an exception call to the underlying logger. + + Delegate a critical call to the underlying logger. + + Delegate a log call to the underlying logger, after adding + contextual information from this adapter instance. + + Set the specified level on the underlying logger. + + Get the effective level for the underlying logger. + + See if the underlying logger has any handlers. + + Low-level log implementation, proxied to allow nested logger adapters. + + Do basic configuration for the logging system. + + This function does nothing if the root logger already has handlers + configured, unless the keyword argument *force* is set to ``True``. + It is a convenience method intended for use by simple scripts + to do one-shot configuration of the logging package. + + The default behaviour is to create a StreamHandler which writes to + sys.stderr, set a formatter using the BASIC_FORMAT format string, and + add the handler to the root logger. + + A number of optional keyword arguments may be specified, which can alter + the default behaviour. + + filename Specifies that a FileHandler be created, using the specified + filename, rather than a StreamHandler. + filemode Specifies the mode to open the file, if filename is specified + (if filemode is unspecified, it defaults to 'a'). + format Use the specified format string for the handler. + datefmt Use the specified date/time format. + style If a format string is specified, use this to specify the + type of format string (possible values '%', '{', '$', for + %-formatting, :meth:`str.format` and :class:`string.Template` + - defaults to '%'). + level Set the root logger level to the specified level. + stream Use the specified stream to initialize the StreamHandler. Note + that this argument is incompatible with 'filename' - if both + are present, 'stream' is ignored. + handlers If specified, this should be an iterable of already created + handlers, which will be added to the root handler. Any handler + in the list which does not have a formatter assigned will be + assigned the formatter created in this function. + force If this keyword is specified as true, any existing handlers + attached to the root logger are removed and closed, before + carrying out the configuration as specified by the other + arguments. + Note that you could specify a stream created using open(filename, mode) + rather than passing the filename and mode in. However, it should be + remembered that StreamHandler does not close its stream (since it may be + using sys.stdout or sys.stderr), whereas FileHandler closes its stream + when the handler is closed. + + .. versionchanged:: 3.8 + Added the ``force`` parameter. + + .. versionchanged:: 3.2 + Added the ``style`` parameter. + + .. versionchanged:: 3.3 + Added the ``handlers`` parameter. A ``ValueError`` is now thrown for + incompatible arguments (e.g. ``handlers`` specified together with + ``filename``/``filemode``, or ``filename``/``filemode`` specified + together with ``stream``, or ``handlers`` specified together with + ``stream``. + force'stream' and 'filename' should not be specified together"'stream' and 'filename' should not be ""specified together"'stream' or 'filename' should not be specified together with 'handlers'"'stream' or 'filename' should not be ""specified together with 'handlers'"filemodedfsfs, Unrecognised argument(s): %s + Return a logger with the specified name, creating it if necessary. + + If no name is specified, return the root logger. + + Log a message with severity 'CRITICAL' on the root logger. If the logger + has no handlers, call basicConfig() to add a console handler with a + pre-defined format. + + Log a message with severity 'ERROR' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + + Log a message with severity 'ERROR' on the root logger, with exception + information. If the logger has no handlers, basicConfig() is called to add + a console handler with a pre-defined format. + + Log a message with severity 'WARNING' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + The 'warn' function is deprecated, use 'warning' instead"The 'warn' function is deprecated, " + Log a message with severity 'INFO' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + + Log a message with severity 'DEBUG' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + + Log 'msg % args' with the integer severity 'level' on the root logger. If + the logger has no handlers, call basicConfig() to add a console handler + with a pre-defined format. + + Disable all logging calls of severity 'level' and below. + handlerList + Perform any cleanup actions in the logging system (e.g. flushing + buffers). + + Should be called at application exit. + atexit + This handler does nothing. It's intended to be used to avoid the + "No handlers could be found for logger XXX" one-off warning. This is + important for library code, which may contain code to log events. If a user + of the library does not configure logging, the one-off warning might be + produced; to avoid this, the library developer simply needs to instantiate + a NullHandler and add it to the top-level logger of the library module or + package. + Stub._warnings_showwarning_showwarningcategory + Implementation of showwarnings which redirects to logging, which will first + check to see if the file parameter is None. If a file is specified, it will + delegate to the original warnings implementation of showwarning. Otherwise, + it will call warnings.formatwarning and will log the resulting string to a + warnings logger named "py.warnings" with level logging.WARNING. + formatwarningpy.warningscapture + If capture is true, redirect all warnings to the logging package. + If capture is False, ensure that warnings are not redirected to logging + but to their original destinations. + showwarning# Copyright 2001-2017 by Vinay Sajip. All Rights Reserved.# Permission to use, copy, modify, and distribute this software and its# documentation for any purpose and without fee is hereby granted,# provided that the above copyright notice appear in all copies and that# both that copyright notice and this permission notice appear in# supporting documentation, and that the name of Vinay Sajip# not be used in advertising or publicity pertaining to distribution# of the software without specific, written prior permission.# VINAY SAJIP DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING# ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL# VINAY SAJIP BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR# ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER# IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT# OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.# The following module attributes are no longer updated.#---------------------------------------------------------------------------# Miscellaneous module data#_startTime is used as the base when calculating the relative time of events#raiseExceptions is used to see if exceptions during handling should be#propagated# If you don't want threading information in the log, set this to zero# If you don't want multiprocessing information in the log, set this to zero# If you don't want process information in the log, set this to zero# Level related stuff# Default levels and level names, these can be replaced with any positive set# of values having corresponding names. There is a pseudo-level, NOTSET, which# is only really there as a lower limit for user-defined levels. Handlers and# loggers are initialized with NOTSET so that they will log all messages, even# at user-defined levels.# See Issues #22386, #27937 and #29220 for why it's this way#unlikely to cause an exception, but you never know...#pragma: no cover# _srcfile is used when walking the stack to check when we've got the first# caller stack frame, by skipping frames whose filename is that of this# module's source. It therefore should contain the filename of this module's# source file.# Ordinarily we would use __file__ for this, but frozen modules don't always# have __file__ set, for some reason (see Issue #21736). Thus, we get the# filename from a handy code object from a function defined in this module.# (There's no particular reason for picking addLevelName.)# _srcfile is only used in conjunction with sys._getframe().# To provide compatibility with older versions of Python, set _srcfile# to None if _getframe() is not available; this value will prevent# findCaller() from being called. You can also do this if you want to avoid# the overhead of fetching caller information, even when _getframe() is# available.#if not hasattr(sys, '_getframe'):# _srcfile = None# Thread-related stuff#_lock is used to serialize access to shared data structures in this module.#This needs to be an RLock because fileConfig() creates and configures#Handlers, and so might arbitrary user threads. Since Handler code updates the#shared dictionary _handlers, it needs to acquire the lock. But if configuring,#the lock would already have been acquired - so we need an RLock.#The same argument applies to Loggers and Manager.loggerDict.# Prevent a held logging lock from blocking a child from logging.# Windows and friends.# no-op when os.register_at_fork does not exist.# A collection of instances with a createLock method (logging.Handler)# to be called in the child after forking. The weakref avoids us keeping# discarded Handler instances alive. A set is used to avoid accumulating# duplicate registrations as createLock() is responsible for registering# a new Handler instance with this set in the first place.# _acquireLock() was called in the parent before forking.# Similar to what PyErr_WriteUnraisable does.# Acquired by os.register_at_fork(before=.# The logging record# The following statement allows passing of a dictionary as a sole# argument, so that you can do something like# logging.debug("a %(a)d b %(b)s", {'a':1, 'b':2})# Suggested by Stefan Behnel.# Note that without the test for args[0], we get a problem because# during formatting, we test to see if the arg is present using# 'if self.args:'. If the event being logged is e.g. 'Value is %d'# and if the passed arg fails 'if self.args:' then no formatting# is done. For example, logger.warning('Value is %d', 0) would log# 'Value is %d' instead of 'Value is 0'.# For the use case of passing a dictionary, this should not be a# problem.# Issue #21172: a request was made to relax the isinstance check# to hasattr(args[0], '__getitem__'). However, the docs on string# formatting still seem to suggest a mapping object is required.# Thus, while not removing the isinstance check, it does now look# for collections.abc.Mapping rather than, as before, dict.# used to cache the traceback text# pragma: no cover# Errors may occur if multiprocessing has not finished loading# yet - e.g. if a custom import hook causes third-party code# to run when multiprocessing calls import. See issue 8200# for an example# Determine which class to use when instantiating log records.# Formatter classes and functions# See issues #9427, #1553375. Commented out for now.#if getattr(self, 'fullstack', False):# traceback.print_stack(tb.tb_frame.f_back, file=sio)# Cache the traceback text to avoid converting it multiple times# (it's constant anyway)# The default formatter to use when no other is specified# Filter classes and functions# assume callable - will raise if not# Handler classes and functions#map of handler names to handlers# added to allow handlers to be removed in reverse of order initialized# This function can be called during module teardown, when globals are# set to None. It can also be called from another thread. So we need to# pre-emptively grab the necessary globals and check if they're None,# to prevent race conditions and failures during interpreter shutdown.# Add the handler to the global _handlerList (for cleanup on shutdown)#get the module data lock, as we're updating a shared structure.#unlikely to raise an exception, but you never know...# see issue 13807# Walk the stack frame up until we're out of logging,# so as to print the calling context.# couldn't find the right stack frame, for some reason# Issue 18671: output logging message and arguments# See issue 36272# see issue 5971# issue 35046: merged two stream.writes into one.# bpo-36015: name can be an int# Issue #27493: add support for Path objects to be passed in#keep the absolute path, otherwise derived classes which use this#may come a cropper when the current directory changes#We don't open the stream, but we still need to call the#Handler constructor to set level, formatter, lock etc.# Issue #19523: call unconditionally to# prevent a handler leak when delay is set# Manager classes and functions# Determine which class to use when instantiating loggers.#The if means ... if not c.parent.name.startswith(nm)# Logger classes and functions#On some versions of IronPython, currentframe() returns None if#IronPython isn't run with -X:Frames.#IronPython doesn't track Python frames, so findCaller raises an#exception on some versions of IronPython. We trap it here so that#IronPython can use logging.#break out# In general, only the root logger will not be accessible via its name.# However, the root logger's class has its own __reduce__ method.# Boilerplate convenience methods# Configuration classes and functions# Add thread safety in case someone mistakenly calls# basicConfig() from multiple threads# Utility functions at module level.# Basically delegate everything to the root logger.#errors might occur, for example, if files are locked#we just ignore them if raiseExceptions is not set# Ignore errors which might be caused# because handlers have been closed but# references to them are still around at# application exit.# ignore everything, as we're shutting down#else, swallow#Let's try and shutdown automatically on application exit...# Null handler# Warnings integrationb' +Logging package for Python. Based on PEP 282 and comments thereto in +comp.lang.python. + +Copyright (C) 2001-2017 Vinay Sajip. All Rights Reserved. + +To use, simply 'import logging' and log away! +'u' +Logging package for Python. Based on PEP 282 and comments thereto in +comp.lang.python. + +Copyright (C) 2001-2017 Vinay Sajip. All Rights Reserved. + +To use, simply 'import logging' and log away! +'b'BASIC_FORMAT'u'BASIC_FORMAT'b'BufferingFormatter'u'BufferingFormatter'b'CRITICAL'u'CRITICAL'b'DEBUG'u'DEBUG'b'ERROR'u'ERROR'b'FATAL'u'FATAL'b'FileHandler'u'FileHandler'b'Filter'u'Filter'b'Formatter'u'Formatter'b'Handler'u'Handler'b'INFO'u'INFO'b'LogRecord'u'LogRecord'b'Logger'u'Logger'b'LoggerAdapter'u'LoggerAdapter'b'NOTSET'u'NOTSET'b'NullHandler'u'NullHandler'b'StreamHandler'u'StreamHandler'b'WARN'u'WARN'b'WARNING'u'WARNING'b'addLevelName'u'addLevelName'b'basicConfig'u'basicConfig'b'captureWarnings'u'captureWarnings'b'critical'u'critical'b'disable'u'disable'b'error'u'error'b'exception'u'exception'b'fatal'u'fatal'b'getLevelName'u'getLevelName'b'getLogger'u'getLogger'b'getLoggerClass'u'getLoggerClass'b'log'u'log'b'makeLogRecord'u'makeLogRecord'b'setLoggerClass'u'setLoggerClass'b'shutdown'u'shutdown'b'warn'u'warn'b'warning'u'warning'b'getLogRecordFactory'u'getLogRecordFactory'b'setLogRecordFactory'u'setLogRecordFactory'b'lastResort'u'lastResort'b'raiseExceptions'u'raiseExceptions'b'Vinay Sajip 'u'Vinay Sajip 'b'production'u'production'b'0.5.1.2'u'0.5.1.2'b'07 February 2010'u'07 February 2010'b' + Return the textual or numeric representation of logging level 'level'. + + If the level is one of the predefined levels (CRITICAL, ERROR, WARNING, + INFO, DEBUG) then you get the corresponding string. If you have + associated levels with names using addLevelName then the name you have + associated with 'level' is returned. + + If a numeric value corresponding to one of the defined levels is passed + in, the corresponding string representation is returned. + + If a string representation of the level is passed in, the corresponding + numeric value is returned. + + If no matching numeric or string value is passed in, the string + 'Level %s' % level is returned. + 'u' + Return the textual or numeric representation of logging level 'level'. + + If the level is one of the predefined levels (CRITICAL, ERROR, WARNING, + INFO, DEBUG) then you get the corresponding string. If you have + associated levels with names using addLevelName then the name you have + associated with 'level' is returned. + + If a numeric value corresponding to one of the defined levels is passed + in, the corresponding string representation is returned. + + If a string representation of the level is passed in, the corresponding + numeric value is returned. + + If no matching numeric or string value is passed in, the string + 'Level %s' % level is returned. + 'b'Level %s'u'Level %s'b' + Associate 'levelName' with 'level'. + + This is used when converting levels to text during message formatting. + 'u' + Associate 'levelName' with 'level'. + + This is used when converting levels to text during message formatting. + 'b'_getframe'u'_getframe'b'Return the frame object for the caller's stack frame.'u'Return the frame object for the caller's stack frame.'b'Unknown level: %r'u'Unknown level: %r'b'Level not an integer or a valid string: %r'u'Level not an integer or a valid string: %r'b' + Acquire the module-level lock for serializing access to shared data. + + This should be released with _releaseLock(). + 'u' + Acquire the module-level lock for serializing access to shared data. + + This should be released with _releaseLock(). + 'b' + Release the module-level lock acquired by calling _acquireLock(). + 'u' + Release the module-level lock acquired by calling _acquireLock(). + 'b'register_at_fork'u'register_at_fork'b'Ignoring exception from logging atfork'u'Ignoring exception from logging atfork'b'._reinit_lock() method:'u'._reinit_lock() method:'b' + A LogRecord instance represents an event being logged. + + LogRecord instances are created every time something is logged. They + contain all the information pertinent to the event being logged. The + main information passed in is in msg and args, which are combined + using str(msg) % args to create the message field of the record. The + record also includes information such as when the record was created, + the source line where the logging call was made, and any exception + information to be logged. + 'u' + A LogRecord instance represents an event being logged. + + LogRecord instances are created every time something is logged. They + contain all the information pertinent to the event being logged. The + main information passed in is in msg and args, which are combined + using str(msg) % args to create the message field of the record. The + record also includes information such as when the record was created, + the source line where the logging call was made, and any exception + information to be logged. + 'b' + Initialize a logging record with interesting information. + 'u' + Initialize a logging record with interesting information. + 'b'Unknown module'u'Unknown module'b'MainProcess'u'MainProcess'b'multiprocessing'b'getpid'u'getpid'b''u''b' + Return the message for this LogRecord. + + Return the message for this LogRecord after merging any user-supplied + arguments with the message. + 'u' + Return the message for this LogRecord. + + Return the message for this LogRecord after merging any user-supplied + arguments with the message. + 'b' + Set the factory to be used when instantiating a log record. + + :param factory: A callable which will be called to instantiate + a log record. + 'u' + Set the factory to be used when instantiating a log record. + + :param factory: A callable which will be called to instantiate + a log record. + 'b' + Return the factory to be used when instantiating a log record. + 'u' + Return the factory to be used when instantiating a log record. + 'b' + Make a LogRecord whose attributes are defined by the specified dictionary, + This function is useful for converting a logging event received over + a socket connection (which is sent as a dictionary) into a LogRecord + instance. + 'u' + Make a LogRecord whose attributes are defined by the specified dictionary, + This function is useful for converting a logging event received over + a socket connection (which is sent as a dictionary) into a LogRecord + instance. + 'b'%(message)s'u'%(message)s'b'%(asctime)s'u'%(asctime)s'b'%(asctime)'u'%(asctime)'b'%\(\w+\)[#0+ -]*(\*|\d+)?(\.(\*|\d+))?[diouxefgcrsa%]'u'%\(\w+\)[#0+ -]*(\*|\d+)?(\.(\*|\d+))?[diouxefgcrsa%]'b'Validate the input format, ensure it matches the correct style'u'Validate the input format, ensure it matches the correct style'b'Invalid format '%s' for '%s' style'u'Invalid format '%s' for '%s' style'b'Formatting field not found in record: %s'u'Formatting field not found in record: %s'b'{message}'u'{message}'b'{asctime}'u'{asctime}'b'{asctime'u'{asctime'b'^(.?[<>=^])?[+ -]?#?0?(\d+|{\w+})?[,_]?(\.(\d+|{\w+}))?[bcdefgnosx%]?$'u'^(.?[<>=^])?[+ -]?#?0?(\d+|{\w+})?[,_]?(\.(\d+|{\w+}))?[bcdefgnosx%]?$'b'^(\d+|\w+)(\.\w+|\[[^]]+\])*$'u'^(\d+|\w+)(\.\w+|\[[^]]+\])*$'b'Validate the input format, ensure it is the correct string formatting style'u'Validate the input format, ensure it is the correct string formatting style'b'invalid field name/expression: %r'u'invalid field name/expression: %r'b'rsa'u'rsa'b'invalid conversion: %r'u'invalid conversion: %r'b'bad specifier: %r'u'bad specifier: %r'b'invalid format: %s'u'invalid format: %s'b'invalid format: no fields'u'invalid format: no fields'b'${message}'u'${message}'b'${asctime}'u'${asctime}'b'$asctime'u'$asctime'b'named'u'named'b'braced'u'braced'b'$'u'$'b'invalid format: bare '$' not allowed'u'invalid format: bare '$' not allowed'b'%(levelname)s:%(name)s:%(message)s'u'%(levelname)s:%(name)s:%(message)s'b'%'u'%'b'{levelname}:{name}:{message}'u'{levelname}:{name}:{message}'b'${levelname}:${name}:${message}'u'${levelname}:${name}:${message}'b' + Formatter instances are used to convert a LogRecord to text. + + Formatters need to know how a LogRecord is constructed. They are + responsible for converting a LogRecord to (usually) a string which can + be interpreted by either a human or an external system. The base Formatter + allows a formatting string to be specified. If none is supplied, the + style-dependent default value, "%(message)s", "{message}", or + "${message}", is used. + + The Formatter can be initialized with a format string which makes use of + knowledge of the LogRecord attributes - e.g. the default value mentioned + above makes use of the fact that the user's message and arguments are pre- + formatted into a LogRecord's message attribute. Currently, the useful + attributes in a LogRecord are described by: + + %(name)s Name of the logger (logging channel) + %(levelno)s Numeric logging level for the message (DEBUG, INFO, + WARNING, ERROR, CRITICAL) + %(levelname)s Text logging level for the message ("DEBUG", "INFO", + "WARNING", "ERROR", "CRITICAL") + %(pathname)s Full pathname of the source file where the logging + call was issued (if available) + %(filename)s Filename portion of pathname + %(module)s Module (name portion of filename) + %(lineno)d Source line number where the logging call was issued + (if available) + %(funcName)s Function name + %(created)f Time when the LogRecord was created (time.time() + return value) + %(asctime)s Textual time when the LogRecord was created + %(msecs)d Millisecond portion of the creation time + %(relativeCreated)d Time in milliseconds when the LogRecord was created, + relative to the time the logging module was loaded + (typically at application startup time) + %(thread)d Thread ID (if available) + %(threadName)s Thread name (if available) + %(process)d Process ID (if available) + %(message)s The result of record.getMessage(), computed just as + the record is emitted + 'u' + Formatter instances are used to convert a LogRecord to text. + + Formatters need to know how a LogRecord is constructed. They are + responsible for converting a LogRecord to (usually) a string which can + be interpreted by either a human or an external system. The base Formatter + allows a formatting string to be specified. If none is supplied, the + style-dependent default value, "%(message)s", "{message}", or + "${message}", is used. + + The Formatter can be initialized with a format string which makes use of + knowledge of the LogRecord attributes - e.g. the default value mentioned + above makes use of the fact that the user's message and arguments are pre- + formatted into a LogRecord's message attribute. Currently, the useful + attributes in a LogRecord are described by: + + %(name)s Name of the logger (logging channel) + %(levelno)s Numeric logging level for the message (DEBUG, INFO, + WARNING, ERROR, CRITICAL) + %(levelname)s Text logging level for the message ("DEBUG", "INFO", + "WARNING", "ERROR", "CRITICAL") + %(pathname)s Full pathname of the source file where the logging + call was issued (if available) + %(filename)s Filename portion of pathname + %(module)s Module (name portion of filename) + %(lineno)d Source line number where the logging call was issued + (if available) + %(funcName)s Function name + %(created)f Time when the LogRecord was created (time.time() + return value) + %(asctime)s Textual time when the LogRecord was created + %(msecs)d Millisecond portion of the creation time + %(relativeCreated)d Time in milliseconds when the LogRecord was created, + relative to the time the logging module was loaded + (typically at application startup time) + %(thread)d Thread ID (if available) + %(threadName)s Thread name (if available) + %(process)d Process ID (if available) + %(message)s The result of record.getMessage(), computed just as + the record is emitted + 'b' + Initialize the formatter with specified format strings. + + Initialize the formatter either with the specified format string, or a + default as described above. Allow for specialized date formatting with + the optional datefmt argument. If datefmt is omitted, you get an + ISO8601-like (or RFC 3339-like) format. + + Use a style parameter of '%', '{' or '$' to specify that you want to + use one of %-formatting, :meth:`str.format` (``{}``) formatting or + :class:`string.Template` formatting in your format string. + + .. versionchanged:: 3.2 + Added the ``style`` parameter. + 'u' + Initialize the formatter with specified format strings. + + Initialize the formatter either with the specified format string, or a + default as described above. Allow for specialized date formatting with + the optional datefmt argument. If datefmt is omitted, you get an + ISO8601-like (or RFC 3339-like) format. + + Use a style parameter of '%', '{' or '$' to specify that you want to + use one of %-formatting, :meth:`str.format` (``{}``) formatting or + :class:`string.Template` formatting in your format string. + + .. versionchanged:: 3.2 + Added the ``style`` parameter. + 'b'Style must be one of: %s'u'Style must be one of: %s'b','u','b'%Y-%m-%d %H:%M:%S'u'%Y-%m-%d %H:%M:%S'b'%s,%03d'u'%s,%03d'b' + Return the creation time of the specified LogRecord as formatted text. + + This method should be called from format() by a formatter which + wants to make use of a formatted time. This method can be overridden + in formatters to provide for any specific requirement, but the + basic behaviour is as follows: if datefmt (a string) is specified, + it is used with time.strftime() to format the creation time of the + record. Otherwise, an ISO8601-like (or RFC 3339-like) format is used. + The resulting string is returned. This function uses a user-configurable + function to convert the creation time to a tuple. By default, + time.localtime() is used; to change this for a particular formatter + instance, set the 'converter' attribute to a function with the same + signature as time.localtime() or time.gmtime(). To change it for all + formatters, for example if you want all logging times to be shown in GMT, + set the 'converter' attribute in the Formatter class. + 'u' + Return the creation time of the specified LogRecord as formatted text. + + This method should be called from format() by a formatter which + wants to make use of a formatted time. This method can be overridden + in formatters to provide for any specific requirement, but the + basic behaviour is as follows: if datefmt (a string) is specified, + it is used with time.strftime() to format the creation time of the + record. Otherwise, an ISO8601-like (or RFC 3339-like) format is used. + The resulting string is returned. This function uses a user-configurable + function to convert the creation time to a tuple. By default, + time.localtime() is used; to change this for a particular formatter + instance, set the 'converter' attribute to a function with the same + signature as time.localtime() or time.gmtime(). To change it for all + formatters, for example if you want all logging times to be shown in GMT, + set the 'converter' attribute in the Formatter class. + 'b' + Format and return the specified exception information as a string. + + This default implementation just uses + traceback.print_exception() + 'u' + Format and return the specified exception information as a string. + + This default implementation just uses + traceback.print_exception() + 'b' + Check if the format uses the creation time of the record. + 'u' + Check if the format uses the creation time of the record. + 'b' + This method is provided as an extension point for specialized + formatting of stack information. + + The input data is a string as returned from a call to + :func:`traceback.print_stack`, but with the last trailing newline + removed. + + The base implementation just returns the value passed in. + 'u' + This method is provided as an extension point for specialized + formatting of stack information. + + The input data is a string as returned from a call to + :func:`traceback.print_stack`, but with the last trailing newline + removed. + + The base implementation just returns the value passed in. + 'b' + Format the specified record as text. + + The record's attribute dictionary is used as the operand to a + string formatting operation which yields the returned string. + Before formatting the dictionary, a couple of preparatory steps + are carried out. The message attribute of the record is computed + using LogRecord.getMessage(). If the formatting string uses the + time (as determined by a call to usesTime(), formatTime() is + called to format the event time. If there is exception information, + it is formatted using formatException() and appended to the message. + 'u' + Format the specified record as text. + + The record's attribute dictionary is used as the operand to a + string formatting operation which yields the returned string. + Before formatting the dictionary, a couple of preparatory steps + are carried out. The message attribute of the record is computed + using LogRecord.getMessage(). If the formatting string uses the + time (as determined by a call to usesTime(), formatTime() is + called to format the event time. If there is exception information, + it is formatted using formatException() and appended to the message. + 'b' + A formatter suitable for formatting a number of records. + 'u' + A formatter suitable for formatting a number of records. + 'b' + Optionally specify a formatter which will be used to format each + individual record. + 'u' + Optionally specify a formatter which will be used to format each + individual record. + 'b' + Return the header string for the specified records. + 'u' + Return the header string for the specified records. + 'b' + Return the footer string for the specified records. + 'u' + Return the footer string for the specified records. + 'b' + Format the specified records and return the result as a string. + 'u' + Format the specified records and return the result as a string. + 'b' + Filter instances are used to perform arbitrary filtering of LogRecords. + + Loggers and Handlers can optionally use Filter instances to filter + records as desired. The base filter class only allows events which are + below a certain point in the logger hierarchy. For example, a filter + initialized with "A.B" will allow events logged by loggers "A.B", + "A.B.C", "A.B.C.D", "A.B.D" etc. but not "A.BB", "B.A.B" etc. If + initialized with the empty string, all events are passed. + 'u' + Filter instances are used to perform arbitrary filtering of LogRecords. + + Loggers and Handlers can optionally use Filter instances to filter + records as desired. The base filter class only allows events which are + below a certain point in the logger hierarchy. For example, a filter + initialized with "A.B" will allow events logged by loggers "A.B", + "A.B.C", "A.B.C.D", "A.B.D" etc. but not "A.BB", "B.A.B" etc. If + initialized with the empty string, all events are passed. + 'b' + Initialize a filter. + + Initialize with the name of the logger which, together with its + children, will have its events allowed through the filter. If no + name is specified, allow every event. + 'u' + Initialize a filter. + + Initialize with the name of the logger which, together with its + children, will have its events allowed through the filter. If no + name is specified, allow every event. + 'b' + Determine if the specified record is to be logged. + + Returns True if the record should be logged, or False otherwise. + If deemed appropriate, the record may be modified in-place. + 'u' + Determine if the specified record is to be logged. + + Returns True if the record should be logged, or False otherwise. + If deemed appropriate, the record may be modified in-place. + 'b' + A base class for loggers and handlers which allows them to share + common code. + 'u' + A base class for loggers and handlers which allows them to share + common code. + 'b' + Initialize the list of filters to be an empty list. + 'u' + Initialize the list of filters to be an empty list. + 'b' + Add the specified filter to this handler. + 'u' + Add the specified filter to this handler. + 'b' + Remove the specified filter from this handler. + 'u' + Remove the specified filter from this handler. + 'b' + Determine if a record is loggable by consulting all the filters. + + The default is to allow the record to be logged; any filter can veto + this and the record is then dropped. Returns a zero value if a record + is to be dropped, else non-zero. + + .. versionchanged:: 3.2 + + Allow filters to be just callables. + 'u' + Determine if a record is loggable by consulting all the filters. + + The default is to allow the record to be logged; any filter can veto + this and the record is then dropped. Returns a zero value if a record + is to be dropped, else non-zero. + + .. versionchanged:: 3.2 + + Allow filters to be just callables. + 'b'filter'u'filter'b' + Remove a handler reference from the internal cleanup list. + 'u' + Remove a handler reference from the internal cleanup list. + 'b' + Add a handler to the internal cleanup list using a weak reference. + 'u' + Add a handler to the internal cleanup list using a weak reference. + 'b' + Handler instances dispatch logging events to specific destinations. + + The base handler class. Acts as a placeholder which defines the Handler + interface. Handlers can optionally use Formatter instances to format + records as desired. By default, no formatter is specified; in this case, + the 'raw' message as determined by record.message is logged. + 'u' + Handler instances dispatch logging events to specific destinations. + + The base handler class. Acts as a placeholder which defines the Handler + interface. Handlers can optionally use Formatter instances to format + records as desired. By default, no formatter is specified; in this case, + the 'raw' message as determined by record.message is logged. + 'b' + Initializes the instance - basically setting the formatter to None + and the filter list to empty. + 'u' + Initializes the instance - basically setting the formatter to None + and the filter list to empty. + 'b' + Acquire a thread lock for serializing access to the underlying I/O. + 'u' + Acquire a thread lock for serializing access to the underlying I/O. + 'b' + Acquire the I/O thread lock. + 'u' + Acquire the I/O thread lock. + 'b' + Release the I/O thread lock. + 'u' + Release the I/O thread lock. + 'b' + Set the logging level of this handler. level must be an int or a str. + 'u' + Set the logging level of this handler. level must be an int or a str. + 'b' + Format the specified record. + + If a formatter is set, use it. Otherwise, use the default formatter + for the module. + 'u' + Format the specified record. + + If a formatter is set, use it. Otherwise, use the default formatter + for the module. + 'b' + Do whatever it takes to actually log the specified logging record. + + This version is intended to be implemented by subclasses and so + raises a NotImplementedError. + 'u' + Do whatever it takes to actually log the specified logging record. + + This version is intended to be implemented by subclasses and so + raises a NotImplementedError. + 'b'emit must be implemented by Handler subclasses'u'emit must be implemented by Handler subclasses'b' + Conditionally emit the specified logging record. + + Emission depends on filters which may have been added to the handler. + Wrap the actual emission of the record with acquisition/release of + the I/O thread lock. Returns whether the filter passed the record for + emission. + 'u' + Conditionally emit the specified logging record. + + Emission depends on filters which may have been added to the handler. + Wrap the actual emission of the record with acquisition/release of + the I/O thread lock. Returns whether the filter passed the record for + emission. + 'b' + Set the formatter for this handler. + 'u' + Set the formatter for this handler. + 'b' + Ensure all logging output has been flushed. + + This version does nothing and is intended to be implemented by + subclasses. + 'u' + Ensure all logging output has been flushed. + + This version does nothing and is intended to be implemented by + subclasses. + 'b' + Tidy up any resources used by the handler. + + This version removes the handler from an internal map of handlers, + _handlers, which is used for handler lookup by name. Subclasses + should ensure that this gets called from overridden close() + methods. + 'u' + Tidy up any resources used by the handler. + + This version removes the handler from an internal map of handlers, + _handlers, which is used for handler lookup by name. Subclasses + should ensure that this gets called from overridden close() + methods. + 'b' + Handle errors which occur during an emit() call. + + This method should be called from handlers when an exception is + encountered during an emit() call. If raiseExceptions is false, + exceptions get silently ignored. This is what is mostly wanted + for a logging system - most users will not care about errors in + the logging system, they are more interested in application errors. + You could, however, replace this with a custom handler if you wish. + The record which was being processed is passed in to this method. + 'u' + Handle errors which occur during an emit() call. + + This method should be called from handlers when an exception is + encountered during an emit() call. If raiseExceptions is false, + exceptions get silently ignored. This is what is mostly wanted + for a logging system - most users will not care about errors in + the logging system, they are more interested in application errors. + You could, however, replace this with a custom handler if you wish. + The record which was being processed is passed in to this method. + 'b'--- Logging error --- +'u'--- Logging error --- +'b'Call stack: +'u'Call stack: +'b'Logged from file %s, line %s +'u'Logged from file %s, line %s +'b'Message: %r +Arguments: %s +'u'Message: %r +Arguments: %s +'b'Unable to print the message and arguments - possible formatting error. +Use the traceback above to help find the error. +'u'Unable to print the message and arguments - possible formatting error. +Use the traceback above to help find the error. +'b'<%s (%s)>'u'<%s (%s)>'b' + A handler class which writes logging records, appropriately formatted, + to a stream. Note that this class does not close the stream, as + sys.stdout or sys.stderr may be used. + 'u' + A handler class which writes logging records, appropriately formatted, + to a stream. Note that this class does not close the stream, as + sys.stdout or sys.stderr may be used. + 'b' + Initialize the handler. + + If stream is not specified, sys.stderr is used. + 'u' + Initialize the handler. + + If stream is not specified, sys.stderr is used. + 'b' + Flushes the stream. + 'u' + Flushes the stream. + 'b'flush'u'flush'b' + Emit a record. + + If a formatter is specified, it is used to format the record. + The record is then written to the stream with a trailing newline. If + exception information is present, it is formatted using + traceback.print_exception and appended to the stream. If the stream + has an 'encoding' attribute, it is used to determine how to do the + output to the stream. + 'u' + Emit a record. + + If a formatter is specified, it is used to format the record. + The record is then written to the stream with a trailing newline. If + exception information is present, it is formatted using + traceback.print_exception and appended to the stream. If the stream + has an 'encoding' attribute, it is used to determine how to do the + output to the stream. + 'b' + Sets the StreamHandler's stream to the specified value, + if it is different. + + Returns the old stream, if the stream was changed, or None + if it wasn't. + 'u' + Sets the StreamHandler's stream to the specified value, + if it is different. + + Returns the old stream, if the stream was changed, or None + if it wasn't. + 'b'<%s %s(%s)>'u'<%s %s(%s)>'b' + A handler class which writes formatted logging records to disk files. + 'u' + A handler class which writes formatted logging records to disk files. + 'b'a'u'a'b' + Open the specified file and use it as the stream for logging. + 'u' + Open the specified file and use it as the stream for logging. + 'b' + Closes the stream. + 'u' + Closes the stream. + 'b'close'u'close'b' + Open the current base file with the (original) mode and encoding. + Return the resulting stream. + 'u' + Open the current base file with the (original) mode and encoding. + Return the resulting stream. + 'b' + Emit a record. + + If the stream was not opened because 'delay' was specified in the + constructor, open it before calling the superclass's emit. + 'u' + Emit a record. + + If the stream was not opened because 'delay' was specified in the + constructor, open it before calling the superclass's emit. + 'b'<%s %s (%s)>'u'<%s %s (%s)>'b' + This class is like a StreamHandler using sys.stderr, but always uses + whatever sys.stderr is currently set to rather than the value of + sys.stderr at handler construction time. + 'u' + This class is like a StreamHandler using sys.stderr, but always uses + whatever sys.stderr is currently set to rather than the value of + sys.stderr at handler construction time. + 'b' + Initialize the handler. + 'u' + Initialize the handler. + 'b' + PlaceHolder instances are used in the Manager logger hierarchy to take + the place of nodes for which no loggers have been defined. This class is + intended for internal use only and not as part of the public API. + 'u' + PlaceHolder instances are used in the Manager logger hierarchy to take + the place of nodes for which no loggers have been defined. This class is + intended for internal use only and not as part of the public API. + 'b' + Initialize with the specified logger being a child of this placeholder. + 'u' + Initialize with the specified logger being a child of this placeholder. + 'b' + Add the specified logger as a child of this placeholder. + 'u' + Add the specified logger as a child of this placeholder. + 'b' + Set the class to be used when instantiating a logger. The class should + define __init__() such that only a name argument is required, and the + __init__() should call Logger.__init__() + 'u' + Set the class to be used when instantiating a logger. The class should + define __init__() such that only a name argument is required, and the + __init__() should call Logger.__init__() + 'b'logger not derived from logging.Logger: 'u'logger not derived from logging.Logger: 'b' + Return the class to be used when instantiating a logger. + 'u' + Return the class to be used when instantiating a logger. + 'b' + There is [under normal circumstances] just one Manager instance, which + holds the hierarchy of loggers. + 'u' + There is [under normal circumstances] just one Manager instance, which + holds the hierarchy of loggers. + 'b' + Initialize the manager with the root node of the logger hierarchy. + 'u' + Initialize the manager with the root node of the logger hierarchy. + 'b' + Get a logger with the specified name (channel name), creating it + if it doesn't yet exist. This name is a dot-separated hierarchical + name, such as "a", "a.b", "a.b.c" or similar. + + If a PlaceHolder existed for the specified name [i.e. the logger + didn't exist but a child of it did], replace it with the created + logger and fix up the parent/child references which pointed to the + placeholder to now point to the logger. + 'u' + Get a logger with the specified name (channel name), creating it + if it doesn't yet exist. This name is a dot-separated hierarchical + name, such as "a", "a.b", "a.b.c" or similar. + + If a PlaceHolder existed for the specified name [i.e. the logger + didn't exist but a child of it did], replace it with the created + logger and fix up the parent/child references which pointed to the + placeholder to now point to the logger. + 'b'A logger name must be a string'u'A logger name must be a string'b' + Set the class to be used when instantiating a logger with this Manager. + 'u' + Set the class to be used when instantiating a logger with this Manager. + 'b' + Set the factory to be used when instantiating a log record with this + Manager. + 'u' + Set the factory to be used when instantiating a log record with this + Manager. + 'b' + Ensure that there are either loggers or placeholders all the way + from the specified logger to the root of the logger hierarchy. + 'u' + Ensure that there are either loggers or placeholders all the way + from the specified logger to the root of the logger hierarchy. + 'b' + Ensure that children of the placeholder ph are connected to the + specified logger. + 'u' + Ensure that children of the placeholder ph are connected to the + specified logger. + 'b' + Clear the cache for all loggers in loggerDict + Called when level changes are made + 'u' + Clear the cache for all loggers in loggerDict + Called when level changes are made + 'b' + Instances of the Logger class represent a single logging channel. A + "logging channel" indicates an area of an application. Exactly how an + "area" is defined is up to the application developer. Since an + application can have any number of areas, logging channels are identified + by a unique string. Application areas can be nested (e.g. an area + of "input processing" might include sub-areas "read CSV files", "read + XLS files" and "read Gnumeric files"). To cater for this natural nesting, + channel names are organized into a namespace hierarchy where levels are + separated by periods, much like the Java or Python package namespace. So + in the instance given above, channel names might be "input" for the upper + level, and "input.csv", "input.xls" and "input.gnu" for the sub-levels. + There is no arbitrary limit to the depth of nesting. + 'u' + Instances of the Logger class represent a single logging channel. A + "logging channel" indicates an area of an application. Exactly how an + "area" is defined is up to the application developer. Since an + application can have any number of areas, logging channels are identified + by a unique string. Application areas can be nested (e.g. an area + of "input processing" might include sub-areas "read CSV files", "read + XLS files" and "read Gnumeric files"). To cater for this natural nesting, + channel names are organized into a namespace hierarchy where levels are + separated by periods, much like the Java or Python package namespace. So + in the instance given above, channel names might be "input" for the upper + level, and "input.csv", "input.xls" and "input.gnu" for the sub-levels. + There is no arbitrary limit to the depth of nesting. + 'b' + Initialize the logger with a name and an optional level. + 'u' + Initialize the logger with a name and an optional level. + 'b' + Set the logging level of this logger. level must be an int or a str. + 'u' + Set the logging level of this logger. level must be an int or a str. + 'b' + Log 'msg % args' with severity 'DEBUG'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.debug("Houston, we have a %s", "thorny problem", exc_info=1) + 'u' + Log 'msg % args' with severity 'DEBUG'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.debug("Houston, we have a %s", "thorny problem", exc_info=1) + 'b' + Log 'msg % args' with severity 'INFO'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.info("Houston, we have a %s", "interesting problem", exc_info=1) + 'u' + Log 'msg % args' with severity 'INFO'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.info("Houston, we have a %s", "interesting problem", exc_info=1) + 'b' + Log 'msg % args' with severity 'WARNING'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.warning("Houston, we have a %s", "bit of a problem", exc_info=1) + 'u' + Log 'msg % args' with severity 'WARNING'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.warning("Houston, we have a %s", "bit of a problem", exc_info=1) + 'b'The 'warn' method is deprecated, use 'warning' instead'u'The 'warn' method is deprecated, use 'warning' instead'b' + Log 'msg % args' with severity 'ERROR'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.error("Houston, we have a %s", "major problem", exc_info=1) + 'u' + Log 'msg % args' with severity 'ERROR'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.error("Houston, we have a %s", "major problem", exc_info=1) + 'b' + Convenience method for logging an ERROR with exception information. + 'u' + Convenience method for logging an ERROR with exception information. + 'b' + Log 'msg % args' with severity 'CRITICAL'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.critical("Houston, we have a %s", "major disaster", exc_info=1) + 'u' + Log 'msg % args' with severity 'CRITICAL'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.critical("Houston, we have a %s", "major disaster", exc_info=1) + 'b' + Log 'msg % args' with the integer severity 'level'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.log(level, "We have a %s", "mysterious problem", exc_info=1) + 'u' + Log 'msg % args' with the integer severity 'level'. + + To pass exception information, use the keyword argument exc_info with + a true value, e.g. + + logger.log(level, "We have a %s", "mysterious problem", exc_info=1) + 'b'level must be an integer'u'level must be an integer'b' + Find the stack frame of the caller so that we can note the source + file name, line number and function name. + 'u' + Find the stack frame of the caller so that we can note the source + file name, line number and function name. + 'b'(unknown file)'u'(unknown file)'b'(unknown function)'u'(unknown function)'b'f_code'u'f_code'b'Stack (most recent call last): +'u'Stack (most recent call last): +'b' + A factory method which can be overridden in subclasses to create + specialized LogRecords. + 'u' + A factory method which can be overridden in subclasses to create + specialized LogRecords. + 'b'asctime'u'asctime'b'Attempt to overwrite %r in LogRecord'u'Attempt to overwrite %r in LogRecord'b' + Low-level logging routine which creates a LogRecord and then calls + all the handlers of this logger to handle the record. + 'u' + Low-level logging routine which creates a LogRecord and then calls + all the handlers of this logger to handle the record. + 'b' + Call the handlers for the specified record. + + This method is used for unpickled records received from a socket, as + well as those created locally. Logger-level filtering is applied. + 'u' + Call the handlers for the specified record. + + This method is used for unpickled records received from a socket, as + well as those created locally. Logger-level filtering is applied. + 'b' + Add the specified handler to this logger. + 'u' + Add the specified handler to this logger. + 'b' + Remove the specified handler from this logger. + 'u' + Remove the specified handler from this logger. + 'b' + See if this logger has any handlers configured. + + Loop through all handlers for this logger and its parents in the + logger hierarchy. Return True if a handler was found, else False. + Stop searching up the hierarchy whenever a logger with the "propagate" + attribute set to zero is found - that will be the last logger which + is checked for the existence of handlers. + 'u' + See if this logger has any handlers configured. + + Loop through all handlers for this logger and its parents in the + logger hierarchy. Return True if a handler was found, else False. + Stop searching up the hierarchy whenever a logger with the "propagate" + attribute set to zero is found - that will be the last logger which + is checked for the existence of handlers. + 'b' + Pass a record to all relevant handlers. + + Loop through all handlers for this logger and its parents in the + logger hierarchy. If no handler was found, output a one-off error + message to sys.stderr. Stop searching up the hierarchy whenever a + logger with the "propagate" attribute set to zero is found - that + will be the last logger whose handlers are called. + 'u' + Pass a record to all relevant handlers. + + Loop through all handlers for this logger and its parents in the + logger hierarchy. If no handler was found, output a one-off error + message to sys.stderr. Stop searching up the hierarchy whenever a + logger with the "propagate" attribute set to zero is found - that + will be the last logger whose handlers are called. + 'b'No handlers could be found for logger "%s" +'u'No handlers could be found for logger "%s" +'b' + Get the effective level for this logger. + + Loop through this logger and its parents in the logger hierarchy, + looking for a non-zero logging level. Return the first one found. + 'u' + Get the effective level for this logger. + + Loop through this logger and its parents in the logger hierarchy, + looking for a non-zero logging level. Return the first one found. + 'b' + Is this logger enabled for level 'level'? + 'u' + Is this logger enabled for level 'level'? + 'b' + Get a logger which is a descendant to this one. + + This is a convenience method, such that + + logging.getLogger('abc').getChild('def.ghi') + + is the same as + + logging.getLogger('abc.def.ghi') + + It's useful, for example, when the parent logger is named using + __name__ rather than a literal string. + 'u' + Get a logger which is a descendant to this one. + + This is a convenience method, such that + + logging.getLogger('abc').getChild('def.ghi') + + is the same as + + logging.getLogger('abc.def.ghi') + + It's useful, for example, when the parent logger is named using + __name__ rather than a literal string. + 'b'logger cannot be pickled'u'logger cannot be pickled'b' + A root logger is not that different to any other logger, except that + it must have a logging level and there is only one instance of it in + the hierarchy. + 'u' + A root logger is not that different to any other logger, except that + it must have a logging level and there is only one instance of it in + the hierarchy. + 'b' + Initialize the logger with the name "root". + 'u' + Initialize the logger with the name "root". + 'b'root'u'root'b' + An adapter for loggers which makes it easier to specify contextual + information in logging output. + 'u' + An adapter for loggers which makes it easier to specify contextual + information in logging output. + 'b' + Initialize the adapter with a logger and a dict-like object which + provides contextual information. This constructor signature allows + easy stacking of LoggerAdapters, if so desired. + + You can effectively pass keyword arguments as shown in the + following example: + + adapter = LoggerAdapter(someLogger, dict(p1=v1, p2="v2")) + 'u' + Initialize the adapter with a logger and a dict-like object which + provides contextual information. This constructor signature allows + easy stacking of LoggerAdapters, if so desired. + + You can effectively pass keyword arguments as shown in the + following example: + + adapter = LoggerAdapter(someLogger, dict(p1=v1, p2="v2")) + 'b' + Process the logging message and keyword arguments passed in to + a logging call to insert contextual information. You can either + manipulate the message itself, the keyword args or both. Return + the message and kwargs modified (or not) to suit your needs. + + Normally, you'll only need to override this one method in a + LoggerAdapter subclass for your specific needs. + 'u' + Process the logging message and keyword arguments passed in to + a logging call to insert contextual information. You can either + manipulate the message itself, the keyword args or both. Return + the message and kwargs modified (or not) to suit your needs. + + Normally, you'll only need to override this one method in a + LoggerAdapter subclass for your specific needs. + 'b'extra'u'extra'b' + Delegate a debug call to the underlying logger. + 'u' + Delegate a debug call to the underlying logger. + 'b' + Delegate an info call to the underlying logger. + 'u' + Delegate an info call to the underlying logger. + 'b' + Delegate a warning call to the underlying logger. + 'u' + Delegate a warning call to the underlying logger. + 'b' + Delegate an error call to the underlying logger. + 'u' + Delegate an error call to the underlying logger. + 'b' + Delegate an exception call to the underlying logger. + 'u' + Delegate an exception call to the underlying logger. + 'b' + Delegate a critical call to the underlying logger. + 'u' + Delegate a critical call to the underlying logger. + 'b' + Delegate a log call to the underlying logger, after adding + contextual information from this adapter instance. + 'u' + Delegate a log call to the underlying logger, after adding + contextual information from this adapter instance. + 'b' + Set the specified level on the underlying logger. + 'u' + Set the specified level on the underlying logger. + 'b' + Get the effective level for the underlying logger. + 'u' + Get the effective level for the underlying logger. + 'b' + See if the underlying logger has any handlers. + 'u' + See if the underlying logger has any handlers. + 'b' + Low-level log implementation, proxied to allow nested logger adapters. + 'u' + Low-level log implementation, proxied to allow nested logger adapters. + 'b' + Do basic configuration for the logging system. + + This function does nothing if the root logger already has handlers + configured, unless the keyword argument *force* is set to ``True``. + It is a convenience method intended for use by simple scripts + to do one-shot configuration of the logging package. + + The default behaviour is to create a StreamHandler which writes to + sys.stderr, set a formatter using the BASIC_FORMAT format string, and + add the handler to the root logger. + + A number of optional keyword arguments may be specified, which can alter + the default behaviour. + + filename Specifies that a FileHandler be created, using the specified + filename, rather than a StreamHandler. + filemode Specifies the mode to open the file, if filename is specified + (if filemode is unspecified, it defaults to 'a'). + format Use the specified format string for the handler. + datefmt Use the specified date/time format. + style If a format string is specified, use this to specify the + type of format string (possible values '%', '{', '$', for + %-formatting, :meth:`str.format` and :class:`string.Template` + - defaults to '%'). + level Set the root logger level to the specified level. + stream Use the specified stream to initialize the StreamHandler. Note + that this argument is incompatible with 'filename' - if both + are present, 'stream' is ignored. + handlers If specified, this should be an iterable of already created + handlers, which will be added to the root handler. Any handler + in the list which does not have a formatter assigned will be + assigned the formatter created in this function. + force If this keyword is specified as true, any existing handlers + attached to the root logger are removed and closed, before + carrying out the configuration as specified by the other + arguments. + Note that you could specify a stream created using open(filename, mode) + rather than passing the filename and mode in. However, it should be + remembered that StreamHandler does not close its stream (since it may be + using sys.stdout or sys.stderr), whereas FileHandler closes its stream + when the handler is closed. + + .. versionchanged:: 3.8 + Added the ``force`` parameter. + + .. versionchanged:: 3.2 + Added the ``style`` parameter. + + .. versionchanged:: 3.3 + Added the ``handlers`` parameter. A ``ValueError`` is now thrown for + incompatible arguments (e.g. ``handlers`` specified together with + ``filename``/``filemode``, or ``filename``/``filemode`` specified + together with ``stream``, or ``handlers`` specified together with + ``stream``. + 'u' + Do basic configuration for the logging system. + + This function does nothing if the root logger already has handlers + configured, unless the keyword argument *force* is set to ``True``. + It is a convenience method intended for use by simple scripts + to do one-shot configuration of the logging package. + + The default behaviour is to create a StreamHandler which writes to + sys.stderr, set a formatter using the BASIC_FORMAT format string, and + add the handler to the root logger. + + A number of optional keyword arguments may be specified, which can alter + the default behaviour. + + filename Specifies that a FileHandler be created, using the specified + filename, rather than a StreamHandler. + filemode Specifies the mode to open the file, if filename is specified + (if filemode is unspecified, it defaults to 'a'). + format Use the specified format string for the handler. + datefmt Use the specified date/time format. + style If a format string is specified, use this to specify the + type of format string (possible values '%', '{', '$', for + %-formatting, :meth:`str.format` and :class:`string.Template` + - defaults to '%'). + level Set the root logger level to the specified level. + stream Use the specified stream to initialize the StreamHandler. Note + that this argument is incompatible with 'filename' - if both + are present, 'stream' is ignored. + handlers If specified, this should be an iterable of already created + handlers, which will be added to the root handler. Any handler + in the list which does not have a formatter assigned will be + assigned the formatter created in this function. + force If this keyword is specified as true, any existing handlers + attached to the root logger are removed and closed, before + carrying out the configuration as specified by the other + arguments. + Note that you could specify a stream created using open(filename, mode) + rather than passing the filename and mode in. However, it should be + remembered that StreamHandler does not close its stream (since it may be + using sys.stdout or sys.stderr), whereas FileHandler closes its stream + when the handler is closed. + + .. versionchanged:: 3.8 + Added the ``force`` parameter. + + .. versionchanged:: 3.2 + Added the ``style`` parameter. + + .. versionchanged:: 3.3 + Added the ``handlers`` parameter. A ``ValueError`` is now thrown for + incompatible arguments (e.g. ``handlers`` specified together with + ``filename``/``filemode``, or ``filename``/``filemode`` specified + together with ``stream``, or ``handlers`` specified together with + ``stream``. + 'b'force'u'force'b'handlers'u'handlers'b'stream'u'stream'b'filename'u'filename'b''stream' and 'filename' should not be specified together'u''stream' and 'filename' should not be specified together'b''stream' or 'filename' should not be specified together with 'handlers''u''stream' or 'filename' should not be specified together with 'handlers''b'filemode'u'filemode'b'datefmt'u'datefmt'b'format'u'format'b'level'u'level'b', 'u', 'b'Unrecognised argument(s): %s'u'Unrecognised argument(s): %s'b' + Return a logger with the specified name, creating it if necessary. + + If no name is specified, return the root logger. + 'u' + Return a logger with the specified name, creating it if necessary. + + If no name is specified, return the root logger. + 'b' + Log a message with severity 'CRITICAL' on the root logger. If the logger + has no handlers, call basicConfig() to add a console handler with a + pre-defined format. + 'u' + Log a message with severity 'CRITICAL' on the root logger. If the logger + has no handlers, call basicConfig() to add a console handler with a + pre-defined format. + 'b' + Log a message with severity 'ERROR' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'u' + Log a message with severity 'ERROR' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'b' + Log a message with severity 'ERROR' on the root logger, with exception + information. If the logger has no handlers, basicConfig() is called to add + a console handler with a pre-defined format. + 'u' + Log a message with severity 'ERROR' on the root logger, with exception + information. If the logger has no handlers, basicConfig() is called to add + a console handler with a pre-defined format. + 'b' + Log a message with severity 'WARNING' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'u' + Log a message with severity 'WARNING' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'b'The 'warn' function is deprecated, use 'warning' instead'u'The 'warn' function is deprecated, use 'warning' instead'b' + Log a message with severity 'INFO' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'u' + Log a message with severity 'INFO' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'b' + Log a message with severity 'DEBUG' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'u' + Log a message with severity 'DEBUG' on the root logger. If the logger has + no handlers, call basicConfig() to add a console handler with a pre-defined + format. + 'b' + Log 'msg % args' with the integer severity 'level' on the root logger. If + the logger has no handlers, call basicConfig() to add a console handler + with a pre-defined format. + 'u' + Log 'msg % args' with the integer severity 'level' on the root logger. If + the logger has no handlers, call basicConfig() to add a console handler + with a pre-defined format. + 'b' + Disable all logging calls of severity 'level' and below. + 'u' + Disable all logging calls of severity 'level' and below. + 'b' + Perform any cleanup actions in the logging system (e.g. flushing + buffers). + + Should be called at application exit. + 'u' + Perform any cleanup actions in the logging system (e.g. flushing + buffers). + + Should be called at application exit. + 'b' + This handler does nothing. It's intended to be used to avoid the + "No handlers could be found for logger XXX" one-off warning. This is + important for library code, which may contain code to log events. If a user + of the library does not configure logging, the one-off warning might be + produced; to avoid this, the library developer simply needs to instantiate + a NullHandler and add it to the top-level logger of the library module or + package. + 'u' + This handler does nothing. It's intended to be used to avoid the + "No handlers could be found for logger XXX" one-off warning. This is + important for library code, which may contain code to log events. If a user + of the library does not configure logging, the one-off warning might be + produced; to avoid this, the library developer simply needs to instantiate + a NullHandler and add it to the top-level logger of the library module or + package. + 'b'Stub.'u'Stub.'b' + Implementation of showwarnings which redirects to logging, which will first + check to see if the file parameter is None. If a file is specified, it will + delegate to the original warnings implementation of showwarning. Otherwise, + it will call warnings.formatwarning and will log the resulting string to a + warnings logger named "py.warnings" with level logging.WARNING. + 'u' + Implementation of showwarnings which redirects to logging, which will first + check to see if the file parameter is None. If a file is specified, it will + delegate to the original warnings implementation of showwarning. Otherwise, + it will call warnings.formatwarning and will log the resulting string to a + warnings logger named "py.warnings" with level logging.WARNING. + 'b'py.warnings'u'py.warnings'b' + If capture is true, redirect all warnings to the logging package. + If capture is False, ensure that warnings are not redirected to logging + but to their original destinations. + 'u' + If capture is true, redirect all warnings to the logging package. + If capture is False, ensure that warnings are not redirected to logging + but to their original destinations. + 'u'logging.__init__'u'logging'Python interfaces to XML parsers. + +This package contains one module: + +expat -- Python wrapper for James Clark's Expat parser, with namespace + support. + +b'Python interfaces to XML parsers. + +This package contains one module: + +expat -- Python wrapper for James Clark's Expat parser, with namespace + support. + +'u'Python interfaces to XML parsers. + +This package contains one module: + +expat -- Python wrapper for James Clark's Expat parser, with namespace + support. + +'u'xml.parsers.__init__'u'xml.parsers'u'parsers.__init__'u'parsers'This module implements specialized container datatypes providing +alternatives to Python's general purpose built-in containers, dict, +list, set, and tuple. + +* namedtuple factory function for creating tuple subclasses with named fields +* deque list-like container with fast appends and pops on either end +* ChainMap dict-like class for creating a single view of multiple mappings +* Counter dict subclass for counting hashable objects +* OrderedDict dict subclass that remembers the order entries were added +* defaultdict dict subclass that calls a factory function to supply missing values +* UserDict wrapper around dictionary objects for easier dict subclassing +* UserList wrapper around list objects for easier list subclassing +* UserString wrapper around string objects for easier string subclassing + +'''defaultdictnamedtupleUserDictUserListUserStringCounterOrderedDictChainMap_collections_abcoperatoritemgetter_itemgettereq_eqkeywordiskeyword_iskeyword_sysheapq_heapq_weakref_proxyitertoolsrepeat_repeatchain_chainstarmap_starmapreprlibrecursive_repr_recursive_repr_collectionsMutableSequenceUsing or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working"Using or importing the ABCs from 'collections' instead ""of from 'collections.abc' is deprecated since Python 3.3, ""and in 3.10 it will stop working"_OrderedDictKeysViewKeysView_mapping_OrderedDictItemsViewItemsView_OrderedDictValuesViewValuesView_Linkprev__slots__Dictionary that remembers insertion orderkwdsInitialize an ordered dictionary. The signature is the same as + regular dictionaries. Keyword argument order is preserved. + __root__hardroot__map__updatedict_setitemLinkod.__setitem__(i, y) <==> od[i]=ydict_delitemod.__delitem__(y) <==> del od[y]link_prevlink_nextod.__iter__() <==> iter(od)currod.__reversed__() <==> reversed(od)od.clear() -> None. Remove all items from od.Remove and return a (key, value) pair from the dictionary. + + Pairs are returned in LIFO order if last is true or FIFO order if false. + dictionary is emptymove_to_endMove an existing element to the end (or beginning if last is false). + + Raise KeyError if the element does not exist. + soft_linksizeofMutableMappingD.keys() -> a set-like object providing a view on D's keysD.items() -> a set-like object providing a view on D's itemsD.values() -> an object providing a view on D's values__markerod.pop(k[,d]) -> v, remove specified key and return the corresponding + value. If key is not found, d is returned if given, otherwise KeyError + is raised. + + Insert key with a value of default if key is not in the dictionary. + + Return the value for key if key is in the dictionary, else default. + od.__repr__() <==> repr(od)%s()%s(%r)Return state information for picklinginst_dictod.copy() -> a shallow copy of oditerableCreate a new ordered dictionary with keys from iterable and values set to value. + od.__eq__(y) <==> od==y. Comparison to another OD is order-sensitive + while comparison to a regular mapping is order-insensitive. + + _tuplegetterdoctypenamefield_namesrenamedefaultsReturns a new subclass of tuple with named fields. + + >>> Point = namedtuple('Point', ['x', 'y']) + >>> Point.__doc__ # docstring for the new class + 'Point(x, y)' + >>> p = Point(11, y=22) # instantiate with positional args or keywords + >>> p[0] + p[1] # indexable like a plain tuple + 33 + >>> x, y = p # unpack like a regular tuple + >>> x, y + (11, 22) + >>> p.x + p.y # fields also accessible by name + 33 + >>> d = p._asdict() # convert to a dictionary + >>> d['x'] + 11 + >>> Point(**d) # convert from a dictionary + Point(x=11, y=22) + >>> p._replace(x=100) # _replace() is like str.replace() but targets named fields + Point(x=100, y=22) + + seenType names and field names must be stringsType names and field names must be valid identifiers: 'Type names and field names must be valid ''identifiers: 'Type names and field names cannot be a keyword: 'Type names and field names cannot be a ''keyword: 'Field names cannot start with an underscore: 'Field names cannot start with an underscore: '''Encountered duplicate field name: field_defaultsGot more default values than field namesnum_fieldsarg_list(=%r)repr_fmttuple_new_dict_tuple_len_map_zipdef __new__(_cls, ): return _tuple_new(_cls, ())_tuple_newnamedtuple_namespaceCreate new instance of _makeExpected arguments, got Make a new object from a sequence or iterable' object from a sequence ''or iterable'_replaceGot unexpected field names: Return a new object replacing specified fields with new values' object replacing specified ''fields with new values'Return a nicely formatted representation string_asdictReturn a new dict which maps field names to their values._fieldsReturn self as a plain tuple. Used by copy and pickle._field_defaults_fields_defaultsclass_namespaceAlias for field number f_globals_count_elementsmappingTally elements from the iterable.mapping_getDict subclass for counting hashable items. Sometimes called a bag + or multiset. Elements are stored as dictionary keys and their counts + are stored as dictionary values. + + >>> c = Counter('abcdeabcdabcaba') # count elements from a string + + >>> c.most_common(3) # three most common elements + [('a', 5), ('b', 4), ('c', 3)] + >>> sorted(c) # list all unique elements + ['a', 'b', 'c', 'd', 'e'] + >>> ''.join(sorted(c.elements())) # list elements with repetitions + 'aaaaabbbbcccdde' + >>> sum(c.values()) # total of all counts + 15 + + >>> c['a'] # count of letter 'a' + 5 + >>> for elem in 'shazam': # update counts from an iterable + ... c[elem] += 1 # by adding 1 to each element's count + >>> c['a'] # now there are seven 'a' + 7 + >>> del c['b'] # remove all 'b' + >>> c['b'] # now there are zero 'b' + 0 + + >>> d = Counter('simsalabim') # make another counter + >>> c.update(d) # add in the second counter + >>> c['a'] # now there are nine 'a' + 9 + + >>> c.clear() # empty the counter + >>> c + Counter() + + Note: If a count is set to zero or reduced to zero, it will remain + in the counter until the entry is deleted or the counter is cleared: + + >>> c = Counter('aaabbc') + >>> c['b'] -= 2 # reduce the count of 'b' by two + >>> c.most_common() # 'b' is still in, but its count is zero + [('a', 3), ('c', 1), ('b', 0)] + + Create a new, empty Counter object. And if given, count elements + from an input iterable. Or, initialize the count from another mapping + of elements to their counts. + + >>> c = Counter() # a new, empty counter + >>> c = Counter('gallahad') # a new counter from an iterable + >>> c = Counter({'a': 4, 'b': 2}) # a new counter from a mapping + >>> c = Counter(a=4, b=2) # a new counter from keyword args + + __missing__The count of elements not in the Counter is zero.most_commonList the n most common elements and their counts from the most + common to the least. If n is None, then list all element counts. + + >>> Counter('abracadabra').most_common(3) + [('a', 5), ('b', 2), ('r', 2)] + + nlargestIterator over elements repeating each as many times as its count. + + >>> c = Counter('ABCABC') + >>> sorted(c.elements()) + ['A', 'A', 'B', 'B', 'C', 'C'] + + # Knuth's example for prime factors of 1836: 2**2 * 3**3 * 17**1 + >>> prime_factors = Counter({2: 2, 3: 3, 17: 1}) + >>> product = 1 + >>> for factor in prime_factors.elements(): # loop over factors + ... product *= factor # and multiply them + >>> product + 1836 + + Note, if an element's count has been set to zero or is a negative + number, elements() will ignore it. + + from_iterableCounter.fromkeys() is undefined. Use Counter(iterable) instead.Like dict.update() but add counts instead of replacing them. + + Source can be an iterable, a dictionary, or another Counter instance. + + >>> c = Counter('which') + >>> c.update('witch') # add elements from another iterable + >>> d = Counter('watch') + >>> c.update(d) # add elements from another counter + >>> c['h'] # four 'h' in which, witch, and watch + 4 + + self_getsubtractLike dict.update() but subtracts counts instead of replacing them. + Counts can be reduced below zero. Both the inputs and outputs are + allowed to contain zero and negative counts. + + Source can be an iterable, a dictionary, or another Counter instance. + + >>> c = Counter('which') + >>> c.subtract('witch') # subtract elements from another iterable + >>> c.subtract(Counter('watch')) # subtract elements from another counter + >>> c['h'] # 2 in which, minus 1 in witch, minus 1 in watch + 0 + >>> c['w'] # 1 in which, minus 1 in witch, minus 1 in watch + -1 + + Return a shallow copy.Like dict.__delitem__() but does not raise KeyError for missing values.%r: %r%s({%s}){0}({1!r})Add counts from two counters. + + >>> Counter('abbb') + Counter('bcc') + Counter({'b': 4, 'c': 2, 'a': 1}) + + newcount Subtract count, but keep only results with positive counts. + + >>> Counter('abbbc') - Counter('bccd') + Counter({'b': 2, 'a': 1}) + + Union is the maximum of value in either of the input counters. + + >>> Counter('abbb') | Counter('bcc') + Counter({'b': 3, 'c': 2, 'a': 1}) + + other_count Intersection is the minimum of corresponding counts. + + >>> Counter('abbb') & Counter('bcc') + Counter({'b': 1}) + + Adds an empty counter, effectively stripping negative and zero countsSubtracts from an empty counter. Strips positive and zero counts, + and flips the sign on negative counts. + + _keep_positiveInternal method to strip elements with a negative or zero countnonpositiveInplace add from another counter, keeping only positive counts. + + >>> c = Counter('abbb') + >>> c += Counter('bcc') + >>> c + Counter({'b': 4, 'c': 2, 'a': 1}) + + Inplace subtract counter, but keep only results with positive counts. + + >>> c = Counter('abbbc') + >>> c -= Counter('bccd') + >>> c + Counter({'b': 2, 'a': 1}) + + Inplace union is the maximum of value from either counter. + + >>> c = Counter('abbb') + >>> c |= Counter('bcc') + >>> c + Counter({'b': 3, 'c': 2, 'a': 1}) + + Inplace intersection is the minimum of corresponding counts. + + >>> c = Counter('abbb') + >>> c &= Counter('bcc') + >>> c + Counter({'b': 1}) + + A ChainMap groups multiple dicts (or other mappings) together + to create a single, updateable view. + + The underlying mappings are stored in a list. That list is public and can + be accessed or updated using the *maps* attribute. There is no other + state. + + Lookups search the underlying mappings successively until a key is found. + In contrast, writes, updates, and deletions only operate on the first + mapping. + + mapsInitialize a ChainMap by setting *maps* to the given mappings. + If no mappings are provided, a single empty dictionary is used. + + Create a ChainMap with a single dict created from the iterable.New ChainMap or subclass with a new copy of maps[0] and refs to maps[1:]__copy__new_childNew ChainMap with a new map followed by all previous maps. + If no map is provided, an empty dict is used. + parentsNew ChainMap from maps[1:].Key not found in the first mapping: {!r}Remove and return an item pair from maps[0]. Raise KeyError is maps[0] is empty.No keys found in the first mapping.Remove *key* from maps[0] and return its value. Raise KeyError if *key* not in maps[0].Clear maps[0], leaving maps[1:] intact.descriptor '__init__' of 'UserDict' object needs an argument"descriptor '__init__' of 'UserDict' object ""needs an argument"expected at most 1 arguments, got %dPassing 'dict' as keyword argument is deprecated($self, dict=None, /, **kwargs)instA more or less complete user-defined wrapper around list objects.initlist__castSequence__complex__templatestricttabsizesepoldnewmaxsplitkeepends# For backwards compatibility, continue to make the collections ABCs# through Python 3.6 available through the collections module.# Note, no new collections ABCs were added in Python 3.7################################################################################### OrderedDict# An inherited dict maps keys to values.# The inherited dict provides __getitem__, __len__, __contains__, and get.# The remaining methods are order-aware.# Big-O running times for all methods are the same as regular dictionaries.# The internal self.__map dict maps keys to links in a doubly linked list.# The circular doubly linked list starts and ends with a sentinel element.# The sentinel element never gets deleted (this simplifies the algorithm).# The sentinel is in self.__hardroot with a weakref proxy in self.__root.# The prev links are weakref proxies (to prevent circular references).# Individual links are kept alive by the hard reference in self.__map.# Those hard references disappear when a key is deleted from an OrderedDict.# Setting a new item creates a new link at the end of the linked list,# and the inherited dictionary is updated with the new key/value pair.# Deleting an existing item uses self.__map to find the link which gets# removed by updating the links in the predecessor and successor nodes.# Traverse the linked list in order.# Traverse the linked list in reverse order.# number of links including root# instance dictionary# internal dict and inherited dict# link objects# proxy objects# Leave the pure Python version in place.### namedtuple# Validate the field names. At the user's option, either generate an error# message or automatically replace the field name with a valid name.# Variables used in the methods and docstrings# Create all the named tuple methods to be added to the class namespace# Note: exec() has the side-effect of interning the field names# Modify function metadata to help with introspection and debugging# Build-up the class namespace dictionary# and use type() to build the result class# alternate spelling for backward compatibility# For pickling to work, the __module__ variable needs to be set to the frame# where the named tuple is created. Bypass this step in environments where# sys._getframe is not defined (Jython for example) or sys._getframe is not# defined for arguments greater than 0 (IronPython), or where the user has# specified a particular module.### Counter# Load C helper function if available# References:# http://en.wikipedia.org/wiki/Multiset# http://www.gnu.org/software/smalltalk/manual-base/html_node/Bag.html# http://www.demo2s.com/Tutorial/Cpp/0380__set-multiset/Catalog0380__set-multiset.htm# http://code.activestate.com/recipes/259174/# Knuth, TAOCP Vol. II section 4.6.3# Needed so that self[missing_item] does not raise KeyError# Emulate Bag.sortedByCount from Smalltalk# Emulate Bag.do from Smalltalk and Multiset.begin from C++.# Override dict methods where necessary# There is no equivalent method for counters because the semantics# would be ambiguous in cases such as Counter.fromkeys('aaabbc', v=2).# Initializing counters to zero values isn't necessary because zero# is already the default value for counter lookups. Initializing# to one is easily accomplished with Counter(set(iterable)). For# more exotic cases, create a dictionary first using a dictionary# comprehension or dict.fromkeys().# The regular dict.update() operation makes no sense here because the# replace behavior results in the some of original untouched counts# being mixed-in with all of the other counts for a mismash that# doesn't have a straight-forward interpretation in most counting# contexts. Instead, we implement straight-addition. Both the inputs# and outputs are allowed to contain zero and negative counts.# fast path when counter is empty# handle case where values are not orderable# Multiset-style mathematical operations discussed in:# Knuth TAOCP Volume II section 4.6.3 exercise 19# and at http://en.wikipedia.org/wiki/Multiset# Outputs guaranteed to only include positive counts.# To strip negative and zero counts, add-in an empty counter:# c += Counter()# Rich comparison operators for multiset subset and superset tests# are deliberately omitted due to semantic conflicts with the# existing inherited dict equality method. Subset and superset# semantics ignore zero counts and require that p≤q ∧ p≥q → p=q;# however, that would not be the case for p=Counter(a=1, b=0)# and q=Counter(a=1) where the dictionaries are not equal.### ChainMap# always at least one map# can't use 'key in mapping' with defaultdict# support subclasses that define __missing__# reuses stored hash values if possible# like Django's Context.push()# like Django's Context.pop()### UserDict# Start by filling-out the abstract methods# Modify __contains__ to work correctly when __missing__ is present# Now, add the methods in dicts but not in MutableMapping# Create a copy and avoid triggering descriptors### UserList# XXX should this accept an arbitrary sequence?### UserString# the following methods are defined in alphabetical order:b'This module implements specialized container datatypes providing +alternatives to Python's general purpose built-in containers, dict, +list, set, and tuple. + +* namedtuple factory function for creating tuple subclasses with named fields +* deque list-like container with fast appends and pops on either end +* ChainMap dict-like class for creating a single view of multiple mappings +* Counter dict subclass for counting hashable objects +* OrderedDict dict subclass that remembers the order entries were added +* defaultdict dict subclass that calls a factory function to supply missing values +* UserDict wrapper around dictionary objects for easier dict subclassing +* UserList wrapper around list objects for easier list subclassing +* UserString wrapper around string objects for easier string subclassing + +'u'This module implements specialized container datatypes providing +alternatives to Python's general purpose built-in containers, dict, +list, set, and tuple. + +* namedtuple factory function for creating tuple subclasses with named fields +* deque list-like container with fast appends and pops on either end +* ChainMap dict-like class for creating a single view of multiple mappings +* Counter dict subclass for counting hashable objects +* OrderedDict dict subclass that remembers the order entries were added +* defaultdict dict subclass that calls a factory function to supply missing values +* UserDict wrapper around dictionary objects for easier dict subclassing +* UserList wrapper around list objects for easier list subclassing +* UserString wrapper around string objects for easier string subclassing + +'b'deque'u'deque'b'defaultdict'u'defaultdict'b'namedtuple'u'namedtuple'b'UserDict'u'UserDict'b'UserList'u'UserList'b'UserString'u'UserString'b'Counter'u'Counter'b'OrderedDict'u'OrderedDict'b'ChainMap'u'ChainMap'b'Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working'u'Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated since Python 3.3, and in 3.10 it will stop working'b'prev'u'prev'b'key'u'key'b'__weakref__'u'__weakref__'b'Dictionary that remembers insertion order'u'Dictionary that remembers insertion order'b'Initialize an ordered dictionary. The signature is the same as + regular dictionaries. Keyword argument order is preserved. + 'u'Initialize an ordered dictionary. The signature is the same as + regular dictionaries. Keyword argument order is preserved. + 'b'od.__setitem__(i, y) <==> od[i]=y'u'od.__setitem__(i, y) <==> od[i]=y'b'od.__delitem__(y) <==> del od[y]'u'od.__delitem__(y) <==> del od[y]'b'od.__iter__() <==> iter(od)'u'od.__iter__() <==> iter(od)'b'od.__reversed__() <==> reversed(od)'u'od.__reversed__() <==> reversed(od)'b'od.clear() -> None. Remove all items from od.'u'od.clear() -> None. Remove all items from od.'b'Remove and return a (key, value) pair from the dictionary. + + Pairs are returned in LIFO order if last is true or FIFO order if false. + 'u'Remove and return a (key, value) pair from the dictionary. + + Pairs are returned in LIFO order if last is true or FIFO order if false. + 'b'dictionary is empty'u'dictionary is empty'b'Move an existing element to the end (or beginning if last is false). + + Raise KeyError if the element does not exist. + 'u'Move an existing element to the end (or beginning if last is false). + + Raise KeyError if the element does not exist. + 'b'D.keys() -> a set-like object providing a view on D's keys'u'D.keys() -> a set-like object providing a view on D's keys'b'D.items() -> a set-like object providing a view on D's items'u'D.items() -> a set-like object providing a view on D's items'b'D.values() -> an object providing a view on D's values'u'D.values() -> an object providing a view on D's values'b'od.pop(k[,d]) -> v, remove specified key and return the corresponding + value. If key is not found, d is returned if given, otherwise KeyError + is raised. + + 'u'od.pop(k[,d]) -> v, remove specified key and return the corresponding + value. If key is not found, d is returned if given, otherwise KeyError + is raised. + + 'b'Insert key with a value of default if key is not in the dictionary. + + Return the value for key if key is in the dictionary, else default. + 'u'Insert key with a value of default if key is not in the dictionary. + + Return the value for key if key is in the dictionary, else default. + 'b'od.__repr__() <==> repr(od)'u'od.__repr__() <==> repr(od)'b'%s()'u'%s()'b'%s(%r)'u'%s(%r)'b'Return state information for pickling'u'Return state information for pickling'b'od.copy() -> a shallow copy of od'u'od.copy() -> a shallow copy of od'b'Create a new ordered dictionary with keys from iterable and values set to value. + 'u'Create a new ordered dictionary with keys from iterable and values set to value. + 'b'od.__eq__(y) <==> od==y. Comparison to another OD is order-sensitive + while comparison to a regular mapping is order-insensitive. + + 'u'od.__eq__(y) <==> od==y. Comparison to another OD is order-sensitive + while comparison to a regular mapping is order-insensitive. + + 'b'Returns a new subclass of tuple with named fields. + + >>> Point = namedtuple('Point', ['x', 'y']) + >>> Point.__doc__ # docstring for the new class + 'Point(x, y)' + >>> p = Point(11, y=22) # instantiate with positional args or keywords + >>> p[0] + p[1] # indexable like a plain tuple + 33 + >>> x, y = p # unpack like a regular tuple + >>> x, y + (11, 22) + >>> p.x + p.y # fields also accessible by name + 33 + >>> d = p._asdict() # convert to a dictionary + >>> d['x'] + 11 + >>> Point(**d) # convert from a dictionary + Point(x=11, y=22) + >>> p._replace(x=100) # _replace() is like str.replace() but targets named fields + Point(x=100, y=22) + + 'u'Returns a new subclass of tuple with named fields. + + >>> Point = namedtuple('Point', ['x', 'y']) + >>> Point.__doc__ # docstring for the new class + 'Point(x, y)' + >>> p = Point(11, y=22) # instantiate with positional args or keywords + >>> p[0] + p[1] # indexable like a plain tuple + 33 + >>> x, y = p # unpack like a regular tuple + >>> x, y + (11, 22) + >>> p.x + p.y # fields also accessible by name + 33 + >>> d = p._asdict() # convert to a dictionary + >>> d['x'] + 11 + >>> Point(**d) # convert from a dictionary + Point(x=11, y=22) + >>> p._replace(x=100) # _replace() is like str.replace() but targets named fields + Point(x=100, y=22) + + 'b'Type names and field names must be strings'u'Type names and field names must be strings'b'Type names and field names must be valid identifiers: 'u'Type names and field names must be valid identifiers: 'b'Type names and field names cannot be a keyword: 'u'Type names and field names cannot be a keyword: 'b'Field names cannot start with an underscore: 'u'Field names cannot start with an underscore: 'b'Encountered duplicate field name: 'u'Encountered duplicate field name: 'b'Got more default values than field names'u'Got more default values than field names'b'('u'('b'=%r'u'=%r'b')'u')'b'def __new__(_cls, 'u'def __new__(_cls, 'b'): return _tuple_new(_cls, ('u'): return _tuple_new(_cls, ('b'))'u'))'b'_tuple_new'u'_tuple_new'b'namedtuple_'u'namedtuple_'b'__name__'u'__name__'b'__new__'u'__new__'b'Create new instance of 'u'Create new instance of 'b'Expected 'u'Expected 'b' arguments, got 'u' arguments, got 'b'Make a new 'u'Make a new 'b' object from a sequence or iterable'u' object from a sequence or iterable'b'Got unexpected field names: 'u'Got unexpected field names: 'b'Return a new 'u'Return a new 'b' object replacing specified fields with new values'u' object replacing specified fields with new values'b'Return a nicely formatted representation string'u'Return a nicely formatted representation string'b'Return a new dict which maps field names to their values.'u'Return a new dict which maps field names to their values.'b'Return self as a plain tuple. Used by copy and pickle.'u'Return self as a plain tuple. Used by copy and pickle.'b'__slots__'u'__slots__'b'_fields'u'_fields'b'_field_defaults'u'_field_defaults'b'_fields_defaults'u'_fields_defaults'b'_make'u'_make'b'_replace'u'_replace'b'__repr__'u'__repr__'b'_asdict'u'_asdict'b'__getnewargs__'u'__getnewargs__'b'Alias for field number 'u'Alias for field number 'b'Tally elements from the iterable.'u'Tally elements from the iterable.'b'Dict subclass for counting hashable items. Sometimes called a bag + or multiset. Elements are stored as dictionary keys and their counts + are stored as dictionary values. + + >>> c = Counter('abcdeabcdabcaba') # count elements from a string + + >>> c.most_common(3) # three most common elements + [('a', 5), ('b', 4), ('c', 3)] + >>> sorted(c) # list all unique elements + ['a', 'b', 'c', 'd', 'e'] + >>> ''.join(sorted(c.elements())) # list elements with repetitions + 'aaaaabbbbcccdde' + >>> sum(c.values()) # total of all counts + 15 + + >>> c['a'] # count of letter 'a' + 5 + >>> for elem in 'shazam': # update counts from an iterable + ... c[elem] += 1 # by adding 1 to each element's count + >>> c['a'] # now there are seven 'a' + 7 + >>> del c['b'] # remove all 'b' + >>> c['b'] # now there are zero 'b' + 0 + + >>> d = Counter('simsalabim') # make another counter + >>> c.update(d) # add in the second counter + >>> c['a'] # now there are nine 'a' + 9 + + >>> c.clear() # empty the counter + >>> c + Counter() + + Note: If a count is set to zero or reduced to zero, it will remain + in the counter until the entry is deleted or the counter is cleared: + + >>> c = Counter('aaabbc') + >>> c['b'] -= 2 # reduce the count of 'b' by two + >>> c.most_common() # 'b' is still in, but its count is zero + [('a', 3), ('c', 1), ('b', 0)] + + 'u'Dict subclass for counting hashable items. Sometimes called a bag + or multiset. Elements are stored as dictionary keys and their counts + are stored as dictionary values. + + >>> c = Counter('abcdeabcdabcaba') # count elements from a string + + >>> c.most_common(3) # three most common elements + [('a', 5), ('b', 4), ('c', 3)] + >>> sorted(c) # list all unique elements + ['a', 'b', 'c', 'd', 'e'] + >>> ''.join(sorted(c.elements())) # list elements with repetitions + 'aaaaabbbbcccdde' + >>> sum(c.values()) # total of all counts + 15 + + >>> c['a'] # count of letter 'a' + 5 + >>> for elem in 'shazam': # update counts from an iterable + ... c[elem] += 1 # by adding 1 to each element's count + >>> c['a'] # now there are seven 'a' + 7 + >>> del c['b'] # remove all 'b' + >>> c['b'] # now there are zero 'b' + 0 + + >>> d = Counter('simsalabim') # make another counter + >>> c.update(d) # add in the second counter + >>> c['a'] # now there are nine 'a' + 9 + + >>> c.clear() # empty the counter + >>> c + Counter() + + Note: If a count is set to zero or reduced to zero, it will remain + in the counter until the entry is deleted or the counter is cleared: + + >>> c = Counter('aaabbc') + >>> c['b'] -= 2 # reduce the count of 'b' by two + >>> c.most_common() # 'b' is still in, but its count is zero + [('a', 3), ('c', 1), ('b', 0)] + + 'b'Create a new, empty Counter object. And if given, count elements + from an input iterable. Or, initialize the count from another mapping + of elements to their counts. + + >>> c = Counter() # a new, empty counter + >>> c = Counter('gallahad') # a new counter from an iterable + >>> c = Counter({'a': 4, 'b': 2}) # a new counter from a mapping + >>> c = Counter(a=4, b=2) # a new counter from keyword args + + 'u'Create a new, empty Counter object. And if given, count elements + from an input iterable. Or, initialize the count from another mapping + of elements to their counts. + + >>> c = Counter() # a new, empty counter + >>> c = Counter('gallahad') # a new counter from an iterable + >>> c = Counter({'a': 4, 'b': 2}) # a new counter from a mapping + >>> c = Counter(a=4, b=2) # a new counter from keyword args + + 'b'The count of elements not in the Counter is zero.'u'The count of elements not in the Counter is zero.'b'List the n most common elements and their counts from the most + common to the least. If n is None, then list all element counts. + + >>> Counter('abracadabra').most_common(3) + [('a', 5), ('b', 2), ('r', 2)] + + 'u'List the n most common elements and their counts from the most + common to the least. If n is None, then list all element counts. + + >>> Counter('abracadabra').most_common(3) + [('a', 5), ('b', 2), ('r', 2)] + + 'b'Iterator over elements repeating each as many times as its count. + + >>> c = Counter('ABCABC') + >>> sorted(c.elements()) + ['A', 'A', 'B', 'B', 'C', 'C'] + + # Knuth's example for prime factors of 1836: 2**2 * 3**3 * 17**1 + >>> prime_factors = Counter({2: 2, 3: 3, 17: 1}) + >>> product = 1 + >>> for factor in prime_factors.elements(): # loop over factors + ... product *= factor # and multiply them + >>> product + 1836 + + Note, if an element's count has been set to zero or is a negative + number, elements() will ignore it. + + 'u'Iterator over elements repeating each as many times as its count. + + >>> c = Counter('ABCABC') + >>> sorted(c.elements()) + ['A', 'A', 'B', 'B', 'C', 'C'] + + # Knuth's example for prime factors of 1836: 2**2 * 3**3 * 17**1 + >>> prime_factors = Counter({2: 2, 3: 3, 17: 1}) + >>> product = 1 + >>> for factor in prime_factors.elements(): # loop over factors + ... product *= factor # and multiply them + >>> product + 1836 + + Note, if an element's count has been set to zero or is a negative + number, elements() will ignore it. + + 'b'Counter.fromkeys() is undefined. Use Counter(iterable) instead.'u'Counter.fromkeys() is undefined. Use Counter(iterable) instead.'b'Like dict.update() but add counts instead of replacing them. + + Source can be an iterable, a dictionary, or another Counter instance. + + >>> c = Counter('which') + >>> c.update('witch') # add elements from another iterable + >>> d = Counter('watch') + >>> c.update(d) # add elements from another counter + >>> c['h'] # four 'h' in which, witch, and watch + 4 + + 'u'Like dict.update() but add counts instead of replacing them. + + Source can be an iterable, a dictionary, or another Counter instance. + + >>> c = Counter('which') + >>> c.update('witch') # add elements from another iterable + >>> d = Counter('watch') + >>> c.update(d) # add elements from another counter + >>> c['h'] # four 'h' in which, witch, and watch + 4 + + 'b'Like dict.update() but subtracts counts instead of replacing them. + Counts can be reduced below zero. Both the inputs and outputs are + allowed to contain zero and negative counts. + + Source can be an iterable, a dictionary, or another Counter instance. + + >>> c = Counter('which') + >>> c.subtract('witch') # subtract elements from another iterable + >>> c.subtract(Counter('watch')) # subtract elements from another counter + >>> c['h'] # 2 in which, minus 1 in witch, minus 1 in watch + 0 + >>> c['w'] # 1 in which, minus 1 in witch, minus 1 in watch + -1 + + 'u'Like dict.update() but subtracts counts instead of replacing them. + Counts can be reduced below zero. Both the inputs and outputs are + allowed to contain zero and negative counts. + + Source can be an iterable, a dictionary, or another Counter instance. + + >>> c = Counter('which') + >>> c.subtract('witch') # subtract elements from another iterable + >>> c.subtract(Counter('watch')) # subtract elements from another counter + >>> c['h'] # 2 in which, minus 1 in witch, minus 1 in watch + 0 + >>> c['w'] # 1 in which, minus 1 in witch, minus 1 in watch + -1 + + 'b'Return a shallow copy.'u'Return a shallow copy.'b'Like dict.__delitem__() but does not raise KeyError for missing values.'u'Like dict.__delitem__() but does not raise KeyError for missing values.'b'%r: %r'u'%r: %r'b'%s({%s})'u'%s({%s})'b'{0}({1!r})'u'{0}({1!r})'b'Add counts from two counters. + + >>> Counter('abbb') + Counter('bcc') + Counter({'b': 4, 'c': 2, 'a': 1}) + + 'u'Add counts from two counters. + + >>> Counter('abbb') + Counter('bcc') + Counter({'b': 4, 'c': 2, 'a': 1}) + + 'b' Subtract count, but keep only results with positive counts. + + >>> Counter('abbbc') - Counter('bccd') + Counter({'b': 2, 'a': 1}) + + 'u' Subtract count, but keep only results with positive counts. + + >>> Counter('abbbc') - Counter('bccd') + Counter({'b': 2, 'a': 1}) + + 'b'Union is the maximum of value in either of the input counters. + + >>> Counter('abbb') | Counter('bcc') + Counter({'b': 3, 'c': 2, 'a': 1}) + + 'u'Union is the maximum of value in either of the input counters. + + >>> Counter('abbb') | Counter('bcc') + Counter({'b': 3, 'c': 2, 'a': 1}) + + 'b' Intersection is the minimum of corresponding counts. + + >>> Counter('abbb') & Counter('bcc') + Counter({'b': 1}) + + 'u' Intersection is the minimum of corresponding counts. + + >>> Counter('abbb') & Counter('bcc') + Counter({'b': 1}) + + 'b'Adds an empty counter, effectively stripping negative and zero counts'u'Adds an empty counter, effectively stripping negative and zero counts'b'Subtracts from an empty counter. Strips positive and zero counts, + and flips the sign on negative counts. + + 'u'Subtracts from an empty counter. Strips positive and zero counts, + and flips the sign on negative counts. + + 'b'Internal method to strip elements with a negative or zero count'u'Internal method to strip elements with a negative or zero count'b'Inplace add from another counter, keeping only positive counts. + + >>> c = Counter('abbb') + >>> c += Counter('bcc') + >>> c + Counter({'b': 4, 'c': 2, 'a': 1}) + + 'u'Inplace add from another counter, keeping only positive counts. + + >>> c = Counter('abbb') + >>> c += Counter('bcc') + >>> c + Counter({'b': 4, 'c': 2, 'a': 1}) + + 'b'Inplace subtract counter, but keep only results with positive counts. + + >>> c = Counter('abbbc') + >>> c -= Counter('bccd') + >>> c + Counter({'b': 2, 'a': 1}) + + 'u'Inplace subtract counter, but keep only results with positive counts. + + >>> c = Counter('abbbc') + >>> c -= Counter('bccd') + >>> c + Counter({'b': 2, 'a': 1}) + + 'b'Inplace union is the maximum of value from either counter. + + >>> c = Counter('abbb') + >>> c |= Counter('bcc') + >>> c + Counter({'b': 3, 'c': 2, 'a': 1}) + + 'u'Inplace union is the maximum of value from either counter. + + >>> c = Counter('abbb') + >>> c |= Counter('bcc') + >>> c + Counter({'b': 3, 'c': 2, 'a': 1}) + + 'b'Inplace intersection is the minimum of corresponding counts. + + >>> c = Counter('abbb') + >>> c &= Counter('bcc') + >>> c + Counter({'b': 1}) + + 'u'Inplace intersection is the minimum of corresponding counts. + + >>> c = Counter('abbb') + >>> c &= Counter('bcc') + >>> c + Counter({'b': 1}) + + 'b' A ChainMap groups multiple dicts (or other mappings) together + to create a single, updateable view. + + The underlying mappings are stored in a list. That list is public and can + be accessed or updated using the *maps* attribute. There is no other + state. + + Lookups search the underlying mappings successively until a key is found. + In contrast, writes, updates, and deletions only operate on the first + mapping. + + 'u' A ChainMap groups multiple dicts (or other mappings) together + to create a single, updateable view. + + The underlying mappings are stored in a list. That list is public and can + be accessed or updated using the *maps* attribute. There is no other + state. + + Lookups search the underlying mappings successively until a key is found. + In contrast, writes, updates, and deletions only operate on the first + mapping. + + 'b'Initialize a ChainMap by setting *maps* to the given mappings. + If no mappings are provided, a single empty dictionary is used. + + 'u'Initialize a ChainMap by setting *maps* to the given mappings. + If no mappings are provided, a single empty dictionary is used. + + 'b'Create a ChainMap with a single dict created from the iterable.'u'Create a ChainMap with a single dict created from the iterable.'b'New ChainMap or subclass with a new copy of maps[0] and refs to maps[1:]'u'New ChainMap or subclass with a new copy of maps[0] and refs to maps[1:]'b'New ChainMap with a new map followed by all previous maps. + If no map is provided, an empty dict is used. + 'u'New ChainMap with a new map followed by all previous maps. + If no map is provided, an empty dict is used. + 'b'New ChainMap from maps[1:].'u'New ChainMap from maps[1:].'b'Key not found in the first mapping: {!r}'u'Key not found in the first mapping: {!r}'b'Remove and return an item pair from maps[0]. Raise KeyError is maps[0] is empty.'u'Remove and return an item pair from maps[0]. Raise KeyError is maps[0] is empty.'b'No keys found in the first mapping.'u'No keys found in the first mapping.'b'Remove *key* from maps[0] and return its value. Raise KeyError if *key* not in maps[0].'u'Remove *key* from maps[0] and return its value. Raise KeyError if *key* not in maps[0].'b'Clear maps[0], leaving maps[1:] intact.'u'Clear maps[0], leaving maps[1:] intact.'b'descriptor '__init__' of 'UserDict' object needs an argument'u'descriptor '__init__' of 'UserDict' object needs an argument'b'expected at most 1 arguments, got %d'u'expected at most 1 arguments, got %d'b'dict'u'dict'b'Passing 'dict' as keyword argument is deprecated'u'Passing 'dict' as keyword argument is deprecated'b'($self, dict=None, /, **kwargs)'u'($self, dict=None, /, **kwargs)'b'__missing__'u'__missing__'b'A more or less complete user-defined wrapper around list objects.'u'A more or less complete user-defined wrapper around list objects.'b'strict'u'strict'u'collections.__init__'u'collections'The asyncio package, tracking PEP 3156.base_eventscoroutinesexceptionsfutureslocksprotocolsrunnersqueuesstreamssubprocesstaskstransports_all_tasks_compatwindows_eventsunix_events# flake8: noqa# This relies on each of the submodules having an __all__ variable.# Exposed for _asynciomodule.c to implement now deprecated# Task.all_tasks() method. This function will be removed in 3.9.# NoQAb'The asyncio package, tracking PEP 3156.'u'The asyncio package, tracking PEP 3156.'u'asyncio.__init__'u'asyncio' +Python unit testing framework, based on Erich Gamma's JUnit and Kent Beck's +Smalltalk testing framework (used with permission). + +This module contains the core framework classes that form the basis of +specific test cases and suites (TestCase, TestSuite etc.), and also a +text-based utility class for running the tests and reporting the results + (TextTestRunner). + +Simple usage: + + import unittest + + class IntegerArithmeticTestCase(unittest.TestCase): + def testAdd(self): # test method names begin with 'test' + self.assertEqual((1 + 2), 3) + self.assertEqual(0 + 1, 1) + def testMultiply(self): + self.assertEqual((0 * 10), 0) + self.assertEqual((5 * 8), 40) + + if __name__ == '__main__': + unittest.main() + +Further information is available in the bundled documentation, and from + + http://docs.python.org/library/unittest.html + +Copyright (c) 1999-2003 Steve Purcell +Copyright (c) 2003-2010 Python Software Foundation +This module is free software, and you may redistribute it and/or modify +it under the same terms as Python itself, so long as this copyright message +and disclaimer are retained in their original form. + +IN NO EVENT SHALL THE AUTHOR BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT, +SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF +THIS CODE, EVEN IF THE AUTHOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. + +THE AUTHOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, +AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, +SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. +TestResultTestCaseIsolatedAsyncioTestCaseTestSuiteTextTestRunnerTestLoaderFunctionTestCasemaindefaultTestLoaderSkipTestskipskipIfexpectedFailureTextTestResultinstallHandlerregisterResultremoveResultaddModuleCleanupgetTestCaseNamesmakeSuitefindTestCases__unittestasync_casecasesuiteBaseTestSuiteTestProgramrunnersignals_TextTestResulttestsos.paththis_dirdiscoverstart_dir# Expose obsolete functions for backwards compatibility# deprecated# There are no tests here, so don't try to run anything discovered from# introspecting the symbols (e.g. FunctionTestCase). Instead, all our# tests come from within unittest.test.# top level directory cached on loader instanceb' +Python unit testing framework, based on Erich Gamma's JUnit and Kent Beck's +Smalltalk testing framework (used with permission). + +This module contains the core framework classes that form the basis of +specific test cases and suites (TestCase, TestSuite etc.), and also a +text-based utility class for running the tests and reporting the results + (TextTestRunner). + +Simple usage: + + import unittest + + class IntegerArithmeticTestCase(unittest.TestCase): + def testAdd(self): # test method names begin with 'test' + self.assertEqual((1 + 2), 3) + self.assertEqual(0 + 1, 1) + def testMultiply(self): + self.assertEqual((0 * 10), 0) + self.assertEqual((5 * 8), 40) + + if __name__ == '__main__': + unittest.main() + +Further information is available in the bundled documentation, and from + + http://docs.python.org/library/unittest.html + +Copyright (c) 1999-2003 Steve Purcell +Copyright (c) 2003-2010 Python Software Foundation +This module is free software, and you may redistribute it and/or modify +it under the same terms as Python itself, so long as this copyright message +and disclaimer are retained in their original form. + +IN NO EVENT SHALL THE AUTHOR BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT, +SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF +THIS CODE, EVEN IF THE AUTHOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. + +THE AUTHOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, +AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, +SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. +'u' +Python unit testing framework, based on Erich Gamma's JUnit and Kent Beck's +Smalltalk testing framework (used with permission). + +This module contains the core framework classes that form the basis of +specific test cases and suites (TestCase, TestSuite etc.), and also a +text-based utility class for running the tests and reporting the results + (TextTestRunner). + +Simple usage: + + import unittest + + class IntegerArithmeticTestCase(unittest.TestCase): + def testAdd(self): # test method names begin with 'test' + self.assertEqual((1 + 2), 3) + self.assertEqual(0 + 1, 1) + def testMultiply(self): + self.assertEqual((0 * 10), 0) + self.assertEqual((5 * 8), 40) + + if __name__ == '__main__': + unittest.main() + +Further information is available in the bundled documentation, and from + + http://docs.python.org/library/unittest.html + +Copyright (c) 1999-2003 Steve Purcell +Copyright (c) 2003-2010 Python Software Foundation +This module is free software, and you may redistribute it and/or modify +it under the same terms as Python itself, so long as this copyright message +and disclaimer are retained in their original form. + +IN NO EVENT SHALL THE AUTHOR BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT, +SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF +THIS CODE, EVEN IF THE AUTHOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. + +THE AUTHOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +PARTICULAR PURPOSE. THE CODE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, +AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, +SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. +'b'TestResult'u'TestResult'b'TestCase'u'TestCase'b'IsolatedAsyncioTestCase'u'IsolatedAsyncioTestCase'b'TestSuite'u'TestSuite'b'TextTestRunner'u'TextTestRunner'b'TestLoader'u'TestLoader'b'FunctionTestCase'u'FunctionTestCase'b'main'u'main'b'defaultTestLoader'u'defaultTestLoader'b'SkipTest'u'SkipTest'b'skip'u'skip'b'skipIf'u'skipIf'b'skipUnless'u'skipUnless'b'expectedFailure'u'expectedFailure'b'TextTestResult'u'TextTestResult'b'installHandler'u'installHandler'b'registerResult'u'registerResult'b'removeResult'u'removeResult'b'removeHandler'u'removeHandler'b'addModuleCleanup'u'addModuleCleanup'b'getTestCaseNames'u'getTestCaseNames'b'makeSuite'u'makeSuite'b'findTestCases'u'findTestCases'u'unittest.__init__'u'unittest'Core XML support for Python. + +This package contains four sub-packages: + +dom -- The W3C Document Object Model. This supports DOM Level 1 + + Namespaces. + +parsers -- Python wrappers for XML parsers (currently only supports Expat). + +sax -- The Simple API for XML, developed by XML-Dev, led by David + Megginson and ported to Python by Lars Marius Garshol. This + supports the SAX 2 API. + +etree -- The ElementTree XML library. This is a subset of the full + ElementTree XML release. + +domparserssaxetreeb'Core XML support for Python. + +This package contains four sub-packages: + +dom -- The W3C Document Object Model. This supports DOM Level 1 + + Namespaces. + +parsers -- Python wrappers for XML parsers (currently only supports Expat). + +sax -- The Simple API for XML, developed by XML-Dev, led by David + Megginson and ported to Python by Lars Marius Garshol. This + supports the SAX 2 API. + +etree -- The ElementTree XML library. This is a subset of the full + ElementTree XML release. + +'u'Core XML support for Python. + +This package contains four sub-packages: + +dom -- The W3C Document Object Model. This supports DOM Level 1 + + Namespaces. + +parsers -- Python wrappers for XML parsers (currently only supports Expat). + +sax -- The Simple API for XML, developed by XML-Dev, led by David + Megginson and ported to Python by Lars Marius Garshol. This + supports the SAX 2 API. + +etree -- The ElementTree XML library. This is a subset of the full + ElementTree XML release. + +'b'dom'u'dom'b'parsers'b'sax'u'sax'b'etree'u'xml.__init__' +General functions for HTML manipulation. +_rehtml.entitieshtml5_html5escapeunescapequote + Replace special characters "&", "<" and ">" to HTML-safe sequences. + If the optional flag quote is true (the default), the quotation mark + characters, both double quote (") and single quote (') characters are also + translated. + '�0x000x0d€0x801290x81‚1300x82ƒ1310x83„1320x84…1330x85†1340x86‡1350x87ˆ1360x88‰1370x89Š1380x8a‹1390x8bŒ1400x8c1410x8dŽ1420x8e1430x8f1440x90‘1450x91’1460x92“1470x93”1480x94•1490x95–1500x96—1510x97˜1520x98™1530x99š1540x9a›1550x9bœ1560x9c1570x9dž1580x9eŸ1590x9f_invalid_charrefs0x10x20x30x40x50x60x70x80xe0xf0x100x110x120x130x140x150x160x170x180x190x1a0x1b0x1c0x1d0x1e0x1f1270x7f649760xfdd0649770xfdd1649780xfdd2649790xfdd3649800xfdd4649810xfdd5649820xfdd6649830xfdd7649840xfdd8649850xfdd9649860xfdda649870xfddb649880xfddc649890xfddd649900xfdde649910xfddf649920xfde0649930xfde1649940xfde2649950xfde3649960xfde4649970xfde5649980xfde6649990xfde7650000xfde8650010xfde9650020xfdea650030xfdeb650040xfdec650050xfded650060xfdee650070xfdef0xb655340xfffe655350xffff1310700x1fffe1310710x1ffff1966060x2fffe1966070x2ffff2621420x3fffe2621430x3ffff3276780x4fffe3276790x4ffff3932140x5fffe3932150x5ffff4587500x6fffe4587510x6ffff5242860x7fffe5242870x7ffff5898220x8fffe5898230x8ffff6553580x9fffe6553590x9ffff7208940xafffe7208950xaffff7864300xbfffe7864310xbffff8519660xcfffe8519670xcffff9175020xdfffe9175030xdffff9830380xefffe9830390xeffff10485740xffffe10485750xfffff11141100x10fffe0x10ffff_invalid_codepoints_replace_charrefxX;552960xD800573430xDFFF0x10FFFF&(#[0-9]+;?|#[xX][0-9a-fA-F]+;?|[^\t\n\f <&#;]{1,32};?)r'&(#[0-9]+;?'r'|#[xX][0-9a-fA-F]+;?'r'|[^\t\n\f <&#;]{1,32};?)'_charref + Convert all named and numeric character references (e.g. >, >, + &x3e;) in the string s to the corresponding unicode characters. + This function uses the rules defined by the HTML 5 standard + for both valid and invalid character references, and the list of + HTML 5 named character references defined in html.entities.html5. + # Must be done first!# see http://www.w3.org/TR/html5/syntax.html#tokenizing-character-references# REPLACEMENT CHARACTER# CARRIAGE RETURN# EURO SIGN# # SINGLE LOW-9 QUOTATION MARK# LATIN SMALL LETTER F WITH HOOK# DOUBLE LOW-9 QUOTATION MARK# HORIZONTAL ELLIPSIS# DAGGER# DOUBLE DAGGER# MODIFIER LETTER CIRCUMFLEX ACCENT# PER MILLE SIGN# LATIN CAPITAL LETTER S WITH CARON# SINGLE LEFT-POINTING ANGLE QUOTATION MARK# LATIN CAPITAL LIGATURE OE# LATIN CAPITAL LETTER Z WITH CARON# LEFT SINGLE QUOTATION MARK# RIGHT SINGLE QUOTATION MARK# LEFT DOUBLE QUOTATION MARK# RIGHT DOUBLE QUOTATION MARK# BULLET# EN DASH# EM DASH# SMALL TILDE# TRADE MARK SIGN# LATIN SMALL LETTER S WITH CARON# SINGLE RIGHT-POINTING ANGLE QUOTATION MARK# LATIN SMALL LIGATURE OE# LATIN SMALL LETTER Z WITH CARON# LATIN CAPITAL LETTER Y WITH DIAERESIS# 0x0001 to 0x0008# 0x000E to 0x001F# 0x007F to 0x009F# 0xFDD0 to 0xFDEF# others# numeric charref# named charref# find the longest matching name (as defined by the standard)b' +General functions for HTML manipulation. +'u' +General functions for HTML manipulation. +'b'escape'u'escape'b'unescape'u'unescape'b' + Replace special characters "&", "<" and ">" to HTML-safe sequences. + If the optional flag quote is true (the default), the quotation mark + characters, both double quote (") and single quote (') characters are also + translated. + 'u' + Replace special characters "&", "<" and ">" to HTML-safe sequences. + If the optional flag quote is true (the default), the quotation mark + characters, both double quote (") and single quote (') characters are also + translated. + 'b'''u'''u'�'u'€'b''u''u'‚'u'ƒ'u'„'u'…'u'†'u'‡'u'ˆ'u'‰'u'Š'u'‹'u'Œ'b''u''u'Ž'b''u''b''u''u'‘'u'’'u'“'u'”'u'•'u'–'u'—'u'˜'u'™'u'š'u'›'u'œ'b''u''u'ž'u'Ÿ'b'#'u'#'b'xX'u'xX'b';'u';'b'&(#[0-9]+;?|#[xX][0-9a-fA-F]+;?|[^\t\n\f <&#;]{1,32};?)'u'&(#[0-9]+;?|#[xX][0-9a-fA-F]+;?|[^\t\n\f <&#;]{1,32};?)'b' + Convert all named and numeric character references (e.g. >, >, + &x3e;) in the string s to the corresponding unicode characters. + This function uses the rules defined by the HTML 5 standard + for both valid and invalid character references, and the list of + HTML 5 named character references defined in html.entities.html5. + 'u' + Convert all named and numeric character references (e.g. >, >, + &x3e;) in the string s to the corresponding unicode characters. + This function uses the rules defined by the HTML 5 standard + for both valid and invalid character references, and the list of + HTML 5 named character references defined in html.entities.html5. + 'u'html.__init__'Supporting definitions for the Python regression tests.test.supportsupport must be imported from the test packageasyncio.eventsasynciofaulthandlerfnmatchfunctoolsgcglobhashlibimportlib.utillogging.handlersloggingnntplibshutilsocketstatstructsysconfigtempfile_threadurllib.errorurllibtestresultget_test_runnermultiprocessing.processzlibgzipbz2lzmaresource_hashlibPIPE_MAX_SIZEmax_memuseuse_resourcesfailfastErrorTestFailedTestDidNotRunResourceDeniedimport_fresh_moduleCleanImportunloadrecord_original_stdoutget_original_stdoutcaptured_stdoutcaptured_stdincaptured_stderrTESTFNSAVEDCWDunlinkrmtreetemp_cwdfindfilecreate_empty_filecan_symlinkfs_is_case_insensitiveis_resource_enabledrequiresrequires_freebsd_versionrequires_linux_versionrequires_mac_verrequires_hashdigestcheck_syntax_errorcheck_syntax_warningTransientResourcetime_outsocket_peer_resetioerror_peer_resettransient_internetBasicTestRunnerrun_unittestrun_doctestskip_unless_symlinkrequires_gziprequires_bz2requires_lzmabigmemtestbigaddrspacetestcpython_onlyget_attributerequires_IEEE_754skip_unless_xattrrequires_zlibanticipate_failuredetect_api_mismatchcheck__all__skip_unless_bind_unix_socketskip_if_buggy_ucrt_strfptimeignore_warningsis_jythonis_androidcheck_impl_detailunix_shellHOSTIPV6_ENABLEDfind_unused_portbind_portopen_urlresourcebind_unix_sockettemp_umaskreap_childrenTestHandlerthreading_setupthreading_cleanupreap_threadsstart_threadscheck_warningscheck_no_resource_warningcheck_no_warningsEnvironmentVarGuardrun_with_localeswap_itemswap_attrMatcherset_memlimitSuppressCrashReportsortdictrun_with_tzPGOmissing_compiler_executablefd_countALWAYS_EQLARGESTSMALLESTBase class for regression test exceptions.Test failed.Test did not run any subtests.Test skipped because it requested a disallowed resource. + + This is raised when a test calls requires() for a resource that + has not be enabled. It is used to distinguish between expected + and unexpected skips. + _ignore_deprecated_importsignoreContext manager to suppress package and module deprecation + warnings when importing them. + + If ignore is False, this context manager has no effect. + catch_warningsfilterwarnings.+ (module|package)Decorator to suppress deprecation warnings. + + Use of context managers to hide warnings make diffs + more noisy and tools like 'git blame' less useful. + decoratorwrapswrappersimplefilterdeprecatedrequired_onImport and return the module to be tested, raising SkipTest if + it is not available. + + If deprecated is True, any module or package deprecation messages + will be suppressed. If a module is required on a platform but optional for + others, set required_on to an iterable of platform prefixes which will be + compared against sys.platform. + _save_and_remove_moduleorig_modulesHelper function to save and remove a module from sys.modules + + Raise ImportError if the module can't be imported. + _save_and_block_moduleHelper function to save and block a module in sys.modules + + Return True if the module was in sys.modules, False otherwise. + savedconditionDecorator to mark a test that is known to be broken in some cases + + Any use of this decorator should have a comment identifying the + associated tracker issue. + pkg_dirstandard_testsGeneric load_tests implementation for simple test packages. + + Most packages can implement load_tests using this function as follows: + + def load_tests(*args): + return load_package_tests(os.path.dirname(__file__), *args) + test*top_dirtop_level_dirpackage_testsaddTestsfreshblockedImport and return a module, deliberately bypassing sys.modules. + + This function imports and returns a fresh copy of the named Python module + by removing the named module from sys.modules before doing the import. + Note that unlike reload, the original module is not affected by + this operation. + + *fresh* is an iterable of additional module names that are also removed + from the sys.modules cache before doing the import. + + *blocked* is an iterable of module names that are replaced with None + in the module cache during the import to ensure that attempts to import + them raise ImportError. + + The named module and any modules named in the *fresh* and *blocked* + parameters are saved before starting the import and then reinserted into + sys.modules when the fresh import is complete. + + Module and package deprecation messages are suppressed during this import + if *deprecated* is True. + + This function will raise ImportError if the named module cannot be + imported. + names_to_removefresh_nameblocked_namefresh_moduleorig_namename_to_removeGet an attribute, raising SkipTest if AttributeError is raised.attributeobject %r has no attribute %rreal_max_memusejunit_xml_list_original_stdout_force_run%s: %sre-run %s%rchmodS_IRWXUwin_waitforwaitall0.001timeoutlistdirLsleeptests may fail, delete still pending for _unlink_rmdirrmdir_rmtree_rmtree_innerfullnamelstatst_modesupport.rmtree(): os.lstat(%r) failed with %sS_ISDIR_longpathcreate_unicode_bufferwindllkernel32GetLongPathNameWlengthmake_legacy_pycMove a PEP 3147/488 pyc file to its legacy pyc location. + + :param source: The file system path to the source file. The source file + does not need to exist, however the PEP 3147/488 pyc file must exist. + :return: The file system path to the legacy pyc file. + utilcache_from_sourcepyc_fileup_onelegacy_pyc'Forget' a module was ever imported. + + This removes the module from sys.modules and deletes any PEP 3147/488 or + legacy .pyc files. + optimization_is_gui_availablectypes.wintypesUOI_FLAGS0x0001WSF_VISIBLEUSEROBJECTFLAGSStructurefInheritwintypesBOOLfReserveddwFlagsDWORD_fields_user32dllGetProcessWindowStationWinErroruofneededGetUserObjectInformationWbyrefgui not available (WSF_VISIBLE flag not set)cdllc_intpointerctypes.utilfind_libraryLoadLibraryApplicationServicesapp_servicesCGMainDisplayIDgui tests cannot run without OS X window managerProcessSerialNumberhighLongOfPSNlowLongOfPSNpsnpsn_pGetCurrentProcessSetFrontProcesscannot run without OS X gui processtkintererr_string [...]Tk unavailable due to {}: {}Test whether a resource is enabled. + + Known resources are set by regrtest.py. If not running under regrtest.py, + all resources are assumed enabled unless use_resources has been set. + Raise ResourceDenied if the specified resource is not available.Use of the %r resource not enabledgui_requires_unix_versionsysnamemin_versionDecorator raising SkipTest if the OS is `sysname` and the version is less + than `min_version`. + + For example, @_requires_unix_version('FreeBSD', (7, 2)) raises SkipTest if + the FreeBSD version is less than 7.2. + min_version_txtversion_txt version or higher required, not " or higher required, not """Decorator raising SkipTest if the OS is FreeBSD and the FreeBSD version is + less than `min_version`. + + For example, @requires_freebsd_version(7, 2) raises SkipTest if the FreeBSD + version is less than 7.2. + FreeBSDDecorator raising SkipTest if the OS is Linux and the Linux version is + less than `min_version`. + + For example, @requires_linux_version(2, 6, 32) raises SkipTest if the Linux + version is less than 2.6.32. + LinuxDecorator raising SkipTest if the OS is Mac OS X and the OS X + version if less than min_version. + + For example, @requires_mac_ver(10, 5) raises SkipTest if the OS X version + is lesser than 10.5. + mac_verMac OS X %s or higher required, not %sdigestnameopensslDecorator raising SkipTest if a hashing algorithm is not available + + The hashing algorithm could be missing or blocked by a strict crypto + policy. + + If 'openssl' is True, then the decorator checks that OpenSSL provides + the algorithm. Otherwise the check falls back to built-in + implementations. + + ValueError: [digital envelope routines: EVP_DigestInit_ex] disabled for FIPS + ValueError: unsupported hash type md4 + hash digest '' is not available.localhost127.0.0.1HOSTv4::1HOSTv6AF_INETSOCK_STREAMfamilysocktypeReturns an unused port that should be suitable for binding. This is + achieved by creating a temporary socket with the same family and type as + the 'sock' parameter (default is AF_INET, SOCK_STREAM), and binding it to + the specified host address (defaults to 0.0.0.0) with the port set to 0, + eliciting an unused ephemeral port from the OS. The temporary socket is + then closed and deleted, and the ephemeral port is returned. + + Either this method or bind_port() should be used for any tests where a + server socket needs to be bound to a particular port for the duration of + the test. Which one to use depends on whether the calling code is creating + a python socket, or if an unused port needs to be provided in a constructor + or passed to an external program (i.e. the -accept argument to openssl's + s_server mode). Always prefer bind_port() over find_unused_port() where + possible. Hard coded ports should *NEVER* be used. As soon as a server + socket is bound to a hard coded port, the ability to run multiple instances + of the test simultaneously on the same host is compromised, which makes the + test a ticking time bomb in a buildbot environment. On Unix buildbots, this + may simply manifest as a failed test, which can be recovered from without + intervention in most cases, but on Windows, the entire python process can + completely and utterly wedge, requiring someone to log in to the buildbot + and manually kill the affected process. + + (This is easy to reproduce on Windows, unfortunately, and can be traced to + the SO_REUSEADDR socket option having different semantics on Windows versus + Unix/Linux. On Unix, you can't have two AF_INET SOCK_STREAM sockets bind, + listen and then accept connections on identical host/ports. An EADDRINUSE + OSError will be raised at some point (depending on the platform and + the order bind and listen were called on each socket). + + However, on Windows, if SO_REUSEADDR is set on the sockets, no EADDRINUSE + will ever be raised when attempting to bind two identical host/ports. When + accept() is called on each socket, the second caller's process will steal + the port from the first caller, leaving them both in an awkwardly wedged + state where they'll no longer respond to any signals or graceful kills, and + must be forcibly killed via OpenProcess()/TerminateProcess(). + + The solution on Windows is to use the SO_EXCLUSIVEADDRUSE socket option + instead of SO_REUSEADDR, which effectively affords the same semantics as + SO_REUSEADDR on Unix. Given the propensity of Unix developers in the Open + Source world compared to Windows ones, this is a common mistake. A quick + look over OpenSSL's 0.9.8g source shows that they use SO_REUSEADDR when + openssl.exe is called with the 's_server' option, for example. See + http://bugs.python.org/issue2550 for more info. The following site also + has a very thorough description about the implications of both REUSEADDR + and EXCLUSIVEADDRUSE on Windows: + http://msdn2.microsoft.com/en-us/library/ms740621(VS.85).aspx) + + XXX: although this approach is a vast improvement on previous attempts to + elicit unused ports, it rests heavily on the assumption that the ephemeral + port returned to us by the OS won't immediately be dished back out to some + other process when we close and delete our temporary socket but before our + calling code has a chance to bind the returned port. We can deal with this + issue if/when we come across it. + tempsockportsockhostBind the socket to a free port and return the port number. Relies on + ephemeral ports in order to ensure we are using an unbound port. This is + important as many tests may be running simultaneously, especially in a + buildbot environment. This method raises an exception if the sock.family + is AF_INET and sock.type is SOCK_STREAM, *and* the socket has SO_REUSEADDR + or SO_REUSEPORT set on it. Tests should *never* set these socket options + for TCP/IP sockets. The only case for setting these options is testing + multicasting via multiple UDP sockets. + + Additionally, if the SO_EXCLUSIVEADDRUSE socket option is available (i.e. + on Windows), it will be set on the socket. This will prevent anyone else + from bind()'ing to our host/port for the duration of the test. + SO_REUSEADDRgetsockoptSOL_SOCKETtests should never set the SO_REUSEADDR socket option on TCP/IP sockets!"tests should never set the SO_REUSEADDR ""socket option on TCP/IP sockets!"SO_REUSEPORTtests should never set the SO_REUSEPORT socket option on TCP/IP sockets!"tests should never set the SO_REUSEPORT "SO_EXCLUSIVEADDRUSEsetsockoptgetsocknameaddrBind a unix socket, raising SkipTest if PermissionError is raised.AF_UNIXcannot bind AF_UNIX sockets_is_ipv6_enabledCheck whether IPv6 is enabled on this host.has_ipv6AF_INET6system_must_validate_certSkip the test on TLS certificate validation failures.decCERTIFICATE_VERIFY_FAILEDsystem does not contain necessary certificates"system does not contain ""necessary certificates"SOCK_MAX_SIZEdoubleIEEEtest requires IEEE 754 doublesrequires zlibrequires gziprequires bz2requires lzmajavagetandroidapilevel/system/bin/sh/bin/sh$test@test{}_{}_tmphttp://www.pythontest.netTEST_HTTP_URLFS_NONASCIIæİŁφКא،تก fsdecodefsencode-àòɘŁğTESTFN_UNICODEunicodedatanormalizeNFDTESTFN_ENCODINGTESTFN_UNENCODABLEntgetwindowsversion-共Ł♡ͣ�WARNING: The filename %r CAN be encoded by the filesystem encoding (%s). Unicode filename tests may not be effective'WARNING: The filename %r CAN be encoded by the filesystem encoding (%s). ''Unicode filename tests may not be effective'ÿb'-ÿsurrogateescapeTESTFN_UNDECODABLEçwð®Õí²€b'\xae\xd5'b'\xed\xb2\x80'í´€˜TESTFN_NONASCIIgetcwdPGO_EXTENDEDtemp_dirReturn a context manager that creates a temporary directory. + + Arguments: + + path: the directory to create temporarily. If omitted or None, + defaults to creating a temporary directory using tempfile.mkdtemp. + + quiet: if False (the default), the context manager raises an exception + on error. Otherwise, if the path is specified and cannot be + created, only a warning is issued. + + dir_createdmkdtemprealpathmkdirtests may fail, unable to create temporary directory 'tests may fail, unable to create ''temporary directory ': pidchange_cwdReturn a context manager that changes the current working directory. + + Arguments: + + path: the directory to use as the temporary current working directory. + + quiet: if False (the default), the context manager raises an exception + on error. Otherwise, it issues only a warning and keeps the current + working directory the same. + + saved_dirchdirtests may fail, unable to change the current working directory to 'tests may fail, unable to change the current working ''directory to 'tempcwd + Context manager that temporarily creates and changes the CWD. + + The function temporarily changes the current working directory + after creating a temporary directory in the current directory with + name *name*. If *name* is None, the temporary directory is + created using tempfile.mkdtemp. + + If *quiet* is False (default) and it is not possible to + create or change the CWD, an error is raised. If *quiet* is True, + only a warning is raised and the original CWD is used. + + temp_pathcwd_dirumaskContext manager that temporarily sets the process umask.oldmaskTEST_SUPPORT_DIRTEST_HOME_DIRTEST_DATA_DIRsubdirTry to find a file on sys.path or in the test directory. If it is not + found the argument passed to the function is returned (this does not + necessarily signal failure; could still be the legitimate path). + + Setting *subdir* indicates a relative path to use to find the file + rather than looking directly in the path directories. + isabsdnCreate an empty file. If the file already exists, truncate it.O_WRONLYO_CREATO_TRUNCfdLike repr(dict), but in sorted order.pairreprpairswithcommasmake_bad_fd + Create an invalid file descriptor by opening and closing a file and return + its fd. + wbtestcasestatementerrtextassertRaisesRegexcmassertIsNotNoneassertEqualwarnsalwaysassertTrueassertRegexurlurllib.requesturllib.parsecheckurlparsecheck_valid_fileurlfetch fetching %s ...requestbuild_openeropeneraddheadersAccept-EncodingheadersContent-EncodingGzipFilefileobjinvalid resource %rWarningsRecorderConvenience wrapper for the warnings list returned on + entry to the warnings.catch_warnings() context manager. + warnings_list_warningsWarningMessage_WARNING_DETAILS%r has no attribute %r_filterwarningsCatch the warnings, then check if all the expected + warnings have been raised and re-raise unexpected warnings. + If 'quiet' is True, only re-raise the unexpected warnings. + __warningregistry__registryreraisemissingcatunhandled warning %sfilter (%r, %s) did not catch any warningContext manager to silence warnings. + + Accept 2-tuples as positional arguments: + ("message regexp", WarningCategory) + + Optional argument: + - if 'quiet' is True, it does not fail if a filter catches nothing + (default True without argument, + default False if some filters are defined) + + Without argument, it defaults to: + check_warnings(("", Warning), quiet=True) + force_gcContext manager to check that no warnings are emitted. + + This context manager enables a given warning within its scope + and checks that no warnings are emitted even with that warning + enabled. + + If force_gc is True, a garbage collection is attempted before checking + for warnings. This may help to catch warnings emitted when objects + are deleted, such as ResourceWarning. + + Other keyword arguments are passed to warnings.filterwarnings(). + gc_collectContext manager to check that no ResourceWarning is emitted. + + Usage: + + with check_no_resource_warning(self): + f = open(...) + ... + del f + + You must remove the object which may emit ResourceWarning before + the end of the context manager. + Context manager to force import to return a new module reference. + + This is useful for testing module-level behaviours, such as + the emission of a DeprecationWarning on import. + + Use like this: + + with CleanImport("foo"): + importlib.import_module("foo") # new reference + module_namesoriginal_modulesmodule_nameignore_excClass to help protect the environment variable properly. Can be used as + a context manager._environ_changedenvvarDirsOnSysPathContext manager to temporarily add directories to sys.path. + + This makes a copy of sys.path, appends any directories given + as positional arguments, then reverts sys.path to the copied + settings when the context ends. + + Note that *all* sys.path modifications in the body of the + context manager, including replacement of the object, + will be reverted at the end of the block. + pathsoriginal_valueoriginal_objectRaise ResourceDenied if an exception is raised while the context manager + is in effect that matches the specified exception and attributes.type_If type_ is a subclass of self.exc and value has attributes matching + self.attrs, raise ResourceDenied. Otherwise let the exception + propagate (if any).attr_valuean optional resource is not availableETIMEDOUTECONNRESETget_socket_conn_refused_errs + Get the different socket error numbers ('errno') which can be received + when a connection is refused. + ECONNREFUSEDENETUNREACHEADDRNOTAVAILEHOSTUNREACHEAFNOSUPPORT30.0resource_nameerrnosReturn a context manager that raises ResourceDenied when various issues + with the Internet connection manifest themselves as exceptions.11110411311099default_errnosEAI_AGAINEAI_FAILEAI_NONAMEEAI_NODATAWSANO_DATA11004default_gai_errnosResource %r is not availabledeniedcaptured_errnosgai_errnosfilter_errorgaierrorHTTPError599URLErrorgetdefaulttimeoutold_timeoutsetdefaulttimeoutNNTPTemporaryErrorcaptured_outputstream_nameReturn a context manager used by captured_stdout/stdin/stderr + that temporarily replaces the sys stream *stream_name* with a StringIO.orig_stdoutCapture the output of sys.stdout: + + with captured_stdout() as stdout: + print("hello") + self.assertEqual(stdout.getvalue(), "hello\n") + Capture the output of sys.stderr: + + with captured_stderr() as stderr: + print("hello", file=sys.stderr) + self.assertEqual(stderr.getvalue(), "hello\n") + Capture the input to sys.stdin: + + with captured_stdin() as stdin: + stdin.write('hello\n') + stdin.seek(0) + # call test code that consumes from sys.stdin + captured = input() + self.assertEqual(captured, "hello") + Force as many objects as possible to be collected. + + In non-CPython implementations of Python, this is needed because timely + deallocation is not guaranteed by the garbage collector. (Even in CPython + this can be the case in case of reference cycles.) This means that __del__ + methods may be called later than expected and weakrefs may remain alive for + longer than expected. This function tries its best to force all garbage + objects to disappear. + collect0.1disable_gcisenabledhave_gcenablepython_is_optimizedFind if Python was built with optimizations.get_config_varPY_CFLAGScflagsfinal_opt-O-O0-OgnP_header0n_aligngetobjects2P0P_vheadercalcobjsizecalcsizecalcvobjsize_TPFLAGS_HAVE_GC_TPFLAGS_HEAPTYPEcheck_sizeofo_testcapiSIZEOF_PYGC_HEADwrong size for %s: got %d, expected %dcatstrlocalesinnersetlocaleorig_localeloctztzsettzset requiredTZorig_tz_1M_1G_2G_4GMAX_Py_ssize_tlimitgsizes(\d+(\.\d+)?) (K|M|G|T)b?$IGNORECASEVERBOSEInvalid memory limit %rmemlimitMemory limit %r too low to be useful_MemoryWatchdogAn object which periodically watches the process' memory consumption + and prints it out. + /proc/{pid}/statmprocfilestartedr/proc not available for stats: {}memory_watchdog.pywatchdog_scriptPopenDEVNULLmem_watchdogterminatememusedry_runDecorator for bigmem tests. + + 'size' is a requested size for the test (in arbitrary, test-interpreted + units.) 'memuse' is the number of bytes per unit for the test, or a good + estimate of it. For example, a test that needs two byte buffers, of 4 GiB + each, could be decorated with @bigmemtest(size=_4G, memuse=2). + + The 'size' argument is normally passed to the decorated test method as an + extra argument. If 'dry_run' is true, the value passed to the test method + may be less than the requested value. If 'dry_run' is false, it means the + test doesn't support dummy runs when -M is not specified. + 5147not enough memory: %.1fG minimum needed ... expected peak memory use: {peak:.1f}GpeakwatchdogDecorator for tests that fill the address space.63not enough memory: try a 32-bit build insteadrun_idrequires_resourceresource {0!r} is not enabled + Decorator for tests only applicable on CPython. + impl_detailcpythonguards_parse_guardsguardnamesimplementation detail not available on {0}implementation detail specific to {0} or is_trueThis function returns True or False depending on the host platform. + Examples: + if check_impl_detail(): # only on CPython (default) + if check_impl_detail(jython=True): # only on Jython + if check_impl_detail(cpython=False): # everywhere except on CPython + python_implementationno_tracingDecorator to temporarily turn off tracing for the duration of a test.original_tracerefcount_testDecorator for tests which involve reference counting. + + To start, the decorator does not run the test if is not run by CPython. + After that, any trace function is unset during the test to prevent + unexpected refcounts caused by the trace function. + + _filter_suitepredRecursively filter test cases in a suite based on a predicate.newtests_tests_run_suiteRun tests from a unittest.TestSuite-derived class.verbositycapture_outputget_xml_elementtestsRunskippedwasSuccessfulfailuresmultiple errors occurred; run in verbose mode for details_match_test_func_accept_test_patterns_ignore_test_patternsmatch_test_is_full_match_test[?*\[\]]set_match_testsaccept_patternsignore_patternsaccept_funcignore_func_compile_match_functionmatch_functiontest_idacceptpatternsregexregex_matchmatch_test_regexRun tests from unittest.TestCase-derived classes.valid_typesaddTeststr arguments must be keys in sys.modules_check_docstringsJust used to check if docstrings are enabledWITH_DOC_STRINGSMISSING_C_DOCSTRINGSHAVE_DOCSTRINGStest requires docstringsrequires_docstringsoptionflagsRun doctest on the given module. Return (#failures, #tests). + + If optional argument verbosity is not specified (or is None), pass + support's belief about verbosity on to doctest. Else doctest's + usual behavior is used (it searches sys.argv for -v). + doctesttestmod%d of %d doctests faileddoctest (%s) ... %d tests with zero failuresprint_warningWarning -- modules_setupmodules_cleanupoldmodulesenvironment_altered_count_danglingoriginal_values_MAX_COUNTdangling_threadsthreading_cleanup() failed to cleanup "threading_cleanup() failed to cleanup " threads (count: " threads ""(count: ", dangling: ", ""dangling: "Dangling thread: 0.01Use this function when threads are being used. This will + ensure that the threads are cleaned up even when the test fails. + wait_threads_exit60.0 + bpo-31234: Context manager to wait until all threads created in the with + statement exit. + + Use _thread.count() to check if threads exited. Indirectly, wait until + threads exit the internal t_bootstrap() C function of the _thread module. + + threading_setup() and threading_cleanup() are designed to emit a warning + if a test leaves running threads in the background. This context manager + is designed to cleanup threads started by the _thread.start_new_thread() + which doesn't allow to wait for thread exit, whereas thread.Thread has a + join() method. + old_countmonotonicstart_timedeadlinedtwait_threads() failed to cleanup threads after " ""threads after " seconds (count: " seconds ", old count: 0.010join_threadJoin a thread. Raise an AssertionError if the thread is still alive + after timeout seconds. + is_alivefailed to join the thread in secondsUse this function at the end of test_main() whenever sub-processes + are started. This will help ensure that no extra children (zombies) + stick around to hog resources and create problems when looking + for refleaks. + waitpidWNOHANGreap_children() reaped child process threadsunlockCan't start %d threads, only %d threads startedendtimestarttime60Unable to join %d threads during a period of %d minutes'Unable to join %d threads during a period of ''%d minutes'dump_tracebackUnable to join %d threadsnew_valTemporary swap out an attribute with a new object. + + Usage: + with swap_attr(obj, "attr", 5): + ... + + This will set obj.attr to 5 for the duration of the with: block, + restoring the old value at the end of the block. If `attr` doesn't + exist on `obj`, it will be created and then deleted at the end of the + block. + + The old value (or None if it doesn't exist) will be assigned to the + target of the "as" clause, if there is one. + real_valTemporary swap out an item with a new object. + + Usage: + with swap_item(obj, "item", 5): + ... + + This will set obj["item"] to 5 for the duration of the with: block, + restoring the old value at the end of the block. If `item` doesn't + exist on `obj`, it will be created and then deleted at the end of the + block. + + The old value (or None if it doesn't exist) will be assigned to the + target of the "as" clause, if there is one. + strip_python_stderrStrip the stderr of a Python process from potential debug output + emitted by the interpreter. + + This will typically be run on the result of the communicate() method + of a subprocess.Popen object. + \[\d+ refs, \d+ blocks\]\r?\n?br"b"getcountstypes are immortal if COUNT_ALLOCS is definedrequires_type_collectingargs_from_interpreter_flagsReturn a list of command-line arguments reproducing the current + settings in sys.flags and sys.warnoptions._args_from_interpreter_flagsoptim_args_from_interpreter_flagsReturn a list of command-line arguments reproducing the current + optimization settings in sys.flags._optim_args_from_interpreter_flagsBufferingHandlermatchershouldFlushmatches + Look for a saved dict whose keys/values match the supplied arguments. + _partial_matches + Try to match a single dict with the supplied arguments. + + Keys whose values are strings and which are in self._partial_matches + will be checked for partial (i.e. substring) matches. You can extend + this scheme to (for example) do regular expression matching, etc. + dvmatch_value + Try to match a single stored value (dv) with a supplied value (v). + _can_symlinksymlink_pathsymlinkcanSkip decorator for tests that require functional symlinkokRequires functional symlink implementation_buggy_ucrt + Skip decorator for tests that use buggy strptime/strftime + + If the UCRT bugs are present time.localtime().tm_zone will be + an empty string, otherwise we assume the UCRT bugs are fixed + + See bpo-37552 [Windows] strptime/strftime return invalid + results with UCRT version 17763.615 + getdefaultlocalecp65001tm_zonebuggy MSVC UCRT strptime/strftimePythonSymlinkCreates a symlink for the current Python executable_linked_also_link_env_platform_specificlexistsGetModuleFileNamedllhandlesrc_dirdest_dirruntimevcruntime*.dllgetenvPYTHONHOMEis_python_buildPYTHONPATHexc_typeexc_valueexc_tbexfailed to clean up {}: {}_callpythonenvreturncodePIPEcommunicateunexpected return code: {0} (0x{0:08X})call_realcall_link_can_xattrcan_xattrsetxattrtmp_dirmkstemptmp_fptmp_nameuser.testtrusted.foo42kernel_version2.6.(\d{1,2})39Skip decorator for tests that require functional extended attributesno non-broken extended attribute supportskip_if_pgo_taskSkip decorator for tests not run in (non-extended) PGO taskNot run for (non-extended) PGO task_bind_nix_socket_errorDecorator for tests requiring a functional bind() for unix sockets.No UNIX Socketscan_bind_unix_socketRequires a functional unix bind(): %sdirectoryDetects if the file system for the specified directory is case-insensitive.NamedTemporaryFilebase_pathcase_pathsamefileref_apiother_apiReturns the set of items in ref_api not in other_api, except for a + defined list of items to be ignored in this check. + + By default this skips private attributes beginning with '_' but + includes all magic methods, i.e. those starting and ending in '__'. + missing_items__test_casename_of_moduleblacklistAssert that the __all__ variable of 'module' contains all public names. + + The module's public names (its API) are detected automatically based on + whether they match the public name convention and were defined in + 'module'. + + The 'name_of_module' argument can specify (as a string or tuple thereof) + what module(s) an API could be defined in in order to be detected as a + public API. One case for this is when 'module' imports part of its public + API from other modules, possibly a C backend (like 'csv' and its '_csv'). + + The 'extra' argument can be a set of names that wouldn't otherwise be + automatically detected as "public", like objects without a proper + '__module__' attribute. If provided, it will be added to the + automatically detected ones. + + The 'blacklist' argument can be a set of names that must not be treated + as part of the public API even though their names indicate otherwise. + + Usage: + import bar + import foo + import unittest + from test import support + + class MiscTestCase(unittest.TestCase): + def test__all__(self): + support.check__all__(self, foo) + + class OtherTestCase(unittest.TestCase): + def test__all__(self): + extra = {'BAR_CONST', 'FOO_CONST'} + blacklist = {'baz'} # Undocumented name. + # bar imports part of its API from _bar. + support.check__all__(self, bar, ('bar', '_bar'), + extra=extra, blacklist=blacklist) + + expectedassertCountEqualsuppress_msvcrt_assertsmsvcrtSetErrorModeSEM_FAILCRITICALERRORSSEM_NOALIGNMENTFAULTEXCEPTSEM_NOGPFAULTERRORBOXSEM_NOOPENFILEERRORBOXCrtSetReportModeCRT_WARNCRT_ERRORCRT_ASSERTCRTDBG_MODE_FILECrtSetReportFileCRTDBG_FILE_STDERRTry to prevent a crash report from popping up. + + On Windows, don't display the Windows Error Reporting dialog. On UNIX, + disable the creation of coredump file. + old_valueold_modesOn Windows, disable Windows Error Reporting dialogs using + SetErrorMode() and CrtSetReportMode(). + + On UNIX, try to save the previous core file size limit, then set + soft limit to 0. + report_typeold_modeold_filegetrlimitRLIMIT_COREsetrlimit/usr/bin/defaultscom.apple.CrashReporterDialogTypeprocdeveloperthis test triggers the Crash Reporter, that is intentional"this test triggers the Crash Reporter, ""that is intentional"Restore Windows ErrorMode or core file behavior to initial value.patchtest_instanceobject_to_patchnew_valueOverride 'object_to_patch'.'attr_name' with 'new_value'. + + Also, add a cleanup procedure to 'test_instance' to restore + 'object_to_patch' value for 'attr_name'. + The 'attr_name' should be a valid attribute for 'object_to_patch'. + + attr_is_localcleanupaddCleanuprun_in_subinterp + Run code in a subinterpreter. Raise unittest.SkipTest if the tracemalloc + module is enabled. + tracemallocis_tracingrun_in_subinterp() cannot be used if tracemalloc module is tracing memory allocations"run_in_subinterp() cannot be used ""if tracemalloc module is tracing ""memory allocations"check_free_after_iteratingdoneassertRaisescmd_namesCheck if the compiler components used to build the interpreter exist. + + Check for the existence of the compiler executables whose names are listed + in 'cmd_names' or all the compiler executables when 'cmd_names' is empty + and return the first missing executable or None when none is found + missing. + + distutilsccompilerspawnnew_compilercompilercustomize_compilerexecutablesthe '%s' executable is not configuredfind_executable_is_android_emulatorinterval1e-051e-5minimum_intervalcheck_outputgetpropro.kernel.qemudisable_faulthandlerall_threadsCount the number of open file descriptors. + linuxfreebsd/proc/self/fd256MAXFDsysconfSC_OPEN_MAXdupfd2EBADFSaveSignals + Save and restore signal handlers. + + This class is only able to save/restore signal handlers registered + by the Python signal module: see bpo-13285 for "external" signal + handlers. + signalvalid_signalssignameSIGKILLSIGSTOPsignumsavegetsignalrestorewith_pymallocWITH_PYMALLOCFakePathSimple implementing of the path protocol. + 'u''b'exec'u'exec'b'always'u'always'b''u''b'check'u'check'b'urlfetch'u'urlfetch'b' fetching %s ...'u' fetching %s ...'b'Accept-Encoding'u'Accept-Encoding'b'gzip'u'gzip'b'Content-Encoding'u'Content-Encoding'b'invalid resource %r'u'invalid resource %r'b'Convenience wrapper for the warnings list returned on + entry to the warnings.catch_warnings() context manager. + 'u'Convenience wrapper for the warnings list returned on + entry to the warnings.catch_warnings() context manager. + 'b'%r has no attribute %r'u'%r has no attribute %r'b'Catch the warnings, then check if all the expected + warnings have been raised and re-raise unexpected warnings. + If 'quiet' is True, only re-raise the unexpected warnings. + 'u'Catch the warnings, then check if all the expected + warnings have been raised and re-raise unexpected warnings. + If 'quiet' is True, only re-raise the unexpected warnings. + 'b'__warningregistry__'u'__warningregistry__'b'warnings'u'warnings'b'unhandled warning %s'u'unhandled warning %s'b'filter (%r, %s) did not catch any warning'u'filter (%r, %s) did not catch any warning'b'Context manager to silence warnings. + + Accept 2-tuples as positional arguments: + ("message regexp", WarningCategory) + + Optional argument: + - if 'quiet' is True, it does not fail if a filter catches nothing + (default True without argument, + default False if some filters are defined) + + Without argument, it defaults to: + check_warnings(("", Warning), quiet=True) + 'u'Context manager to silence warnings. + + Accept 2-tuples as positional arguments: + ("message regexp", WarningCategory) + + Optional argument: + - if 'quiet' is True, it does not fail if a filter catches nothing + (default True without argument, + default False if some filters are defined) + + Without argument, it defaults to: + check_warnings(("", Warning), quiet=True) + 'b'quiet'u'quiet'b'Context manager to check that no warnings are emitted. + + This context manager enables a given warning within its scope + and checks that no warnings are emitted even with that warning + enabled. + + If force_gc is True, a garbage collection is attempted before checking + for warnings. This may help to catch warnings emitted when objects + are deleted, such as ResourceWarning. + + Other keyword arguments are passed to warnings.filterwarnings(). + 'u'Context manager to check that no warnings are emitted. + + This context manager enables a given warning within its scope + and checks that no warnings are emitted even with that warning + enabled. + + If force_gc is True, a garbage collection is attempted before checking + for warnings. This may help to catch warnings emitted when objects + are deleted, such as ResourceWarning. + + Other keyword arguments are passed to warnings.filterwarnings(). + 'b'Context manager to check that no ResourceWarning is emitted. + + Usage: + + with check_no_resource_warning(self): + f = open(...) + ... + del f + + You must remove the object which may emit ResourceWarning before + the end of the context manager. + 'u'Context manager to check that no ResourceWarning is emitted. + + Usage: + + with check_no_resource_warning(self): + f = open(...) + ... + del f + + You must remove the object which may emit ResourceWarning before + the end of the context manager. + 'b'Context manager to force import to return a new module reference. + + This is useful for testing module-level behaviours, such as + the emission of a DeprecationWarning on import. + + Use like this: + + with CleanImport("foo"): + importlib.import_module("foo") # new reference + 'u'Context manager to force import to return a new module reference. + + This is useful for testing module-level behaviours, such as + the emission of a DeprecationWarning on import. + + Use like this: + + with CleanImport("foo"): + importlib.import_module("foo") # new reference + 'b'Class to help protect the environment variable properly. Can be used as + a context manager.'u'Class to help protect the environment variable properly. Can be used as + a context manager.'b'Context manager to temporarily add directories to sys.path. + + This makes a copy of sys.path, appends any directories given + as positional arguments, then reverts sys.path to the copied + settings when the context ends. + + Note that *all* sys.path modifications in the body of the + context manager, including replacement of the object, + will be reverted at the end of the block. + 'u'Context manager to temporarily add directories to sys.path. + + This makes a copy of sys.path, appends any directories given + as positional arguments, then reverts sys.path to the copied + settings when the context ends. + + Note that *all* sys.path modifications in the body of the + context manager, including replacement of the object, + will be reverted at the end of the block. + 'b'Raise ResourceDenied if an exception is raised while the context manager + is in effect that matches the specified exception and attributes.'u'Raise ResourceDenied if an exception is raised while the context manager + is in effect that matches the specified exception and attributes.'b'If type_ is a subclass of self.exc and value has attributes matching + self.attrs, raise ResourceDenied. Otherwise let the exception + propagate (if any).'u'If type_ is a subclass of self.exc and value has attributes matching + self.attrs, raise ResourceDenied. Otherwise let the exception + propagate (if any).'b'an optional resource is not available'u'an optional resource is not available'b' + Get the different socket error numbers ('errno') which can be received + when a connection is refused. + 'u' + Get the different socket error numbers ('errno') which can be received + when a connection is refused. + 'b'ENETUNREACH'u'ENETUNREACH'b'EADDRNOTAVAIL'u'EADDRNOTAVAIL'b'EHOSTUNREACH'u'EHOSTUNREACH'b'Return a context manager that raises ResourceDenied when various issues + with the Internet connection manifest themselves as exceptions.'u'Return a context manager that raises ResourceDenied when various issues + with the Internet connection manifest themselves as exceptions.'b'ECONNREFUSED'u'ECONNREFUSED'b'ECONNRESET'u'ECONNRESET'b'ETIMEDOUT'u'ETIMEDOUT'b'EAI_AGAIN'u'EAI_AGAIN'b'EAI_FAIL'u'EAI_FAIL'b'EAI_NONAME'u'EAI_NONAME'b'EAI_NODATA'u'EAI_NODATA'b'WSANO_DATA'u'WSANO_DATA'b'Resource %r is not available'u'Resource %r is not available'b'errno'b'ConnectionRefusedError'u'ConnectionRefusedError'b'EOFError'u'EOFError'b'Return a context manager used by captured_stdout/stdin/stderr + that temporarily replaces the sys stream *stream_name* with a StringIO.'u'Return a context manager used by captured_stdout/stdin/stderr + that temporarily replaces the sys stream *stream_name* with a StringIO.'b'Capture the output of sys.stdout: + + with captured_stdout() as stdout: + print("hello") + self.assertEqual(stdout.getvalue(), "hello\n") + 'u'Capture the output of sys.stdout: + + with captured_stdout() as stdout: + print("hello") + self.assertEqual(stdout.getvalue(), "hello\n") + 'b'stdout'u'stdout'b'Capture the output of sys.stderr: + + with captured_stderr() as stderr: + print("hello", file=sys.stderr) + self.assertEqual(stderr.getvalue(), "hello\n") + 'u'Capture the output of sys.stderr: + + with captured_stderr() as stderr: + print("hello", file=sys.stderr) + self.assertEqual(stderr.getvalue(), "hello\n") + 'b'stderr'u'stderr'b'Capture the input to sys.stdin: + + with captured_stdin() as stdin: + stdin.write('hello\n') + stdin.seek(0) + # call test code that consumes from sys.stdin + captured = input() + self.assertEqual(captured, "hello") + 'u'Capture the input to sys.stdin: + + with captured_stdin() as stdin: + stdin.write('hello\n') + stdin.seek(0) + # call test code that consumes from sys.stdin + captured = input() + self.assertEqual(captured, "hello") + 'b'stdin'u'stdin'b'Force as many objects as possible to be collected. + + In non-CPython implementations of Python, this is needed because timely + deallocation is not guaranteed by the garbage collector. (Even in CPython + this can be the case in case of reference cycles.) This means that __del__ + methods may be called later than expected and weakrefs may remain alive for + longer than expected. This function tries its best to force all garbage + objects to disappear. + 'u'Force as many objects as possible to be collected. + + In non-CPython implementations of Python, this is needed because timely + deallocation is not guaranteed by the garbage collector. (Even in CPython + this can be the case in case of reference cycles.) This means that __del__ + methods may be called later than expected and weakrefs may remain alive for + longer than expected. This function tries its best to force all garbage + objects to disappear. + 'b'Find if Python was built with optimizations.'u'Find if Python was built with optimizations.'b'PY_CFLAGS'u'PY_CFLAGS'b'-O'u'-O'b'-O0'u'-O0'b'-Og'u'-Og'b'nP'u'nP'b'0n'u'0n'b'getobjects'u'getobjects'b'2P'u'2P'b'0P'u'0P'b'wrong size for %s: got %d, expected %d'u'wrong size for %s: got %d, expected %d'b'tzset required'u'tzset required'b'TZ'u'TZ'b'k'u'k'b'm'u'm'b'g'u'g'b't'u't'b'(\d+(\.\d+)?) (K|M|G|T)b?$'u'(\d+(\.\d+)?) (K|M|G|T)b?$'b'Invalid memory limit %r'u'Invalid memory limit %r'b'Memory limit %r too low to be useful'u'Memory limit %r too low to be useful'b'An object which periodically watches the process' memory consumption + and prints it out. + 'u'An object which periodically watches the process' memory consumption + and prints it out. + 'b'/proc/{pid}/statm'u'/proc/{pid}/statm'b'r'u'r'b'/proc not available for stats: {}'u'/proc not available for stats: {}'b'memory_watchdog.py'u'memory_watchdog.py'b'Decorator for bigmem tests. + + 'size' is a requested size for the test (in arbitrary, test-interpreted + units.) 'memuse' is the number of bytes per unit for the test, or a good + estimate of it. For example, a test that needs two byte buffers, of 4 GiB + each, could be decorated with @bigmemtest(size=_4G, memuse=2). + + The 'size' argument is normally passed to the decorated test method as an + extra argument. If 'dry_run' is true, the value passed to the test method + may be less than the requested value. If 'dry_run' is false, it means the + test doesn't support dummy runs when -M is not specified. + 'u'Decorator for bigmem tests. + + 'size' is a requested size for the test (in arbitrary, test-interpreted + units.) 'memuse' is the number of bytes per unit for the test, or a good + estimate of it. For example, a test that needs two byte buffers, of 4 GiB + each, could be decorated with @bigmemtest(size=_4G, memuse=2). + + The 'size' argument is normally passed to the decorated test method as an + extra argument. If 'dry_run' is true, the value passed to the test method + may be less than the requested value. If 'dry_run' is false, it means the + test doesn't support dummy runs when -M is not specified. + 'b'not enough memory: %.1fG minimum needed'u'not enough memory: %.1fG minimum needed'b' ... expected peak memory use: {peak:.1f}G'u' ... expected peak memory use: {peak:.1f}G'b'Decorator for tests that fill the address space.'u'Decorator for tests that fill the address space.'b'not enough memory: try a 32-bit build instead'u'not enough memory: try a 32-bit build instead'b'resource {0!r} is not enabled'u'resource {0!r} is not enabled'b' + Decorator for tests only applicable on CPython. + 'u' + Decorator for tests only applicable on CPython. + 'b'implementation detail not available on {0}'u'implementation detail not available on {0}'b'implementation detail specific to {0}'u'implementation detail specific to {0}'b' or 'u' or 'b'cpython'u'cpython'b'This function returns True or False depending on the host platform. + Examples: + if check_impl_detail(): # only on CPython (default) + if check_impl_detail(jython=True): # only on Jython + if check_impl_detail(cpython=False): # everywhere except on CPython + 'u'This function returns True or False depending on the host platform. + Examples: + if check_impl_detail(): # only on CPython (default) + if check_impl_detail(jython=True): # only on Jython + if check_impl_detail(cpython=False): # everywhere except on CPython + 'b'Decorator to temporarily turn off tracing for the duration of a test.'u'Decorator to temporarily turn off tracing for the duration of a test.'b'gettrace'u'gettrace'b'Decorator for tests which involve reference counting. + + To start, the decorator does not run the test if is not run by CPython. + After that, any trace function is unset during the test to prevent + unexpected refcounts caused by the trace function. + + 'u'Decorator for tests which involve reference counting. + + To start, the decorator does not run the test if is not run by CPython. + After that, any trace function is unset during the test to prevent + unexpected refcounts caused by the trace function. + + 'b'Recursively filter test cases in a suite based on a predicate.'u'Recursively filter test cases in a suite based on a predicate.'b'Run tests from a unittest.TestSuite-derived class.'u'Run tests from a unittest.TestSuite-derived class.'b'multiple errors occurred'u'multiple errors occurred'b'; run in verbose mode for details'u'; run in verbose mode for details'b'[?*\[\]]'u'[?*\[\]]'b'Run tests from unittest.TestCase-derived classes.'u'Run tests from unittest.TestCase-derived classes.'b'str arguments must be keys in sys.modules'u'str arguments must be keys in sys.modules'b'Just used to check if docstrings are enabled'u'Just used to check if docstrings are enabled'b'WITH_DOC_STRINGS'u'WITH_DOC_STRINGS'b'test requires docstrings'u'test requires docstrings'b'Run doctest on the given module. Return (#failures, #tests). + + If optional argument verbosity is not specified (or is None), pass + support's belief about verbosity on to doctest. Else doctest's + usual behavior is used (it searches sys.argv for -v). + 'u'Run doctest on the given module. Return (#failures, #tests). + + If optional argument verbosity is not specified (or is None), pass + support's belief about verbosity on to doctest. Else doctest's + usual behavior is used (it searches sys.argv for -v). + 'b'%d of %d doctests failed'u'%d of %d doctests failed'b'doctest (%s) ... %d tests with zero failures'u'doctest (%s) ... %d tests with zero failures'b'Warning -- 'u'Warning -- 'b'threading_cleanup() failed to cleanup 'u'threading_cleanup() failed to cleanup 'b' threads (count: 'u' threads (count: 'b', dangling: 'u', dangling: 'b'Dangling thread: 'u'Dangling thread: 'b'Use this function when threads are being used. This will + ensure that the threads are cleaned up even when the test fails. + 'u'Use this function when threads are being used. This will + ensure that the threads are cleaned up even when the test fails. + 'b' + bpo-31234: Context manager to wait until all threads created in the with + statement exit. + + Use _thread.count() to check if threads exited. Indirectly, wait until + threads exit the internal t_bootstrap() C function of the _thread module. + + threading_setup() and threading_cleanup() are designed to emit a warning + if a test leaves running threads in the background. This context manager + is designed to cleanup threads started by the _thread.start_new_thread() + which doesn't allow to wait for thread exit, whereas thread.Thread has a + join() method. + 'u' + bpo-31234: Context manager to wait until all threads created in the with + statement exit. + + Use _thread.count() to check if threads exited. Indirectly, wait until + threads exit the internal t_bootstrap() C function of the _thread module. + + threading_setup() and threading_cleanup() are designed to emit a warning + if a test leaves running threads in the background. This context manager + is designed to cleanup threads started by the _thread.start_new_thread() + which doesn't allow to wait for thread exit, whereas thread.Thread has a + join() method. + 'b'wait_threads() failed to cleanup 'u'wait_threads() failed to cleanup 'b' threads after 'u' threads after 'b' seconds (count: 'u' seconds (count: 'b', old count: 'u', old count: 'b'Join a thread. Raise an AssertionError if the thread is still alive + after timeout seconds. + 'u'Join a thread. Raise an AssertionError if the thread is still alive + after timeout seconds. + 'b'failed to join the thread in 'u'failed to join the thread in 'b' seconds'u' seconds'b'Use this function at the end of test_main() whenever sub-processes + are started. This will help ensure that no extra children (zombies) + stick around to hog resources and create problems when looking + for refleaks. + 'u'Use this function at the end of test_main() whenever sub-processes + are started. This will help ensure that no extra children (zombies) + stick around to hog resources and create problems when looking + for refleaks. + 'b'waitpid'u'waitpid'b'WNOHANG'u'WNOHANG'b'reap_children() reaped child process 'u'reap_children() reaped child process 'b'Can't start %d threads, only %d threads started'u'Can't start %d threads, only %d threads started'b'Unable to join %d threads during a period of %d minutes'u'Unable to join %d threads during a period of %d minutes'b'Unable to join %d threads'u'Unable to join %d threads'b'Temporary swap out an attribute with a new object. + + Usage: + with swap_attr(obj, "attr", 5): + ... + + This will set obj.attr to 5 for the duration of the with: block, + restoring the old value at the end of the block. If `attr` doesn't + exist on `obj`, it will be created and then deleted at the end of the + block. + + The old value (or None if it doesn't exist) will be assigned to the + target of the "as" clause, if there is one. + 'u'Temporary swap out an attribute with a new object. + + Usage: + with swap_attr(obj, "attr", 5): + ... + + This will set obj.attr to 5 for the duration of the with: block, + restoring the old value at the end of the block. If `attr` doesn't + exist on `obj`, it will be created and then deleted at the end of the + block. + + The old value (or None if it doesn't exist) will be assigned to the + target of the "as" clause, if there is one. + 'b'Temporary swap out an item with a new object. + + Usage: + with swap_item(obj, "item", 5): + ... + + This will set obj["item"] to 5 for the duration of the with: block, + restoring the old value at the end of the block. If `item` doesn't + exist on `obj`, it will be created and then deleted at the end of the + block. + + The old value (or None if it doesn't exist) will be assigned to the + target of the "as" clause, if there is one. + 'u'Temporary swap out an item with a new object. + + Usage: + with swap_item(obj, "item", 5): + ... + + This will set obj["item"] to 5 for the duration of the with: block, + restoring the old value at the end of the block. If `item` doesn't + exist on `obj`, it will be created and then deleted at the end of the + block. + + The old value (or None if it doesn't exist) will be assigned to the + target of the "as" clause, if there is one. + 'b'Strip the stderr of a Python process from potential debug output + emitted by the interpreter. + + This will typically be run on the result of the communicate() method + of a subprocess.Popen object. + 'u'Strip the stderr of a Python process from potential debug output + emitted by the interpreter. + + This will typically be run on the result of the communicate() method + of a subprocess.Popen object. + 'b'\[\d+ refs, \d+ blocks\]\r?\n?'b'getcounts'u'getcounts'b'types are immortal if COUNT_ALLOCS is defined'u'types are immortal if COUNT_ALLOCS is defined'b'Return a list of command-line arguments reproducing the current + settings in sys.flags and sys.warnoptions.'u'Return a list of command-line arguments reproducing the current + settings in sys.flags and sys.warnoptions.'b'Return a list of command-line arguments reproducing the current + optimization settings in sys.flags.'u'Return a list of command-line arguments reproducing the current + optimization settings in sys.flags.'b' + Look for a saved dict whose keys/values match the supplied arguments. + 'u' + Look for a saved dict whose keys/values match the supplied arguments. + 'b'msg'u'msg'b' + Try to match a single dict with the supplied arguments. + + Keys whose values are strings and which are in self._partial_matches + will be checked for partial (i.e. substring) matches. You can extend + this scheme to (for example) do regular expression matching, etc. + 'u' + Try to match a single dict with the supplied arguments. + + Keys whose values are strings and which are in self._partial_matches + will be checked for partial (i.e. substring) matches. You can extend + this scheme to (for example) do regular expression matching, etc. + 'b' + Try to match a single stored value (dv) with a supplied value (v). + 'u' + Try to match a single stored value (dv) with a supplied value (v). + 'b'Skip decorator for tests that require functional symlink'u'Skip decorator for tests that require functional symlink'b'Requires functional symlink implementation'u'Requires functional symlink implementation'b' + Skip decorator for tests that use buggy strptime/strftime + + If the UCRT bugs are present time.localtime().tm_zone will be + an empty string, otherwise we assume the UCRT bugs are fixed + + See bpo-37552 [Windows] strptime/strftime return invalid + results with UCRT version 17763.615 + 'u' + Skip decorator for tests that use buggy strptime/strftime + + If the UCRT bugs are present time.localtime().tm_zone will be + an empty string, otherwise we assume the UCRT bugs are fixed + + See bpo-37552 [Windows] strptime/strftime return invalid + results with UCRT version 17763.615 + 'b'cp65001'u'cp65001'b'buggy MSVC UCRT strptime/strftime'u'buggy MSVC UCRT strptime/strftime'b'Creates a symlink for the current Python executable'u'Creates a symlink for the current Python executable'b'vcruntime*.dll'u'vcruntime*.dll'b'PYTHONHOME'u'PYTHONHOME'b'PYTHONPATH'u'PYTHONPATH'b'failed to clean up {}: {}'u'failed to clean up {}: {}'b'unexpected return code: {0} (0x{0:08X})'u'unexpected return code: {0} (0x{0:08X})'b'setxattr'u'setxattr'b'user.test'b'trusted.foo'b'42'b'2.6.(\d{1,2})'u'2.6.(\d{1,2})'b'Skip decorator for tests that require functional extended attributes'u'Skip decorator for tests that require functional extended attributes'b'no non-broken extended attribute support'u'no non-broken extended attribute support'b'Skip decorator for tests not run in (non-extended) PGO task'u'Skip decorator for tests not run in (non-extended) PGO task'b'Not run for (non-extended) PGO task'u'Not run for (non-extended) PGO task'b'Decorator for tests requiring a functional bind() for unix sockets.'u'Decorator for tests requiring a functional bind() for unix sockets.'b'AF_UNIX'u'AF_UNIX'b'No UNIX Sockets'u'No UNIX Sockets'b'can_bind_unix_socket'u'can_bind_unix_socket'b'Requires a functional unix bind(): %s'u'Requires a functional unix bind(): %s'b'Detects if the file system for the specified directory is case-insensitive.'u'Detects if the file system for the specified directory is case-insensitive.'b'Returns the set of items in ref_api not in other_api, except for a + defined list of items to be ignored in this check. + + By default this skips private attributes beginning with '_' but + includes all magic methods, i.e. those starting and ending in '__'. + 'u'Returns the set of items in ref_api not in other_api, except for a + defined list of items to be ignored in this check. + + By default this skips private attributes beginning with '_' but + includes all magic methods, i.e. those starting and ending in '__'. + 'b'__'u'__'b'Assert that the __all__ variable of 'module' contains all public names. + + The module's public names (its API) are detected automatically based on + whether they match the public name convention and were defined in + 'module'. + + The 'name_of_module' argument can specify (as a string or tuple thereof) + what module(s) an API could be defined in in order to be detected as a + public API. One case for this is when 'module' imports part of its public + API from other modules, possibly a C backend (like 'csv' and its '_csv'). + + The 'extra' argument can be a set of names that wouldn't otherwise be + automatically detected as "public", like objects without a proper + '__module__' attribute. If provided, it will be added to the + automatically detected ones. + + The 'blacklist' argument can be a set of names that must not be treated + as part of the public API even though their names indicate otherwise. + + Usage: + import bar + import foo + import unittest + from test import support + + class MiscTestCase(unittest.TestCase): + def test__all__(self): + support.check__all__(self, foo) + + class OtherTestCase(unittest.TestCase): + def test__all__(self): + extra = {'BAR_CONST', 'FOO_CONST'} + blacklist = {'baz'} # Undocumented name. + # bar imports part of its API from _bar. + support.check__all__(self, bar, ('bar', '_bar'), + extra=extra, blacklist=blacklist) + + 'u'Assert that the __all__ variable of 'module' contains all public names. + + The module's public names (its API) are detected automatically based on + whether they match the public name convention and were defined in + 'module'. + + The 'name_of_module' argument can specify (as a string or tuple thereof) + what module(s) an API could be defined in in order to be detected as a + public API. One case for this is when 'module' imports part of its public + API from other modules, possibly a C backend (like 'csv' and its '_csv'). + + The 'extra' argument can be a set of names that wouldn't otherwise be + automatically detected as "public", like objects without a proper + '__module__' attribute. If provided, it will be added to the + automatically detected ones. + + The 'blacklist' argument can be a set of names that must not be treated + as part of the public API even though their names indicate otherwise. + + Usage: + import bar + import foo + import unittest + from test import support + + class MiscTestCase(unittest.TestCase): + def test__all__(self): + support.check__all__(self, foo) + + class OtherTestCase(unittest.TestCase): + def test__all__(self): + extra = {'BAR_CONST', 'FOO_CONST'} + blacklist = {'baz'} # Undocumented name. + # bar imports part of its API from _bar. + support.check__all__(self, bar, ('bar', '_bar'), + extra=extra, blacklist=blacklist) + + 'b'__module__'u'__module__'b'CrtSetReportMode'u'CrtSetReportMode'b'Try to prevent a crash report from popping up. + + On Windows, don't display the Windows Error Reporting dialog. On UNIX, + disable the creation of coredump file. + 'u'Try to prevent a crash report from popping up. + + On Windows, don't display the Windows Error Reporting dialog. On UNIX, + disable the creation of coredump file. + 'b'On Windows, disable Windows Error Reporting dialogs using + SetErrorMode() and CrtSetReportMode(). + + On UNIX, try to save the previous core file size limit, then set + soft limit to 0. + 'u'On Windows, disable Windows Error Reporting dialogs using + SetErrorMode() and CrtSetReportMode(). + + On UNIX, try to save the previous core file size limit, then set + soft limit to 0. + 'b'/usr/bin/defaults'u'/usr/bin/defaults'b'com.apple.CrashReporter'u'com.apple.CrashReporter'b'DialogType'u'DialogType'b'developer'b'this test triggers the Crash Reporter, that is intentional'u'this test triggers the Crash Reporter, that is intentional'b'Restore Windows ErrorMode or core file behavior to initial value.'u'Restore Windows ErrorMode or core file behavior to initial value.'b'Override 'object_to_patch'.'attr_name' with 'new_value'. + + Also, add a cleanup procedure to 'test_instance' to restore + 'object_to_patch' value for 'attr_name'. + The 'attr_name' should be a valid attribute for 'object_to_patch'. + + 'u'Override 'object_to_patch'.'attr_name' with 'new_value'. + + Also, add a cleanup procedure to 'test_instance' to restore + 'object_to_patch' value for 'attr_name'. + The 'attr_name' should be a valid attribute for 'object_to_patch'. + + 'b' + Run code in a subinterpreter. Raise unittest.SkipTest if the tracemalloc + module is enabled. + 'u' + Run code in a subinterpreter. Raise unittest.SkipTest if the tracemalloc + module is enabled. + 'b'run_in_subinterp() cannot be used if tracemalloc module is tracing memory allocations'u'run_in_subinterp() cannot be used if tracemalloc module is tracing memory allocations'b'Check if the compiler components used to build the interpreter exist. + + Check for the existence of the compiler executables whose names are listed + in 'cmd_names' or all the compiler executables when 'cmd_names' is empty + and return the first missing executable or None when none is found + missing. + + 'u'Check if the compiler components used to build the interpreter exist. + + Check for the existence of the compiler executables whose names are listed + in 'cmd_names' or all the compiler executables when 'cmd_names' is empty + and return the first missing executable or None when none is found + missing. + + 'b'the '%s' executable is not configured'u'the '%s' executable is not configured'b'getprop'u'getprop'b'ro.kernel.qemu'u'ro.kernel.qemu'b'Count the number of open file descriptors. + 'u'Count the number of open file descriptors. + 'b'linux'u'linux'b'freebsd'u'freebsd'b'/proc/self/fd'u'/proc/self/fd'b'sysconf'u'sysconf'b'SC_OPEN_MAX'u'SC_OPEN_MAX'b' + Save and restore signal handlers. + + This class is only able to save/restore signal handlers registered + by the Python signal module: see bpo-13285 for "external" signal + handlers. + 'u' + Save and restore signal handlers. + + This class is only able to save/restore signal handlers registered + by the Python signal module: see bpo-13285 for "external" signal + handlers. + 'b'SIGKILL'u'SIGKILL'b'SIGSTOP'u'SIGSTOP'b'Simple implementing of the path protocol. + 'u'Simple implementing of the path protocol. + 'b' character array + create_string_buffer(anInteger) -> character array + create_string_buffer(aBytes, anInteger) -> character array + ctypes.create_string_bufferc_charbuftypebufc_buffer_c_functype_cacheCFUNCTYPErestypeargtypesCFUNCTYPE(restype, *argtypes, + use_errno=False, use_last_error=False) -> function prototype. + + restype: the result type + argtypes: a sequence specifying the argument types + + The function prototype can be called in different ways to create a + callable object: + + prototype(integer address) -> foreign function + prototype(callable) -> create and return a C callable function from callable + prototype(integer index, method name[, paramflags]) -> foreign function calling a COM method + prototype((ordinal number, dll object)[, paramflags]) -> foreign function exported by ordinal + prototype((function name, dll object)[, paramflags]) -> foreign function exported by name + use_errnouse_last_errorunexpected keyword argument(s) %sCFunctionType_argtypes__restype__flags__dlopenFUNCFLAG_STDCALL_FUNCFLAG_STDCALL_win_functype_cacheWINFUNCTYPEWinFunctionTypedlopenaddressofalignmentresizeget_errnoset_errno_SimpleCData_check_sizetyptypecode_type_actualrequiredsizeof(%s) wrong: %d instead of %dpy_objectO%s()Pc_shortc_ushortHc_longlc_ulongc_uintc_floatc_doublec_longdoubleqc_longlongc_ulonglongQc_ubyteB__ctype_le____ctype_be__c_bytec_char_pz%s(%s)c_void_pfrom_bufferc_voidpc_bool?POINTER_pointer_type_cachec_wchar_pZc_wchar_reset_cachefrom_paramcreate_unicode_buffer(aString) -> character array + create_unicode_buffer(anInteger) -> character array + create_unicode_buffer(aString, anInteger) -> character array + 0xFFFFctypes.create_unicode_bufferSetPointerTypeThis type already exists in the cacheWhat's this???set_typeARRAYCDLLAn instance of this class represents a loaded dll/shared + library, exporting functions using the standard C calling + convention (named 'cdecl' on Windows). + + The exported functions can be accessed as attributes, or by + indexing with the function name. Examples: + + .qsort -> callable object + ['qsort'] -> callable object + + Calling the functions releases the Python GIL during the call and + reacquires it afterwards. + _func_flags__func_restype__handle_FuncPtrwinmodeaixWhen the name contains ".a(" and ends with ")", + e.g., "libFOO.a(libFOO.so)" - this is taken to be an + archive(member) syntax for dlopen(), and the mode is adjusted. + Otherwise, name is presented to dlopen() as a file argument. + .a(RTLD_MEMBERRTLD_NOW_LOAD_LIBRARY_SEARCH_DEFAULT_DIRS_getfullpathname_LOAD_LIBRARY_SEARCH_DLL_LOAD_DIR<%s '%s', handle %x at %#x>name_or_ordinalPyDLLThis class represents the Python library itself. It allows + accessing Python API functions. The GIL is not released, and + Python exceptions are handled correctly. + WinDLLThis class represents a dll exporting functions using the + Windows stdcall calling convention. + _check_HRESULTHRESULT_check_retval_OleDLLThis class represents a dll exporting functions using the + Windows stdcall calling convention, and returning HRESULT. + HRESULT error values are automatically raised as OSError + exceptions. + LibraryLoaderdlltype_dlltypepydllpython dllpythonapicygwinlibpython%d.%d.dlloledllGetLastErrorget_last_errorset_last_errordescrc_size_tc_ssize_t_memmove_addr_memset_addr_string_at_addr_cast_addrmemmovememsetPYFUNCTYPE_cast_string_atstring_atptrstring_at(addr[, size]) -> string + + Return the string at addr._wstring_at_addr_wstring_atwstring_atwstring_at(addr[, size]) -> string + + Return the string at addr.DllGetClassObjectrclsidriidppvcomtypes.server.inprocserverccom2147221231DllCanUnloadNowctypes._endianBigEndianStructureLittleEndianStructurec_int8c_uint8kindc_int16c_int32c_int64c_uint16c_uint32c_uint64# On OS X 10.3, we use RTLD_GLOBAL as default mode# because RTLD_LOCAL does not work at least on some# libraries. OS X 10.3 is Darwin 7, so we check for# that.# WINOLEAPI -> HRESULT# WINOLEAPI_(type)# STDMETHODCALLTYPE# STDMETHOD(name)# STDMETHOD_(type, name)# STDAPICALLTYPE## "deprecated, use create_string_buffer instead"## import warnings## warnings.warn("c_buffer is deprecated, use create_string_buffer instead",## DeprecationWarning, stacklevel=2)# docstring set later (very similar to CFUNCTYPE.__doc__)# Check if sizeof(ctypes_type) against struct.calcsize. This# should protect somewhat against a misconfigured libffi.# Most _type_ codes are the same as used in struct# if int and long have the same size, make c_int an alias for c_long# if long and long long have the same size, make c_longlong an alias for c_long## def from_param(cls, val):## return ('d', float(val), val)## from_param = classmethod(from_param)# backward compatibility:##c_uchar = c_ubyte# backwards compatibility (to a bug)# _SimpleCData.c_wchar_p_from_param# _SimpleCData.c_char_p_from_param# UTF-16 requires a surrogate pair (2 wchar_t) for non-BMP# characters (outside [U+0000; U+FFFF] range). +1 for trailing# NUL character.# 32-bit wchar_t (1 wchar_t per Unicode character). +1 for# trailing NUL character.# XXX Deprecated################################################################# default values for repr# XXX Hm, what about HRESULT as normal parameter?# Mustn't it derive from c_long then?# _check_retval_ is called with the function's result when it# is used as restype. It checks for the FAILED bit, and# raises an OSError if it is set.# The _check_retval_ method is implemented in C, so that the# method definition itself is not included in the traceback# when it raises an error - that is what we want (and Python# doesn't have a way to raise an exception in the caller's# frame).# functions## void *memmove(void *, const void *, size_t);## void *memset(void *, int, size_t)# COM stuff# CLASS_E_CLASSNOTAVAILABLE# S_OK# Fill in specifically-sized typesb'create and manipulate C data types in Python'u'create and manipulate C data types in Python'b'1.1.0'u'1.1.0'b'Version number mismatch'u'Version number mismatch'b'posix'b'create_string_buffer(aBytes) -> character array + create_string_buffer(anInteger) -> character array + create_string_buffer(aBytes, anInteger) -> character array + 'u'create_string_buffer(aBytes) -> character array + create_string_buffer(anInteger) -> character array + create_string_buffer(aBytes, anInteger) -> character array + 'b'ctypes.create_string_buffer'u'ctypes.create_string_buffer'b'CFUNCTYPE(restype, *argtypes, + use_errno=False, use_last_error=False) -> function prototype. + + restype: the result type + argtypes: a sequence specifying the argument types + + The function prototype can be called in different ways to create a + callable object: + + prototype(integer address) -> foreign function + prototype(callable) -> create and return a C callable function from callable + prototype(integer index, method name[, paramflags]) -> foreign function calling a COM method + prototype((ordinal number, dll object)[, paramflags]) -> foreign function exported by ordinal + prototype((function name, dll object)[, paramflags]) -> foreign function exported by name + 'u'CFUNCTYPE(restype, *argtypes, + use_errno=False, use_last_error=False) -> function prototype. + + restype: the result type + argtypes: a sequence specifying the argument types + + The function prototype can be called in different ways to create a + callable object: + + prototype(integer address) -> foreign function + prototype(callable) -> create and return a C callable function from callable + prototype(integer index, method name[, paramflags]) -> foreign function calling a COM method + prototype((ordinal number, dll object)[, paramflags]) -> foreign function exported by ordinal + prototype((function name, dll object)[, paramflags]) -> foreign function exported by name + 'b'use_errno'u'use_errno'b'use_last_error'u'use_last_error'b'unexpected keyword argument(s) %s'u'unexpected keyword argument(s) %s'b'CFUNCTYPE'u'CFUNCTYPE'b'WINFUNCTYPE'u'WINFUNCTYPE'b'sizeof(%s) wrong: %d instead of %d'u'sizeof(%s) wrong: %d instead of %d'b'O'u'O'b'%s()'u'%s()'b'P'u'P'b'h'u'h'b'H'u'H'b'l'u'l'b'L'u'L'b'i'u'i'b'I'u'I'b'f'u'f'b'd'u'd'b'q'u'q'b'Q'u'Q'b'B'u'B'b'b'u'b'b'z'u'z'b'%s(%s)'u'%s(%s)'b'?'u'?'b'Z'u'Z'b'u'u'u'b'create_unicode_buffer(aString) -> character array + create_unicode_buffer(anInteger) -> character array + create_unicode_buffer(aString, anInteger) -> character array + 'u'create_unicode_buffer(aString) -> character array + create_unicode_buffer(anInteger) -> character array + create_unicode_buffer(aString, anInteger) -> character array + 'b'ctypes.create_unicode_buffer'u'ctypes.create_unicode_buffer'b'This type already exists in the cache'u'This type already exists in the cache'b'What's this???'u'What's this???'b'An instance of this class represents a loaded dll/shared + library, exporting functions using the standard C calling + convention (named 'cdecl' on Windows). + + The exported functions can be accessed as attributes, or by + indexing with the function name. Examples: + + .qsort -> callable object + ['qsort'] -> callable object + + Calling the functions releases the Python GIL during the call and + reacquires it afterwards. + 'u'An instance of this class represents a loaded dll/shared + library, exporting functions using the standard C calling + convention (named 'cdecl' on Windows). + + The exported functions can be accessed as attributes, or by + indexing with the function name. Examples: + + .qsort -> callable object + ['qsort'] -> callable object + + Calling the functions releases the Python GIL during the call and + reacquires it afterwards. + 'b''u''b'aix'u'aix'b'When the name contains ".a(" and ends with ")", + e.g., "libFOO.a(libFOO.so)" - this is taken to be an + archive(member) syntax for dlopen(), and the mode is adjusted. + Otherwise, name is presented to dlopen() as a file argument. + 'u'When the name contains ".a(" and ends with ")", + e.g., "libFOO.a(libFOO.so)" - this is taken to be an + archive(member) syntax for dlopen(), and the mode is adjusted. + Otherwise, name is presented to dlopen() as a file argument. + 'b'.a('u'.a('b'<%s '%s', handle %x at %#x>'u'<%s '%s', handle %x at %#x>'b'This class represents the Python library itself. It allows + accessing Python API functions. The GIL is not released, and + Python exceptions are handled correctly. + 'u'This class represents the Python library itself. It allows + accessing Python API functions. The GIL is not released, and + Python exceptions are handled correctly. + 'b'This class represents a dll exporting functions using the + Windows stdcall calling convention. + 'u'This class represents a dll exporting functions using the + Windows stdcall calling convention. + 'b'This class represents a dll exporting functions using the + Windows stdcall calling convention, and returning HRESULT. + HRESULT error values are automatically raised as OSError + exceptions. + 'u'This class represents a dll exporting functions using the + Windows stdcall calling convention, and returning HRESULT. + HRESULT error values are automatically raised as OSError + exceptions. + 'b'python dll'u'python dll'b'cygwin'u'cygwin'b'libpython%d.%d.dll'u'libpython%d.%d.dll'b'string_at(addr[, size]) -> string + + Return the string at addr.'u'string_at(addr[, size]) -> string + + Return the string at addr.'b'wstring_at(addr[, size]) -> string + + Return the string at addr.'u'wstring_at(addr[, size]) -> string + + Return the string at addr.'b'comtypes.server.inprocserver'u'comtypes.server.inprocserver'u'ctypes.__init__'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/ctypes/__pycache__u'Module contains faster C implementation of abc.ABCMeta'_abc_init_abc_instancecheck_abc_register_abc_subclasscheck_get_dump_reset_caches_reset_registryget_cache_token_abc +Lib/ctypes.util.find_library() support for AIX +Similar approach as done for Darwin support by using separate files +but unlike Darwin - no extension such as ctypes.macholib.* + +dlopen() is an interface to AIX initAndLoad() - primary documentation at: +https://www.ibm.com/support/knowledgecenter/en/ssw_aix_61/com.ibm.aix.basetrf1/dlopen.htm +https://www.ibm.com/support/knowledgecenter/en/ssw_aix_61/com.ibm.aix.basetrf1/load.htm + +AIX supports two styles for dlopen(): svr4 (System V Release 4) which is common on posix +platforms, but also a BSD style - aka SVR3. + +From AIX 5.3 Difference Addendum (December 2004) +2.9 SVR4 linking affinity +Nowadays, there are two major object file formats used by the operating systems: +XCOFF: The COFF enhanced by IBM and others. The original COFF (Common +Object File Format) was the base of SVR3 and BSD 4.2 systems. +ELF: Executable and Linking Format that was developed by AT&T and is a +base for SVR4 UNIX. + +While the shared library content is identical on AIX - one is located as a filepath name +(svr4 style) and the other is located as a member of an archive (and the archive +is located as a filepath name). + +The key difference arises when supporting multiple abi formats (i.e., 32 and 64 bit). +For svr4 either only one ABI is supported, or there are two directories, or there +are different file names. The most common solution for multiple ABI is multiple +directories. + +For the XCOFF (aka AIX) style - one directory (one archive file) is sufficient +as multiple shared libraries can be in the archive - even sharing the same name. +In documentation the archive is also referred to as the "base" and the shared +library object is referred to as the "member". + +For dlopen() on AIX (read initAndLoad()) the calls are similar. +Default activity occurs when no path information is provided. When path +information is provided dlopen() does not search any other directories. + +For SVR4 - the shared library name is the name of the file expected: libFOO.so +For AIX - the shared library is expressed as base(member). The search is for the +base (e.g., libFOO.a) and once the base is found the shared library - identified by +member (e.g., libFOO.so, or shr.o) is located and loaded. + +The mode bit RTLD_MEMBER tells initAndLoad() that it needs to use the AIX (SVR3) +naming style. +Michael Felt AIX_ABI_last_versionlibnames_num_versionlibnamepartsnumsget_ld_headerld_header./../INDEXget_ld_header_info[0-9]get_ld_headers + Parse the header of the loader section of executable and archives + This function calls /usr/bin/dump -H as a subprocess + and returns a list of (ld_header, ld_header_info) tuples. + ldr_headers/usr/bin/dump-X-Huniversal_newlinesget_sharedld_headers + extract the shareable objects from ld_headers + character "[" is used to strip off the path information. + Note: the "[" and "]" characters that are part of dump -H output + are not removed here. + sharedget_one_matchexprlines + Must be only one match, otherwise result is None. + When there is a match, strip leading "[" and trailing "]" + \[(rf')\]get_legacymembers + This routine provides historical aka legacy naming schemes started + in AIX4 shared library support for library members names. + e.g., in /usr/lib/libc.a the member name shr.o for 32-bit binary and + shr_64.o for 64-bit binary. + shr4?_?64\.omembershr.oshr4.oget_version + Sort list of members and return highest numbered version - if it exists. + This function is called when an unversioned libFOO.a(libFOO.so) has + not been found. + + Versioning for the member name is expected to follow + GNU LIBTOOL conventions: the highest version (x, then X.y, then X.Y.z) + * find [libFoo.so.X] + * find [libFoo.so.X.Y] + * find [libFoo.so.X.Y.Z] + + Before the GNU convention became the standard scheme regardless of + binary size AIX packagers used GNU convention "as-is" for 32-bit + archive members but used an "distinguishing" name for 64-bit members. + This scheme inserted either 64 or _64 between libFOO and .so + - generally libFOO_64.so, but occasionally libFOO64.so + lib\.so\.[0-9]+[0-9.]*_?64\.so\.[0-9]+[0-9.]*exprsversionsget_member + Return an archive member matching the request in name. + Name is the library name without any prefix like lib, suffix like .so, + or version number. + Given a list of members find and return the most appropriate result + Priority is given to generic libXXX.so, then a versioned libXXX.so.a.b.c + and finally, legacy AIX naming scheme. + \.so64\.soget_libpaths + On AIX, the buildtime searchpath is stored in the executable. + as "loader header information". + The command /usr/bin/dump -H extracts this info. + Prefix searched libraries with LD_LIBRARY_PATH (preferred), + or LIBPATH if defined. These paths are appended to the paths + to libraries the python executable is linked with. + This mimics AIX dlopen() behavior. + LD_LIBRARY_PATHlibpathsLIBPATHobjectsfind_shared + paths is a list of directories to search for an archive. + name is the abbreviated name given to find_library(). + Process: search "paths" for archive, and if an archive is found + return the result of get_member(). + If an archive is not found then return None + /lib.aarchiveAIX implementation of ctypes.util.find_library() + Find an archive member that will dlopen(). If not available, + also search for a file (or link) with a .so suffix. + + AIX supports two types of schemes that can be used with dlopen(). + The so-called SystemV Release4 (svr4) format is commonly suffixed + with .so while the (default) AIX scheme has the library (archive) + ending with the suffix .a + As an archive has multiple members (e.g., 32-bit and 64-bit) in one file + the argument passed to dlopen must include both the library and + the member names in a single string. + + find_library() looks first for an archive (.a) with a suitable member. + If no archive+member pair is found, look for a .so file. + .sosonameshlib# Executable bit size - 32 or 64# Used to filter the search in an archive by size, e.g., -X64# "libxyz.so.MAJOR.MINOR" => [MAJOR, MINOR]# "nested-function, but placed at module level# as an ld_header was found, return known paths, archives and members# these lines start with a digit# blank line (separator), consume line and end for loop# get_ld_headers parsing:# 1. Find a line that starts with /, ./, or ../ - set as ld_header# 2. If "INDEX" in occurs in a following line - return ld_header# 3. get info (lines starting with [0-9])# be sure to read to the end-of-file - getting all entries# potential member lines contain "["# otherwise, no processing needed# Strip off trailing colon (:)# member names in the ld_headers output are between square brackets# additional processing to deal with AIX legacy names for 64-bit members# AIX 64-bit member is one of shr64.o, shr_64.o, or shr4_64.o# 32-bit legacy names - both shr.o and shr4.o exist.# shr.o is the preffered name so we look for shr.o first# i.e., shr4.o is returned only when shr.o does not exist# the expression ending for versions must start as# '.so.[0-9]', i.e., *.so.[at least one digit]# while multiple, more specific expressions could be specified# to search for .so.X, .so.X.Y and .so.X.Y.Z# after the first required 'dot' digit# any combination of additional 'dot' digits pairs are accepted# anything more than libFOO.so.digits.digits.digits# should be seen as a member name outside normal expectations# look first for a generic match - prepend lib and append .so# since an exact match with .so as suffix was not found# look for a versioned name# If a versioned name is not found, look for AIX legacy member name# the second (optional) argument is PATH if it includes a /# /lib is a symbolic link to /usr/lib, skip it# "lib" is prefixed to emulate compiler name resolution,# e.g., -lc to libc# To get here, a member in an archive has not been found# In other words, either:# a) a .a file was not found# b) a .a file did not have a suitable member# So, look for a .so file# Check libpaths for .so file# Note, the installation must prepare a link from a .so# to a versioned file# This is common practice by GNU libtool on other platforms# if we are here, we have not found anything plausibleb' +Lib/ctypes.util.find_library() support for AIX +Similar approach as done for Darwin support by using separate files +but unlike Darwin - no extension such as ctypes.macholib.* + +dlopen() is an interface to AIX initAndLoad() - primary documentation at: +https://www.ibm.com/support/knowledgecenter/en/ssw_aix_61/com.ibm.aix.basetrf1/dlopen.htm +https://www.ibm.com/support/knowledgecenter/en/ssw_aix_61/com.ibm.aix.basetrf1/load.htm + +AIX supports two styles for dlopen(): svr4 (System V Release 4) which is common on posix +platforms, but also a BSD style - aka SVR3. + +From AIX 5.3 Difference Addendum (December 2004) +2.9 SVR4 linking affinity +Nowadays, there are two major object file formats used by the operating systems: +XCOFF: The COFF enhanced by IBM and others. The original COFF (Common +Object File Format) was the base of SVR3 and BSD 4.2 systems. +ELF: Executable and Linking Format that was developed by AT&T and is a +base for SVR4 UNIX. + +While the shared library content is identical on AIX - one is located as a filepath name +(svr4 style) and the other is located as a member of an archive (and the archive +is located as a filepath name). + +The key difference arises when supporting multiple abi formats (i.e., 32 and 64 bit). +For svr4 either only one ABI is supported, or there are two directories, or there +are different file names. The most common solution for multiple ABI is multiple +directories. + +For the XCOFF (aka AIX) style - one directory (one archive file) is sufficient +as multiple shared libraries can be in the archive - even sharing the same name. +In documentation the archive is also referred to as the "base" and the shared +library object is referred to as the "member". + +For dlopen() on AIX (read initAndLoad()) the calls are similar. +Default activity occurs when no path information is provided. When path +information is provided dlopen() does not search any other directories. + +For SVR4 - the shared library name is the name of the file expected: libFOO.so +For AIX - the shared library is expressed as base(member). The search is for the +base (e.g., libFOO.a) and once the base is found the shared library - identified by +member (e.g., libFOO.so, or shr.o) is located and loaded. + +The mode bit RTLD_MEMBER tells initAndLoad() that it needs to use the AIX (SVR3) +naming style. +'u' +Lib/ctypes.util.find_library() support for AIX +Similar approach as done for Darwin support by using separate files +but unlike Darwin - no extension such as ctypes.macholib.* + +dlopen() is an interface to AIX initAndLoad() - primary documentation at: +https://www.ibm.com/support/knowledgecenter/en/ssw_aix_61/com.ibm.aix.basetrf1/dlopen.htm +https://www.ibm.com/support/knowledgecenter/en/ssw_aix_61/com.ibm.aix.basetrf1/load.htm + +AIX supports two styles for dlopen(): svr4 (System V Release 4) which is common on posix +platforms, but also a BSD style - aka SVR3. + +From AIX 5.3 Difference Addendum (December 2004) +2.9 SVR4 linking affinity +Nowadays, there are two major object file formats used by the operating systems: +XCOFF: The COFF enhanced by IBM and others. The original COFF (Common +Object File Format) was the base of SVR3 and BSD 4.2 systems. +ELF: Executable and Linking Format that was developed by AT&T and is a +base for SVR4 UNIX. + +While the shared library content is identical on AIX - one is located as a filepath name +(svr4 style) and the other is located as a member of an archive (and the archive +is located as a filepath name). + +The key difference arises when supporting multiple abi formats (i.e., 32 and 64 bit). +For svr4 either only one ABI is supported, or there are two directories, or there +are different file names. The most common solution for multiple ABI is multiple +directories. + +For the XCOFF (aka AIX) style - one directory (one archive file) is sufficient +as multiple shared libraries can be in the archive - even sharing the same name. +In documentation the archive is also referred to as the "base" and the shared +library object is referred to as the "member". + +For dlopen() on AIX (read initAndLoad()) the calls are similar. +Default activity occurs when no path information is provided. When path +information is provided dlopen() does not search any other directories. + +For SVR4 - the shared library name is the name of the file expected: libFOO.so +For AIX - the shared library is expressed as base(member). The search is for the +base (e.g., libFOO.a) and once the base is found the shared library - identified by +member (e.g., libFOO.so, or shr.o) is located and loaded. + +The mode bit RTLD_MEMBER tells initAndLoad() that it needs to use the AIX (SVR3) +naming style. +'b'Michael Felt 'u'Michael Felt 'b'./'u'./'b'../'u'../'b'INDEX'u'INDEX'b'[0-9]'u'[0-9]'b' + Parse the header of the loader section of executable and archives + This function calls /usr/bin/dump -H as a subprocess + and returns a list of (ld_header, ld_header_info) tuples. + 'u' + Parse the header of the loader section of executable and archives + This function calls /usr/bin/dump -H as a subprocess + and returns a list of (ld_header, ld_header_info) tuples. + 'b'/usr/bin/dump'u'/usr/bin/dump'b'-X'u'-X'b'-H'u'-H'b' + extract the shareable objects from ld_headers + character "[" is used to strip off the path information. + Note: the "[" and "]" characters that are part of dump -H output + are not removed here. + 'u' + extract the shareable objects from ld_headers + character "[" is used to strip off the path information. + Note: the "[" and "]" characters that are part of dump -H output + are not removed here. + 'b' + Must be only one match, otherwise result is None. + When there is a match, strip leading "[" and trailing "]" + 'u' + Must be only one match, otherwise result is None. + When there is a match, strip leading "[" and trailing "]" + 'b'\[('u'\[('b')\]'u')\]'b' + This routine provides historical aka legacy naming schemes started + in AIX4 shared library support for library members names. + e.g., in /usr/lib/libc.a the member name shr.o for 32-bit binary and + shr_64.o for 64-bit binary. + 'u' + This routine provides historical aka legacy naming schemes started + in AIX4 shared library support for library members names. + e.g., in /usr/lib/libc.a the member name shr.o for 32-bit binary and + shr_64.o for 64-bit binary. + 'b'shr4?_?64\.o'u'shr4?_?64\.o'b'shr.o'u'shr.o'b'shr4.o'u'shr4.o'b' + Sort list of members and return highest numbered version - if it exists. + This function is called when an unversioned libFOO.a(libFOO.so) has + not been found. + + Versioning for the member name is expected to follow + GNU LIBTOOL conventions: the highest version (x, then X.y, then X.Y.z) + * find [libFoo.so.X] + * find [libFoo.so.X.Y] + * find [libFoo.so.X.Y.Z] + + Before the GNU convention became the standard scheme regardless of + binary size AIX packagers used GNU convention "as-is" for 32-bit + archive members but used an "distinguishing" name for 64-bit members. + This scheme inserted either 64 or _64 between libFOO and .so + - generally libFOO_64.so, but occasionally libFOO64.so + 'u' + Sort list of members and return highest numbered version - if it exists. + This function is called when an unversioned libFOO.a(libFOO.so) has + not been found. + + Versioning for the member name is expected to follow + GNU LIBTOOL conventions: the highest version (x, then X.y, then X.Y.z) + * find [libFoo.so.X] + * find [libFoo.so.X.Y] + * find [libFoo.so.X.Y.Z] + + Before the GNU convention became the standard scheme regardless of + binary size AIX packagers used GNU convention "as-is" for 32-bit + archive members but used an "distinguishing" name for 64-bit members. + This scheme inserted either 64 or _64 between libFOO and .so + - generally libFOO_64.so, but occasionally libFOO64.so + 'b'lib'u'lib'b'\.so\.[0-9]+[0-9.]*'u'\.so\.[0-9]+[0-9.]*'b'_?64\.so\.[0-9]+[0-9.]*'u'_?64\.so\.[0-9]+[0-9.]*'b' + Return an archive member matching the request in name. + Name is the library name without any prefix like lib, suffix like .so, + or version number. + Given a list of members find and return the most appropriate result + Priority is given to generic libXXX.so, then a versioned libXXX.so.a.b.c + and finally, legacy AIX naming scheme. + 'u' + Return an archive member matching the request in name. + Name is the library name without any prefix like lib, suffix like .so, + or version number. + Given a list of members find and return the most appropriate result + Priority is given to generic libXXX.so, then a versioned libXXX.so.a.b.c + and finally, legacy AIX naming scheme. + 'b'\.so'u'\.so'b'64\.so'u'64\.so'b' + On AIX, the buildtime searchpath is stored in the executable. + as "loader header information". + The command /usr/bin/dump -H extracts this info. + Prefix searched libraries with LD_LIBRARY_PATH (preferred), + or LIBPATH if defined. These paths are appended to the paths + to libraries the python executable is linked with. + This mimics AIX dlopen() behavior. + 'u' + On AIX, the buildtime searchpath is stored in the executable. + as "loader header information". + The command /usr/bin/dump -H extracts this info. + Prefix searched libraries with LD_LIBRARY_PATH (preferred), + or LIBPATH if defined. These paths are appended to the paths + to libraries the python executable is linked with. + This mimics AIX dlopen() behavior. + 'b'LD_LIBRARY_PATH'u'LD_LIBRARY_PATH'b'LIBPATH'u'LIBPATH'b' + paths is a list of directories to search for an archive. + name is the abbreviated name given to find_library(). + Process: search "paths" for archive, and if an archive is found + return the result of get_member(). + If an archive is not found then return None + 'u' + paths is a list of directories to search for an archive. + name is the abbreviated name given to find_library(). + Process: search "paths" for archive, and if an archive is found + return the result of get_member(). + If an archive is not found then return None + 'b'/lib'u'/lib'b'.a'u'.a'b'AIX implementation of ctypes.util.find_library() + Find an archive member that will dlopen(). If not available, + also search for a file (or link) with a .so suffix. + + AIX supports two types of schemes that can be used with dlopen(). + The so-called SystemV Release4 (svr4) format is commonly suffixed + with .so while the (default) AIX scheme has the library (archive) + ending with the suffix .a + As an archive has multiple members (e.g., 32-bit and 64-bit) in one file + the argument passed to dlopen must include both the library and + the member names in a single string. + + find_library() looks first for an archive (.a) with a suitable member. + If no archive+member pair is found, look for a .so file. + 'u'AIX implementation of ctypes.util.find_library() + Find an archive member that will dlopen(). If not available, + also search for a file (or link) with a .so suffix. + + AIX supports two types of schemes that can be used with dlopen(). + The so-called SystemV Release4 (svr4) format is commonly suffixed + with .so while the (default) AIX scheme has the library (archive) + ending with the suffix .a + As an archive has multiple members (e.g., 32-bit and 64-bit) in one file + the argument passed to dlopen must include both the library and + the member names in a single string. + + find_library() looks first for an archive (.a) with a suitable member. + If no archive+member pair is found, look for a .so file. + 'b'.so'u'.so'u'ctypes._aix'u'_aix'u'AST.__dict__'_attributes_ast.ASTASTu'operator.__weakref__'_ast.operator_ast.AddAddu'boolop.__weakref__'_ast.boolop_ast.AndAndu'target'u'annotation'u'value'u'simple'u'stmt.__weakref__'u'lineno'u'col_offset'u'end_lineno'u'end_col_offset'_ast.stmt_ast.AnnAssignAnnAssign_ast.AssertAssertu'targets'u'type_comment'_ast.AssignAssignu'iter'u'body'u'orelse'_ast.AsyncForAsyncForu'args'u'decorator_list'u'returns'_ast.AsyncFunctionDefAsyncFunctionDefu'items'_ast.AsyncWithAsyncWithu'attr'u'ctx'u'expr.__weakref__'_ast.expr_ast.AttributeAttributeu'op'_ast.AugAssignAugAssignu'expr_context.__weakref__'_ast.expr_context_ast.AugLoadAugLoad_ast.AugStoreAugStore_ast.AwaitAwaitu'left'u'right'_ast.BinOpBinOp_ast.BitAndBitAnd_ast.BitOrBitOr_ast.BitXorBitXoru'values'_ast.BoolOpBoolOp_ast.BreakBreaku'func'u'keywords'_ast.CallCallu'bases'_ast.ClassDefClassDefu'ops'u'comparators'_ast.CompareCompareu'kind'_ast.ConstantConstant_ast.Continue_ast.DelDel_ast.DeleteDeleteu'keys'_ast.DictDict_ast.DictCompDictComp_ast.DivDivu'cmpop.__weakref__'_ast.cmpop_ast.EqEqu'excepthandler.__weakref__'_ast.excepthandler_ast.ExceptHandlerExceptHandler_ast.ExprExpru'mod.__weakref__'_ast.mod_ast.ExpressionExpressionu'dims'u'slice.__weakref__'_ast.slice_ast.ExtSliceExtSlice_ast.FloorDivFloorDiv_ast.ForForu'conversion'u'format_spec'_ast.FormattedValueFormattedValue_ast.FunctionDefFunctionDefu'argtypes'_ast.FunctionTypeu'elt'_ast.GeneratorExpGeneratorExp_ast.GlobalGlobal_ast.GtGt_ast.GtEGtE_ast.IfIf_ast.IfExpIfExp_ast.ImportImportu'module'_ast.ImportFromImportFrom_ast.InIn_ast.IndexIndex_ast.InteractiveInteractiveu'unaryop.__weakref__'_ast.unaryop_ast.InvertInvert_ast.IsIs_ast.IsNotIsNot_ast.JoinedStrJoinedStr_ast.LShiftLShift_ast.LambdaLambdau'elts'_ast.ListList_ast.ListCompListComp_ast.LoadLoad_ast.LtLt_ast.LtELtE_ast.MatMultMatMult_ast.ModModu'type_ignores'_ast.ModuleModule_ast.MultMult_ast.NameName_ast.NamedExprNamedExpr_ast.NonlocalNonlocal_ast.NotNot_ast.NotEqNotEq_ast.NotInNotIn_ast.OrOr_ast.ParamParam_ast.PassPass_ast.PowPow8192PyCF_ALLOW_TOP_LEVEL_AWAITPyCF_ONLY_AST4096PyCF_TYPE_COMMENTS_ast.RShiftRShiftu'exc'u'cause'_ast.RaiseRaise_ast.ReturnReturn_ast.SetSet_ast.SetCompSetCompu'upper'u'step'_ast.SliceSlice_ast.StarredStarred_ast.StoreStore_ast.SubSubu'slice'_ast.SubscriptSubscript_ast.SuiteSuiteu'finalbody'_ast.TryTry_ast.TupleTupleu'type_ignore.__weakref__'_ast.type_ignore_ast.TypeIgnoreTypeIgnore_ast.UAddUAdd_ast.USubUSubu'operand'_ast.UnaryOpUnaryOp_ast.WhileWhile_ast.WithWith_ast.YieldYield_ast.YieldFromYieldFromu'alias.__weakref__'u'asname'_ast.aliasu'arg.__weakref__'u'arg'_ast.argu'arguments.__weakref__'u'posonlyargs'u'vararg'u'kwonlyargs'u'kw_defaults'u'kwarg'u'defaults'_ast.argumentsargumentsboolopcmpopu'comprehension.__weakref__'u'ifs'u'is_async'_ast.comprehensioncomprehensionexcepthandlerexpr_contextu'keyword.__weakref__'_ast.keywordstmttype_ignoreunaryopu'withitem.__weakref__'u'context_expr'u'optional_vars'_ast.withitemwithitem_ast__await__u'This class is *almost* compatible with concurrent.futures.Future. + + Differences: + + - result() and exception() do not take a timeout argument and + raise an exception when the future isn't done yet. + + - Callbacks registered with add_done_callback() are always called + via the event loop's call_soon_threadsafe(). + + - This class is not compatible with the wait() and as_completed() + methods in the concurrent.futures package.'u'Future._asyncio_future_blocking'_asyncio_future_blockingu'Future._callbacks'_callbacksu'Future._exception'_exceptionu'Future._log_traceback'_log_tracebacku'Future._loop'_loop_repr_infou'Future._result'_resultu'Future._source_traceback'_source_tracebacku'Future._state'_stateadd_done_callbackcancelledget_loopremove_done_callbackset_exceptionset_result_asyncio.Futureu'A coroutine wrapped in a Future.'u'Task._asyncio_future_blocking'u'Task._callbacks'u'Task._coro'_corou'Task._exception'u'Task._fut_waiter'_fut_waiteru'Task._log_destroy_pending'_log_destroy_pendingu'Task._log_traceback'u'Task._loop'u'Task._must_cancel'_must_cancelu'Task._result'u'Task._source_traceback'u'Task._state'all_taskscurrent_taskget_coroget_stack_asyncio.TaskTasku'Accelerator module for asyncio'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_asyncio.cpython-38-darwin.so'u'Loader for extension modules. + + The constructor is designed to work with FileFinder. + + 'u'FileLoader.__dict__'u'Base file loader class which implements the loader protocol methods that + require file system usage.'u'FileLoader.__weakref__'contentsis_resourceopen_resourceresource_path_frozen_importlib_external.FileLoader_frozen_importlib_external.ExtensionFileLoaderu'_asyncio'u'WeakSet.__dict__'u'_weakrefset'u'WeakSet.__weakref__'_commit_removals_weakrefset.WeakSet_all_tasks_current_tasks_enter_task_get_running_loop_leave_task_register_task_set_running_loop_unregister_taskget_event_loopget_running_loop_asyncio_AS_COMPLETEDPENDINGRUNNINGCANCELLEDCANCELLED_AND_NOTIFIEDFINISHED_FUTURE_STATESpendingrunningfinished_STATE_TO_DESCRIPTION_MAPconcurrent.futuresLOGGERBase class for all future-related exceptions.The Future was cancelled.The operation exceeded the given deadline.The operation is not allowed in this state._WaiterProvides the event that wait() and as_completed() block on.finished_futuresadd_resultfutureadd_exceptionadd_cancelled_AsCompletedWaiterUsed by as_completed()._FirstCompletedWaiterUsed by wait(return_when=FIRST_COMPLETED)._AllCompletedWaiterUsed by wait(return_when=FIRST_EXCEPTION and ALL_COMPLETED).num_pending_callsstop_on_exception_decrement_pending_calls_AcquireFuturesA context manager that does an ordered acquire of Future conditions._condition_create_and_install_waitersreturn_whenwaiterpending_countInvalid return condition: %r_waiters_yield_finished_futuresref_collect + Iterate on the list *fs*, yielding finished futures one by one in + reverse order. + Before yielding a future, *waiter* is removed from its waiters + and the future is removed from each set in the collection of sets + *ref_collect*. + + The aim of this function is to avoid keeping stale references after + the future is yielded and before the iterator resumes. + futures_setAn iterator over the given futures that yields each as it completes. + + Args: + fs: The sequence of Futures (possibly created by different Executors) to + iterate over. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + + Returns: + An iterator that yields the given Futures as they complete (finished or + cancelled). If any given Futures are duplicated, they will be returned + once. + + Raises: + TimeoutError: If the entire result iterator could not be generated + before the given timeout. + end_timetotal_futureswait_timeout%d (of %d) futures unfinishedDoneAndNotDoneFuturesdone not_doneWait for the futures in the given sequence to complete. + + Args: + fs: The sequence of Futures (possibly created by different Executors) to + wait upon. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + return_when: Indicates when this function should return. The options + are: + + FIRST_COMPLETED - Return when any future finishes or is + cancelled. + FIRST_EXCEPTION - Return when any future finishes by raising an + exception. If no future raises an exception + then it is equivalent to ALL_COMPLETED. + ALL_COMPLETED - Return when all futures finish or are cancelled. + + Returns: + A named 2-tuple of sets. The first set, named 'done', contains the + futures that completed (is finished or cancelled) before the wait + completed. The second set, named 'not_done', contains uncompleted + futures. + not_doneRepresents the result of an asynchronous computation.Initializes the future. Should not be called by clients.Condition_done_callbacks_invoke_callbacksexception calling callback for %r<%s at %#x state=%s raised %s><%s at %#x state=%s returned %s><%s at %#x state=%s>Cancel the future if possible. + + Returns True if the future was cancelled, False otherwise. A future + cannot be cancelled if it is running or has already completed. + notify_allReturn True if the future was cancelled.Return True if the future is currently executing.Return True of the future was cancelled or finished executing.__get_resultAttaches a callable that will be called when the future finishes. + + Args: + fn: A callable that will be called with this future as its only + argument when the future completes or is cancelled. The callable + will always be called by a thread in the same process in which + it was added. If the future has already completed or been + cancelled then the callable will be called immediately. These + callables are called in the order that they were added. + Return the result of the call that the future represents. + + Args: + timeout: The number of seconds to wait for the result if the future + isn't done. If None, then there is no limit on the wait time. + + Returns: + The result of the call that the future represents. + + Raises: + CancelledError: If the future was cancelled. + TimeoutError: If the future didn't finish executing before the given + timeout. + Exception: If the call raised then that exception will be raised. + Return the exception raised by the call that the future represents. + + Args: + timeout: The number of seconds to wait for the exception if the + future isn't done. If None, then there is no limit on the wait + time. + + Returns: + The exception raised by the call that the future represents or None + if the call completed without raising. + + Raises: + CancelledError: If the future was cancelled. + TimeoutError: If the future didn't finish executing before the given + timeout. + set_running_or_notify_cancelMark the future as running or process any cancel notifications. + + Should only be used by Executor implementations and unit tests. + + If the future has been cancelled (cancel() was called and returned + True) then any threads waiting on the future completing (though calls + to as_completed() or wait()) are notified and False is returned. + + If the future was not cancelled then it is put in the running state + (future calls to running() will return True) and True is returned. + + This method should be called by Executor implementations before + executing the work associated with this future. If this method returns + False then the work should not be executed. + + Returns: + False if the Future was cancelled, True otherwise. + + Raises: + RuntimeError: if this method was already called or if set_result() + or set_exception() was called. + Future %s in unexpected state: %sFuture in unexpected stateSets the return value of work associated with the future. + + Should only be used by Executor implementations and unit tests. + {}: {!r}Sets the result of the future as being the given exception. + + Should only be used by Executor implementations and unit tests. + This is an abstract base class for concrete asynchronous executors.submitSubmits a callable to be executed with the given arguments. + + Schedules the callable to be executed as fn(*args, **kwargs) and returns + a Future instance representing the execution of the callable. + + Returns: + A Future representing the given call. + descriptor 'submit' of 'Executor' object needs an argument"descriptor 'submit' of 'Executor' object "Passing 'fn' as keyword argument is deprecatedsubmit expected at least 1 positional argument, got %d'submit expected at least 1 positional argument, ''got %d'($self, fn, /, *args, **kwargs)iterableschunksizeReturns an iterator equivalent to map(fn, iter). + + Args: + fn: A callable that will take as many arguments as there are + passed iterables. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + chunksize: The size of the chunks the iterable will be broken into + before being passed to a child process. This argument is only + used by ProcessPoolExecutor; it is ignored by + ThreadPoolExecutor. + + Returns: + An iterator equivalent to: map(func, *iterables) but the calls may + be evaluated out-of-order. + + Raises: + TimeoutError: If the entire result iterator could not be generated + before the given timeout. + Exception: If fn(*args) raises for any values. + result_iteratorClean-up the resources associated with the Executor. + + It is safe to call this method several times. Otherwise, no other + methods can be called after this one. + + Args: + wait: If True then shutdown will not return until all running + futures have finished executing and the resources used by the + executor have been reclaimed. + exc_val + Raised when a executor has become non-functional after a severe failure. + # Possible future states (for internal use by the futures package).# The future was cancelled by the user...# ...and _Waiter.add_cancelled() was called by a worker.# Logger for internal use by the futures package.# Careful not to keep a reference to the popped value# reverse to keep finishing order# Remove waiter from unfinished futures# Break a reference cycle with the exception in self._exception# The following methods should only be used by Executors and in tests.# self._condition.notify_all() is not necessary because# self.cancel() triggers a notification.# Yield must be hidden in closure so that the futures are submitted# before the first iterator value is required.# Careful not to keep a reference to the popped futureb'_AS_COMPLETED'u'_AS_COMPLETED'b'PENDING'u'PENDING'b'RUNNING'u'RUNNING'b'CANCELLED'u'CANCELLED'b'CANCELLED_AND_NOTIFIED'u'CANCELLED_AND_NOTIFIED'b'FINISHED'u'FINISHED'b'pending'u'pending'b'running'u'running'b'cancelled'u'cancelled'b'finished'u'finished'b'concurrent.futures'b'Base class for all future-related exceptions.'u'Base class for all future-related exceptions.'b'The Future was cancelled.'u'The Future was cancelled.'b'The operation exceeded the given deadline.'u'The operation exceeded the given deadline.'b'The operation is not allowed in this state.'u'The operation is not allowed in this state.'b'Provides the event that wait() and as_completed() block on.'u'Provides the event that wait() and as_completed() block on.'b'Used by as_completed().'u'Used by as_completed().'b'Used by wait(return_when=FIRST_COMPLETED).'u'Used by wait(return_when=FIRST_COMPLETED).'b'Used by wait(return_when=FIRST_EXCEPTION and ALL_COMPLETED).'u'Used by wait(return_when=FIRST_EXCEPTION and ALL_COMPLETED).'b'A context manager that does an ordered acquire of Future conditions.'u'A context manager that does an ordered acquire of Future conditions.'b'Invalid return condition: %r'u'Invalid return condition: %r'b' + Iterate on the list *fs*, yielding finished futures one by one in + reverse order. + Before yielding a future, *waiter* is removed from its waiters + and the future is removed from each set in the collection of sets + *ref_collect*. + + The aim of this function is to avoid keeping stale references after + the future is yielded and before the iterator resumes. + 'u' + Iterate on the list *fs*, yielding finished futures one by one in + reverse order. + Before yielding a future, *waiter* is removed from its waiters + and the future is removed from each set in the collection of sets + *ref_collect*. + + The aim of this function is to avoid keeping stale references after + the future is yielded and before the iterator resumes. + 'b'An iterator over the given futures that yields each as it completes. + + Args: + fs: The sequence of Futures (possibly created by different Executors) to + iterate over. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + + Returns: + An iterator that yields the given Futures as they complete (finished or + cancelled). If any given Futures are duplicated, they will be returned + once. + + Raises: + TimeoutError: If the entire result iterator could not be generated + before the given timeout. + 'u'An iterator over the given futures that yields each as it completes. + + Args: + fs: The sequence of Futures (possibly created by different Executors) to + iterate over. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + + Returns: + An iterator that yields the given Futures as they complete (finished or + cancelled). If any given Futures are duplicated, they will be returned + once. + + Raises: + TimeoutError: If the entire result iterator could not be generated + before the given timeout. + 'b'%d (of %d) futures unfinished'u'%d (of %d) futures unfinished'b'DoneAndNotDoneFutures'u'DoneAndNotDoneFutures'b'done not_done'u'done not_done'b'Wait for the futures in the given sequence to complete. + + Args: + fs: The sequence of Futures (possibly created by different Executors) to + wait upon. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + return_when: Indicates when this function should return. The options + are: + + FIRST_COMPLETED - Return when any future finishes or is + cancelled. + FIRST_EXCEPTION - Return when any future finishes by raising an + exception. If no future raises an exception + then it is equivalent to ALL_COMPLETED. + ALL_COMPLETED - Return when all futures finish or are cancelled. + + Returns: + A named 2-tuple of sets. The first set, named 'done', contains the + futures that completed (is finished or cancelled) before the wait + completed. The second set, named 'not_done', contains uncompleted + futures. + 'u'Wait for the futures in the given sequence to complete. + + Args: + fs: The sequence of Futures (possibly created by different Executors) to + wait upon. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + return_when: Indicates when this function should return. The options + are: + + FIRST_COMPLETED - Return when any future finishes or is + cancelled. + FIRST_EXCEPTION - Return when any future finishes by raising an + exception. If no future raises an exception + then it is equivalent to ALL_COMPLETED. + ALL_COMPLETED - Return when all futures finish or are cancelled. + + Returns: + A named 2-tuple of sets. The first set, named 'done', contains the + futures that completed (is finished or cancelled) before the wait + completed. The second set, named 'not_done', contains uncompleted + futures. + 'b'Represents the result of an asynchronous computation.'u'Represents the result of an asynchronous computation.'b'Initializes the future. Should not be called by clients.'u'Initializes the future. Should not be called by clients.'b'exception calling callback for %r'u'exception calling callback for %r'b'<%s at %#x state=%s raised %s>'u'<%s at %#x state=%s raised %s>'b'<%s at %#x state=%s returned %s>'u'<%s at %#x state=%s returned %s>'b'<%s at %#x state=%s>'u'<%s at %#x state=%s>'b'Cancel the future if possible. + + Returns True if the future was cancelled, False otherwise. A future + cannot be cancelled if it is running or has already completed. + 'u'Cancel the future if possible. + + Returns True if the future was cancelled, False otherwise. A future + cannot be cancelled if it is running or has already completed. + 'b'Return True if the future was cancelled.'u'Return True if the future was cancelled.'b'Return True if the future is currently executing.'u'Return True if the future is currently executing.'b'Return True of the future was cancelled or finished executing.'u'Return True of the future was cancelled or finished executing.'b'Attaches a callable that will be called when the future finishes. + + Args: + fn: A callable that will be called with this future as its only + argument when the future completes or is cancelled. The callable + will always be called by a thread in the same process in which + it was added. If the future has already completed or been + cancelled then the callable will be called immediately. These + callables are called in the order that they were added. + 'u'Attaches a callable that will be called when the future finishes. + + Args: + fn: A callable that will be called with this future as its only + argument when the future completes or is cancelled. The callable + will always be called by a thread in the same process in which + it was added. If the future has already completed or been + cancelled then the callable will be called immediately. These + callables are called in the order that they were added. + 'b'Return the result of the call that the future represents. + + Args: + timeout: The number of seconds to wait for the result if the future + isn't done. If None, then there is no limit on the wait time. + + Returns: + The result of the call that the future represents. + + Raises: + CancelledError: If the future was cancelled. + TimeoutError: If the future didn't finish executing before the given + timeout. + Exception: If the call raised then that exception will be raised. + 'u'Return the result of the call that the future represents. + + Args: + timeout: The number of seconds to wait for the result if the future + isn't done. If None, then there is no limit on the wait time. + + Returns: + The result of the call that the future represents. + + Raises: + CancelledError: If the future was cancelled. + TimeoutError: If the future didn't finish executing before the given + timeout. + Exception: If the call raised then that exception will be raised. + 'b'Return the exception raised by the call that the future represents. + + Args: + timeout: The number of seconds to wait for the exception if the + future isn't done. If None, then there is no limit on the wait + time. + + Returns: + The exception raised by the call that the future represents or None + if the call completed without raising. + + Raises: + CancelledError: If the future was cancelled. + TimeoutError: If the future didn't finish executing before the given + timeout. + 'u'Return the exception raised by the call that the future represents. + + Args: + timeout: The number of seconds to wait for the exception if the + future isn't done. If None, then there is no limit on the wait + time. + + Returns: + The exception raised by the call that the future represents or None + if the call completed without raising. + + Raises: + CancelledError: If the future was cancelled. + TimeoutError: If the future didn't finish executing before the given + timeout. + 'b'Mark the future as running or process any cancel notifications. + + Should only be used by Executor implementations and unit tests. + + If the future has been cancelled (cancel() was called and returned + True) then any threads waiting on the future completing (though calls + to as_completed() or wait()) are notified and False is returned. + + If the future was not cancelled then it is put in the running state + (future calls to running() will return True) and True is returned. + + This method should be called by Executor implementations before + executing the work associated with this future. If this method returns + False then the work should not be executed. + + Returns: + False if the Future was cancelled, True otherwise. + + Raises: + RuntimeError: if this method was already called or if set_result() + or set_exception() was called. + 'u'Mark the future as running or process any cancel notifications. + + Should only be used by Executor implementations and unit tests. + + If the future has been cancelled (cancel() was called and returned + True) then any threads waiting on the future completing (though calls + to as_completed() or wait()) are notified and False is returned. + + If the future was not cancelled then it is put in the running state + (future calls to running() will return True) and True is returned. + + This method should be called by Executor implementations before + executing the work associated with this future. If this method returns + False then the work should not be executed. + + Returns: + False if the Future was cancelled, True otherwise. + + Raises: + RuntimeError: if this method was already called or if set_result() + or set_exception() was called. + 'b'Future %s in unexpected state: %s'u'Future %s in unexpected state: %s'b'Future in unexpected state'u'Future in unexpected state'b'Sets the return value of work associated with the future. + + Should only be used by Executor implementations and unit tests. + 'u'Sets the return value of work associated with the future. + + Should only be used by Executor implementations and unit tests. + 'b'{}: {!r}'u'{}: {!r}'b'Sets the result of the future as being the given exception. + + Should only be used by Executor implementations and unit tests. + 'u'Sets the result of the future as being the given exception. + + Should only be used by Executor implementations and unit tests. + 'b'This is an abstract base class for concrete asynchronous executors.'u'This is an abstract base class for concrete asynchronous executors.'b'Submits a callable to be executed with the given arguments. + + Schedules the callable to be executed as fn(*args, **kwargs) and returns + a Future instance representing the execution of the callable. + + Returns: + A Future representing the given call. + 'u'Submits a callable to be executed with the given arguments. + + Schedules the callable to be executed as fn(*args, **kwargs) and returns + a Future instance representing the execution of the callable. + + Returns: + A Future representing the given call. + 'b'descriptor 'submit' of 'Executor' object needs an argument'u'descriptor 'submit' of 'Executor' object needs an argument'b'fn'u'fn'b'Passing 'fn' as keyword argument is deprecated'u'Passing 'fn' as keyword argument is deprecated'b'submit expected at least 1 positional argument, got %d'u'submit expected at least 1 positional argument, got %d'b'($self, fn, /, *args, **kwargs)'u'($self, fn, /, *args, **kwargs)'b'Returns an iterator equivalent to map(fn, iter). + + Args: + fn: A callable that will take as many arguments as there are + passed iterables. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + chunksize: The size of the chunks the iterable will be broken into + before being passed to a child process. This argument is only + used by ProcessPoolExecutor; it is ignored by + ThreadPoolExecutor. + + Returns: + An iterator equivalent to: map(func, *iterables) but the calls may + be evaluated out-of-order. + + Raises: + TimeoutError: If the entire result iterator could not be generated + before the given timeout. + Exception: If fn(*args) raises for any values. + 'u'Returns an iterator equivalent to map(fn, iter). + + Args: + fn: A callable that will take as many arguments as there are + passed iterables. + timeout: The maximum number of seconds to wait. If None, then there + is no limit on the wait time. + chunksize: The size of the chunks the iterable will be broken into + before being passed to a child process. This argument is only + used by ProcessPoolExecutor; it is ignored by + ThreadPoolExecutor. + + Returns: + An iterator equivalent to: map(func, *iterables) but the calls may + be evaluated out-of-order. + + Raises: + TimeoutError: If the entire result iterator could not be generated + before the given timeout. + Exception: If fn(*args) raises for any values. + 'b'Clean-up the resources associated with the Executor. + + It is safe to call this method several times. Otherwise, no other + methods can be called after this one. + + Args: + wait: If True then shutdown will not return until all running + futures have finished executing and the resources used by the + executor have been reclaimed. + 'u'Clean-up the resources associated with the Executor. + + It is safe to call this method several times. Otherwise, no other + methods can be called after this one. + + Args: + wait: If True then shutdown will not return until all running + futures have finished executing and the resources used by the + executor have been reclaimed. + 'b' + Raised when a executor has become non-functional after a severe failure. + 'u' + Raised when a executor has become non-functional after a severe failure. + 'u'concurrent.futures._base'u'futures._base'u'_base'u'Bisection algorithms. + +This module provides support for maintaining a list in sorted order without +having to sort the list after each insertion. For long lists of items with +expensive comparison operations, this can be an improvement over the more +common approach. +'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_bisect.cpython-38-darwin.so'u'_bisect'bisect_leftbisect_rightinsort_leftinsort_right_bisectBLAKE2B_MAX_DIGEST_SIZEBLAKE2B_MAX_KEY_SIZEBLAKE2B_PERSON_SIZEBLAKE2B_SALT_SIZEBLAKE2S_MAX_DIGEST_SIZEBLAKE2S_MAX_KEY_SIZEBLAKE2S_PERSON_SIZEBLAKE2S_SALT_SIZEu'_blake2b provides BLAKE2b for hashlib +'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_blake2.cpython-38-darwin.so'u'_blake2'MAX_DIGEST_SIZEMAX_KEY_SIZEPERSON_SIZESALT_SIZEu'Return a new BLAKE2b hash object.'u'blake2b.block_size'block_sizedigestu'blake2b.digest_size'digest_sizehexdigestu'blake2b.name'_blake2.blake2bblake2bu'Return a new BLAKE2s hash object.'u'blake2s.block_size'u'blake2s.digest_size'u'blake2s.name'_blake2.blake2sblake2s_blake2A minimal subset of the locale module used at interpreter startup +(imported by the _io module), in order to reduce startup time. + +Don't import directly from third-party code; use the `locale` module instead! +_localedo_setlocaleUTF-8_getdefaultlocaleCODESETnl_langinfo# On Android langinfo.h and CODESET are missing, and UTF-8 is# always used in mbstowcs() and wcstombs().# This path for legacy systems needs the more complex# getdefaultlocale() function, import the full locale module.# nl_langinfo can return an empty string# when the setting has an invalid value.# Default to UTF-8 in that case because# UTF-8 is the default charset on OSX and# returning nothing will crash the# interpreter.b'A minimal subset of the locale module used at interpreter startup +(imported by the _io module), in order to reduce startup time. + +Don't import directly from third-party code; use the `locale` module instead! +'u'A minimal subset of the locale module used at interpreter startup +(imported by the _io module), in order to reduce startup time. + +Don't import directly from third-party code; use the `locale` module instead! +'b'UTF-8'u'UTF-8'u'_bootlocale'Core implementation of import. + +This module is NOT meant to be directly imported! It has been designed such +that it can be bootstrapped into Python as the implementation of import. As +such it requires the injection of specific modules and attributes in order to +work. One should use importlib as the public-facing version of this module. + +_wrapSimple substitute for functools.update_wrapper._new_module_module_locks_blocking_on_DeadlockError_ModuleLockA recursive lock implementation which is able to detect deadlocks + (e.g. thread 1 trying to take locks A then B, and thread 2 trying to + take locks B then A). + allocate_lockwakeupownerwaitershas_deadlockmetid + Acquire the module lock. If a potential deadlock is detected, + a _DeadlockError is raised. + Otherwise, the lock is always acquired and True is returned. + deadlock detected by %rcannot release un-acquired lock_ModuleLock({!r}) at {}_DummyModuleLockA simple _ModuleLock equivalent for Python builds without + multi-threading support._DummyModuleLock({!r}) at {}_ModuleLockManager_get_module_lockGet or create the module lock for a given module name. + + Acquire/release internally the global import lock to protect + _module_locks.acquire_lockcbrelease_lock_lock_unlock_moduleAcquires then releases the module lock for a given module name. + + This is used to ensure a module is completely initialized, in the + event it is being imported by another thread. + _call_with_frames_removedremove_importlib_frames in import.c will always remove sequences + of importlib frames that end with a call to this function + + Use it instead of a normal call in places where including the importlib + frames introduces unwanted noise into the traceback (e.g. when executing + module code) + _verbose_messagePrint the message to stderr if -v/PYTHONVERBOSE is turned on.import # _requires_builtinfxnDecorator to verify the named module is built-in._requires_builtin_wrapper{!r} is not a built-in module_requires_frozenDecorator to verify the named module is frozen._requires_frozen_wrapperis_frozen{!r} is not a frozen module_load_module_shimLoad the specified module into sys.modules and return it. + + This method is deprecated. Use loader.exec_module instead. + + spec_from_loader_load_module_repr_module_repr_from_specModuleSpecThe specification for a module, used for loading. + + A module's spec is the source for information about the module. For + data associated with the module, including source, use the spec's + loader. + + `name` is the absolute name of the module. `loader` is the loader + to use when loading the module. `parent` is the name of the + package the module is in. The parent is derived from the name. + + `is_package` determines if the module is considered a package or + not. On modules this is reflected by the `__path__` attribute. + + `origin` is the specific location used by the loader from which to + load the module, if that information is available. When filename is + set, origin will match. + + `has_location` indicates that a spec's "origin" reflects a location. + When this is True, `__file__` attribute of the module is set. + + `cached` is the location of the cached bytecode file, if any. It + corresponds to the `__cached__` attribute. + + `submodule_search_locations` is the sequence of path entries to + search when importing submodules. If set, is_package should be + True--and False otherwise. + + Packages are simply modules that (may) have submodules. If a spec + has a non-None value in `submodule_search_locations`, the import + system will consider modules loaded from the spec as packages. + + Only finders (see importlib.abc.MetaPathFinder and + importlib.abc.PathEntryFinder) should modify ModuleSpec instances. + + originloader_state_set_fileattr_cachedname={!r}loader={!r}origin={!r}submodule_search_locations={}{}({})smsl_get_cachedThe name of the module's parent.Return a module spec based on various loader methods.spec_from_file_location_spec_from_module__cached___init_module_attrsoverride_NamespaceLoader_pathmodule_from_specCreate a module based on the provided spec.loaders that define exec_module() must also define create_module()'loaders that define exec_module() ''must also define create_module()'Return the repr to use for the module.Execute the spec's specified module in an existing module's namespace.module {!r} not in sys.modulesmissing loader_load_backward_compatible_load_unlocked_initializingimport {!r} # {!r}Return a new module object, loaded by the spec's loader. + + The module is not added to its parent. + + If a module is already in sys.modules, that existing module gets + clobbered. + + BuiltinImporterMeta path import for built-in modules. + + All methods are either class or static methods to avoid the need to + instantiate the class. + + Return repr for the module. + + The method is deprecated. The import machinery does the job itself. + + is_builtinbuilt-inFind the built-in module. + + If 'path' is ever specified then the search is considered a failure. + + This method is deprecated. Use find_spec() instead. + + Create a built-in modulecreate_builtinExec a built-in moduleexec_builtinReturn None as built-in modules do not have code objects.Return None as built-in modules do not have source code.Return False as built-in modules are never packages.FrozenImporterMeta path import for frozen modules. + + All methods are either class or static methods to avoid the need to + instantiate the class. + + frozenFind a frozen module. + + This method is deprecated. Use find_spec() instead. + + Use default semantics for module creation.get_frozen_objectLoad a frozen module. + + This method is deprecated. Use exec_module() instead. + + Return the code object for the frozen module.Return None as frozen modules do not have source code.Return True if the frozen module is a package.is_frozen_package_ImportLockContextContext manager for the import lock.Acquire the import lock.Release the import lock regardless of any raised exceptions._resolve_nameResolve a relative module name to an absolute one.attempted relative import beyond top-level package{}.{}_find_spec_legacyFind a module's spec.sys.meta_path is None, Python is likely shutting down"sys.meta_path is None, Python is likely ""shutting down"sys.meta_path is emptyis_reload_sanity_checkVerify arguments are "sane".module name must be str, not {}level must be >= 0__package__ not set to a stringattempted relative import with no known parent package'attempted relative import with no known parent ''package'Empty module nameNo module named _ERR_MSG_PREFIX{!r}_ERR_MSG_find_and_load_unlockedimport_parent_module; {!r} is not a package_NEEDS_LOADING_find_and_loadFind and load the module.import of {} halted; None in sys.modules'import of {} halted; ''None in sys.modules'Import and return the module based on its name, the package the call is + being made from, and the level adjustment. + + This function represents the greatest common denominator of functionality + between import_module and __import__. This includes setting __package__ if + the loader did not. + + _handle_fromlistrecursiveFigure out what __import__ should return. + + The import_ parameter is a callable which takes the name of module to + import. It is required to decouple the function from assuming importlib's + import implementation is desired. + + .__all__where``from list''Item in must be str, not " must be str, ""not "from_name_calc___package__Calculate what __package__ should be. + + __package__ is not guaranteed to be defined or could be set to None + to represent that its proper value is unknown. + + __package__ != __spec__.parent ("__package__ != __spec__.parent ""(" != can't resolve package from __spec__ or __package__, falling back on __name__ and __path__"can't resolve package from __spec__ or __package__, ""falling back on __name__ and __path__"Import a module. + + The 'globals' argument is used to infer where the import is occurring from + to handle relative imports. The 'locals' argument is ignored. The + 'fromlist' argument specifies what should exist as attributes on the module + being imported (e.g. ``from module import ``). The 'level' + argument represents the package location to import from in a relative + import (e.g. ``from ..pkg import mod`` would have a 'level' of 2). + + globals_cut_off_builtin_from_nameno built-in module named sys_module_imp_moduleSetup importlib by importing needed built-in modules and injecting them + into the global namespace. + + As sys is needed for sys.modules access and _imp is needed to load built-in + modules, those two modules must be explicitly passed in. + + module_typeself_modulebuiltin_name_installInstall importers for builtin and frozen modules_install_external_importersInstall importers that require external filesystem access# IMPORTANT: Whenever making changes to this module, be sure to run a top-level# `make regen-importlib` followed by `make` in order to get the frozen version# of the module updated. Not doing so will result in the Makefile to fail for# all others who don't have a ./python around to freeze the module# in the early stages of compilation.# See importlib._setup() for what is injected into the global namespace.# When editing this code be aware that code executed at import time CANNOT# reference any injected objects! This includes not only global code but also# anything specified at the class level.# Bootstrap-related code ####################################################### Module-level locking ######################################################### A dict mapping module names to weakrefs of _ModuleLock instances# Dictionary protected by the global import lock# A dict mapping thread ids to _ModuleLock instances# Deadlock avoidance for concurrent circular imports.# Wait for a release() call# The following two functions are for consumption by Python/import.c.# bpo-31070: Check if another thread created a new lock# after the previous lock was destroyed# but before the weakref callback was called.# Concurrent circular import, we'll accept a partially initialized# module object.# Frame stripping magic ################################################ Typically used by loader classes as a method replacement.# Module specifications ######################################################## The implementation of ModuleType.__repr__().# As soon as BuiltinImporter, FrozenImporter, and NamespaceLoader# drop their implementations for module_repr. we can add a# deprecation warning here.# We could use module.__class__.__name__ instead of 'module' in the# various repr permutations.# file-location attributes# aka, undefined# the default# This function is meant for use in _setup().# loader will stay None.# The passed-in module may be not support attribute assignment,# in which case we simply don't set the attributes.# __name__# __loader__# A backward compatibility hack.# While the docs say that module.__file__ is not set for# built-in modules, and the code below will avoid setting it if# spec.has_location is false, this is incorrect for namespace# packages. Namespace packages have no location, but their# __spec__.origin is None, and thus their module.__file__# should also be None for consistency. While a bit of a hack,# this is the best place to ensure this consistency.# See # https://docs.python.org/3/library/importlib.html#importlib.abc.Loader.load_module# and bpo-32305# __package__# __spec__# __path__# __file__/__cached__# Typically loaders will not implement create_module().# If create_module() returns `None` then it means default# module creation should be used.# We mostly replicate _module_repr() using the spec attributes.# Used by importlib.reload() and _load_module_shim().# Namespace package.# (issue19713) Once BuiltinImporter and ExtensionFileLoader# have exec_module() implemented, we can add a deprecation# warning here.# Update the order of insertion into sys.modules for module# clean-up at shutdown.# The module must be in sys.modules at this point!# Move it to the end of sys.modules.# Since module.__path__ may not line up with# spec.submodule_search_paths, we can't necessarily rely# on spec.parent here.# A helper for direct use by the import system.# Not a namespace package.# This must be done before putting the module in sys.modules# (otherwise an optimization shortcut in import.c becomes# wrong).# A namespace package so do nothing.# Move the module to the end of sys.modules.# We don't ensure that the import-related module attributes get# set in the sys.modules replacement case. Such modules are on# their own.# A method used during testing of _load_unlocked() and by# _load_module_shim().# Loaders ###################################################################### Import itself ################################################################ This would be a good place for a DeprecationWarning if# we ended up going that route.# PyImport_Cleanup() is running or has been called.# We check sys.modules here for the reload case. While a passed-in# target will usually indicate a reload there is no guarantee, whereas# sys.modules provides one.# The parent import may have already imported this module.# We use the found spec since that is the one that# we would have used if the parent module hadn't# beaten us to the punch.# Crazy side-effects!# Set the module as an attribute on its parent.# The hell that is fromlist ...# If a package was imported, try to import stuff from fromlist.# Backwards-compatibility dictates we ignore failed# imports triggered by fromlist for modules that don't# exist.# Return up to the first dot in 'name'. This is complicated by the fact# that 'name' may be relative.# Figure out where to slice the module's name up to the first dot# in 'name'.# Slice end needs to be positive to alleviate need to special-case# when ``'.' not in name``.# Set up the spec for existing builtin/frozen modules.# Directly load built-in modules needed during bootstrap.b'Core implementation of import. + +This module is NOT meant to be directly imported! It has been designed such +that it can be bootstrapped into Python as the implementation of import. As +such it requires the injection of specific modules and attributes in order to +work. One should use importlib as the public-facing version of this module. + +'u'Core implementation of import. + +This module is NOT meant to be directly imported! It has been designed such +that it can be bootstrapped into Python as the implementation of import. As +such it requires the injection of specific modules and attributes in order to +work. One should use importlib as the public-facing version of this module. + +'b'Simple substitute for functools.update_wrapper.'u'Simple substitute for functools.update_wrapper.'b'__qualname__'u'__qualname__'b'A recursive lock implementation which is able to detect deadlocks + (e.g. thread 1 trying to take locks A then B, and thread 2 trying to + take locks B then A). + 'u'A recursive lock implementation which is able to detect deadlocks + (e.g. thread 1 trying to take locks A then B, and thread 2 trying to + take locks B then A). + 'b' + Acquire the module lock. If a potential deadlock is detected, + a _DeadlockError is raised. + Otherwise, the lock is always acquired and True is returned. + 'u' + Acquire the module lock. If a potential deadlock is detected, + a _DeadlockError is raised. + Otherwise, the lock is always acquired and True is returned. + 'b'deadlock detected by %r'u'deadlock detected by %r'b'cannot release un-acquired lock'u'cannot release un-acquired lock'b'_ModuleLock({!r}) at {}'u'_ModuleLock({!r}) at {}'b'A simple _ModuleLock equivalent for Python builds without + multi-threading support.'u'A simple _ModuleLock equivalent for Python builds without + multi-threading support.'b'_DummyModuleLock({!r}) at {}'u'_DummyModuleLock({!r}) at {}'b'Get or create the module lock for a given module name. + + Acquire/release internally the global import lock to protect + _module_locks.'u'Get or create the module lock for a given module name. + + Acquire/release internally the global import lock to protect + _module_locks.'b'Acquires then releases the module lock for a given module name. + + This is used to ensure a module is completely initialized, in the + event it is being imported by another thread. + 'u'Acquires then releases the module lock for a given module name. + + This is used to ensure a module is completely initialized, in the + event it is being imported by another thread. + 'b'remove_importlib_frames in import.c will always remove sequences + of importlib frames that end with a call to this function + + Use it instead of a normal call in places where including the importlib + frames introduces unwanted noise into the traceback (e.g. when executing + module code) + 'u'remove_importlib_frames in import.c will always remove sequences + of importlib frames that end with a call to this function + + Use it instead of a normal call in places where including the importlib + frames introduces unwanted noise into the traceback (e.g. when executing + module code) + 'b'Print the message to stderr if -v/PYTHONVERBOSE is turned on.'u'Print the message to stderr if -v/PYTHONVERBOSE is turned on.'b'import 'u'import 'b'# 'u'# 'b'Decorator to verify the named module is built-in.'u'Decorator to verify the named module is built-in.'b'{!r} is not a built-in module'u'{!r} is not a built-in module'b'Decorator to verify the named module is frozen.'u'Decorator to verify the named module is frozen.'b'{!r} is not a frozen module'u'{!r} is not a frozen module'b'Load the specified module into sys.modules and return it. + + This method is deprecated. Use loader.exec_module instead. + + 'u'Load the specified module into sys.modules and return it. + + This method is deprecated. Use loader.exec_module instead. + + 'b'__loader__'u'__loader__'b'module_repr'u'module_repr'b''u''b''u''b''u''b'The specification for a module, used for loading. + + A module's spec is the source for information about the module. For + data associated with the module, including source, use the spec's + loader. + + `name` is the absolute name of the module. `loader` is the loader + to use when loading the module. `parent` is the name of the + package the module is in. The parent is derived from the name. + + `is_package` determines if the module is considered a package or + not. On modules this is reflected by the `__path__` attribute. + + `origin` is the specific location used by the loader from which to + load the module, if that information is available. When filename is + set, origin will match. + + `has_location` indicates that a spec's "origin" reflects a location. + When this is True, `__file__` attribute of the module is set. + + `cached` is the location of the cached bytecode file, if any. It + corresponds to the `__cached__` attribute. + + `submodule_search_locations` is the sequence of path entries to + search when importing submodules. If set, is_package should be + True--and False otherwise. + + Packages are simply modules that (may) have submodules. If a spec + has a non-None value in `submodule_search_locations`, the import + system will consider modules loaded from the spec as packages. + + Only finders (see importlib.abc.MetaPathFinder and + importlib.abc.PathEntryFinder) should modify ModuleSpec instances. + + 'b'name={!r}'u'name={!r}'b'loader={!r}'u'loader={!r}'b'origin={!r}'u'origin={!r}'b'submodule_search_locations={}'u'submodule_search_locations={}'b'{}({})'u'{}({})'b'The name of the module's parent.'u'The name of the module's parent.'b'Return a module spec based on various loader methods.'u'Return a module spec based on various loader methods.'b'get_filename'u'get_filename'b'is_package'u'is_package'b'__package__'u'__package__'b'__path__'u'__path__'b'__file__'u'__file__'b'__cached__'u'__cached__'b'Create a module based on the provided spec.'u'Create a module based on the provided spec.'b'create_module'u'create_module'b'exec_module'u'exec_module'b'loaders that define exec_module() must also define create_module()'u'loaders that define exec_module() must also define create_module()'b'Return the repr to use for the module.'u'Return the repr to use for the module.'b''u''b'Execute the spec's specified module in an existing module's namespace.'u'Execute the spec's specified module in an existing module's namespace.'b'module {!r} not in sys.modules'u'module {!r} not in sys.modules'b'missing loader'u'missing loader'b'__spec__'u'__spec__'b'import {!r} # {!r}'u'import {!r} # {!r}'b'Return a new module object, loaded by the spec's loader. + + The module is not added to its parent. + + If a module is already in sys.modules, that existing module gets + clobbered. + + 'u'Return a new module object, loaded by the spec's loader. + + The module is not added to its parent. + + If a module is already in sys.modules, that existing module gets + clobbered. + + 'b'Meta path import for built-in modules. + + All methods are either class or static methods to avoid the need to + instantiate the class. + + 'b'Return repr for the module. + + The method is deprecated. The import machinery does the job itself. + + 'u'Return repr for the module. + + The method is deprecated. The import machinery does the job itself. + + 'b''u''b'built-in'u'built-in'b'Find the built-in module. + + If 'path' is ever specified then the search is considered a failure. + + This method is deprecated. Use find_spec() instead. + + 'u'Find the built-in module. + + If 'path' is ever specified then the search is considered a failure. + + This method is deprecated. Use find_spec() instead. + + 'b'Create a built-in module'u'Create a built-in module'b'Exec a built-in module'u'Exec a built-in module'b'Return None as built-in modules do not have code objects.'u'Return None as built-in modules do not have code objects.'b'Return None as built-in modules do not have source code.'u'Return None as built-in modules do not have source code.'b'Return False as built-in modules are never packages.'u'Return False as built-in modules are never packages.'b'Meta path import for frozen modules. + + All methods are either class or static methods to avoid the need to + instantiate the class. + + 'b'frozen'b'Find a frozen module. + + This method is deprecated. Use find_spec() instead. + + 'u'Find a frozen module. + + This method is deprecated. Use find_spec() instead. + + 'b'Use default semantics for module creation.'u'Use default semantics for module creation.'b'Load a frozen module. + + This method is deprecated. Use exec_module() instead. + + 'u'Load a frozen module. + + This method is deprecated. Use exec_module() instead. + + 'b'Return the code object for the frozen module.'u'Return the code object for the frozen module.'b'Return None as frozen modules do not have source code.'u'Return None as frozen modules do not have source code.'b'Return True if the frozen module is a package.'u'Return True if the frozen module is a package.'b'Context manager for the import lock.'u'Context manager for the import lock.'b'Acquire the import lock.'u'Acquire the import lock.'b'Release the import lock regardless of any raised exceptions.'u'Release the import lock regardless of any raised exceptions.'b'Resolve a relative module name to an absolute one.'u'Resolve a relative module name to an absolute one.'b'attempted relative import beyond top-level package'u'attempted relative import beyond top-level package'b'{}.{}'u'{}.{}'b'Find a module's spec.'u'Find a module's spec.'b'sys.meta_path is None, Python is likely shutting down'u'sys.meta_path is None, Python is likely shutting down'b'sys.meta_path is empty'u'sys.meta_path is empty'b'Verify arguments are "sane".'u'Verify arguments are "sane".'b'module name must be str, not {}'u'module name must be str, not {}'b'level must be >= 0'u'level must be >= 0'b'__package__ not set to a string'u'__package__ not set to a string'b'attempted relative import with no known parent package'u'attempted relative import with no known parent package'b'Empty module name'u'Empty module name'b'No module named 'u'No module named 'b'{!r}'u'{!r}'b'; {!r} is not a package'u'; {!r} is not a package'b'Find and load the module.'u'Find and load the module.'b'import of {} halted; None in sys.modules'u'import of {} halted; None in sys.modules'b'Import and return the module based on its name, the package the call is + being made from, and the level adjustment. + + This function represents the greatest common denominator of functionality + between import_module and __import__. This includes setting __package__ if + the loader did not. + + 'u'Import and return the module based on its name, the package the call is + being made from, and the level adjustment. + + This function represents the greatest common denominator of functionality + between import_module and __import__. This includes setting __package__ if + the loader did not. + + 'b'Figure out what __import__ should return. + + The import_ parameter is a callable which takes the name of module to + import. It is required to decouple the function from assuming importlib's + import implementation is desired. + + 'u'Figure out what __import__ should return. + + The import_ parameter is a callable which takes the name of module to + import. It is required to decouple the function from assuming importlib's + import implementation is desired. + + 'b'.__all__'u'.__all__'b'``from list'''u'``from list'''b'Item in 'u'Item in 'b' must be str, not 'u' must be str, not 'b'__all__'u'__all__'b'Calculate what __package__ should be. + + __package__ is not guaranteed to be defined or could be set to None + to represent that its proper value is unknown. + + 'u'Calculate what __package__ should be. + + __package__ is not guaranteed to be defined or could be set to None + to represent that its proper value is unknown. + + 'b'__package__ != __spec__.parent ('u'__package__ != __spec__.parent ('b' != 'u' != 'b'can't resolve package from __spec__ or __package__, falling back on __name__ and __path__'u'can't resolve package from __spec__ or __package__, falling back on __name__ and __path__'b'Import a module. + + The 'globals' argument is used to infer where the import is occurring from + to handle relative imports. The 'locals' argument is ignored. The + 'fromlist' argument specifies what should exist as attributes on the module + being imported (e.g. ``from module import ``). The 'level' + argument represents the package location to import from in a relative + import (e.g. ``from ..pkg import mod`` would have a 'level' of 2). + + 'u'Import a module. + + The 'globals' argument is used to infer where the import is occurring from + to handle relative imports. The 'locals' argument is ignored. The + 'fromlist' argument specifies what should exist as attributes on the module + being imported (e.g. ``from module import ``). The 'level' + argument represents the package location to import from in a relative + import (e.g. ``from ..pkg import mod`` would have a 'level' of 2). + + 'b'no built-in module named 'u'no built-in module named 'b'Setup importlib by importing needed built-in modules and injecting them + into the global namespace. + + As sys is needed for sys.modules access and _imp is needed to load built-in + modules, those two modules must be explicitly passed in. + + 'u'Setup importlib by importing needed built-in modules and injecting them + into the global namespace. + + As sys is needed for sys.modules access and _imp is needed to load built-in + modules, those two modules must be explicitly passed in. + + 'b'_thread'b'_warnings'b'_weakref'b'Install importers for builtin and frozen modules'u'Install importers for builtin and frozen modules'b'Install importers that require external filesystem access'u'Install importers that require external filesystem access'u'_bootstrap'Core implementation of path-based import. + +This module is NOT meant to be directly imported! It has been designed such +that it can be bootstrapped into Python as the implementation of import. As +such it requires the injection of specific modules and attributes in order to +work. One should use importlib as the public-facing version of this module. + +_iomarshal_MS_WINDOWSwinregpath_separatorspath_seppath_sep_tuplesetcomp_pathseps_with_colon_CASE_INSENSITIVE_PLATFORMS_STR_KEY_CASE_INSENSITIVE_PLATFORMS_BYTES_KEY_CASE_INSENSITIVE_PLATFORMS_make_relax_casePYTHONCASEOK_relax_caseTrue if filenames must be checked case-insensitively.Convert a 32-bit integer to little-endian.42949672950xFFFFFFFFlittleConvert 4 bytes in little-endian to an integer._unpack_uint16Convert 2 bytes in little-endian to an integer._path_joinpath_partsReplacement for os.path.join().new_root_path_splitroot_path_splitReplacement for os.path.split()._path_statStat the path. + + Made a separate function to make it easier to override in experiments + (e.g. cache stat results). + + _path_is_mode_typeTest whether the path is the specified mode type.stat_info614400o170000_path_isfileReplacement for os.path.isfile.327680o100000_path_isdirReplacement for os.path.isdir.163840o040000_path_isabsReplacement for os.path.isabs.\\_write_atomic4380o666Best-effort function to write data to a path atomically. + Be prepared to handle a FileExistsError if concurrent writing of the + temporary file is attempted.path_tmpO_EXCLFileIO_code_type3413MAGIC_NUMBER_RAW_MAGIC_NUMBER__pycache___PYCACHEopt-_OPTSOURCE_SUFFIXESBYTECODE_SUFFIXESDEBUG_BYTECODE_SUFFIXESOPTIMIZED_BYTECODE_SUFFIXESdebug_overrideGiven the path to a .py file, return the path to its .pyc file. + + The .py file does not need to exist; this simply returns the path to the + .pyc file calculated as if the .py file were imported. + + The 'optimization' parameter controls the presumed optimization level of + the bytecode file. If 'optimization' is not None, the string representation + of the argument is taken and verified to be alphanumeric (else ValueError + is raised). + + The debug_override parameter is deprecated. If debug_override is not None, + a True value is the same as setting 'optimization' to the empty string + while a False value is equivalent to setting 'optimization' to '1'. + + If sys.implementation.cache_tag is None then NotImplementedError is raised. + + the debug_override parameter is deprecated; use 'optimization' instead'the debug_override parameter is deprecated; use '"'optimization' instead"debug_override or optimization must be set to Noneheadrestcache_tagsys.implementation.cache_tag is Nonealmost_filename{!r} is not alphanumeric{}.{}{}source_from_cacheGiven the path to a .pyc. file, return the path to its .py file. + + The .pyc file does not need to exist; this simply returns the path to + the .py file calculated to correspond to the .pyc file. If path does + not conform to PEP 3147/488 format, ValueError will be raised. If + sys.implementation.cache_tag is None then NotImplementedError is raised. + + pycache_filenamefound_in_pycache_prefixstripped_pathpycache not bottom-level directory in ' not bottom-level directory in 'dot_countexpected only 2 or 3 dots in optimization portion of filename does not start with "optimization portion of filename does not start ""with "opt_leveloptimization level is not an alphanumeric value" is not an ""alphanumeric value"base_filename_get_sourcefilebytecode_pathConvert a bytecode file path to a source path (if possible). + + This function exists purely for backwards-compatibility for + PyImport_ExecCodeModuleWithFilenames() in the C API. + + extensionpysource_path_calc_modeCalculate the mode permissions for a bytecode file.0o200_check_nameDecorator to verify that the module being requested matches the one the + loader can handle. + + The first argument (self) must define _name which the second argument is + compared against. If the comparison fails then ImportError is raised. + + _check_name_wrapperloader for %s cannot handle %s_find_module_shimTry to find a loader for the specified module by delegating to + self.find_loader(). + + This method is deprecated in favor of finder.find_spec(). + + portionsNot importing directory {}: missing __init___classify_pycexc_detailsPerform basic validity checking of a pyc header and return the flags field, + which determines how the pyc should be further validated against the source. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required, though.) + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + ImportError is raised when the magic number is incorrect or when the flags + field is invalid. EOFError is raised when the data is found to be truncated. + + magicbad magic number in reached EOF while reading pyc header of 0b11invalid flags in _validate_timestamp_pycsource_mtimesource_sizeValidate a pyc against the source last-modified time. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required.) + + *source_mtime* is the last modified timestamp of the source file. + + *source_size* is None or the size of the source file in bytes. + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + An ImportError is raised if the bytecode is stale. + + bytecode is stale for _validate_hash_pycsource_hashValidate a hash-based pyc by checking the real source hash against the one in + the pyc header. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required.) + + *source_hash* is the importlib.util.source_hash() of the source file. + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + An ImportError is raised if the bytecode is stale. + + hash in bytecode doesn't match hash of source _compile_bytecodeCompile bytecode as found in a pyc.loadscode object from {!r}_fix_co_filenameNon-code object in {!r}_code_to_timestamp_pycmtimeProduce the data for a timestamp-based pyc.dumps_code_to_hash_pyccheckedProduce the data for a hash-based pyc.0b1decode_sourcesource_bytesDecode bytes representing source code and return the string. + + Universal newline support is used in the decoding. + tokenizesource_bytes_readlinedetect_encodingIncrementalNewlineDecodernewline_decoder_POPULATEReturn a module spec based on a file location. + + To indicate that the module is a package, set + submodule_search_locations to a list of directory paths. An + empty list is sufficient, though its not otherwise useful to the + import system. + + The loader must take a spec as its only __init__() arg. + + loader_classsuffixes_get_supported_file_loadersWindowsRegistryFinderMeta path finder for modules declared in the Windows registry.Software\Python\PythonCore\{sys_version}\Modules\{fullname}'Software\\Python\\PythonCore\\{sys_version}''\\Modules\\{fullname}'REGISTRY_KEYSoftware\Python\PythonCore\{sys_version}\Modules\{fullname}\Debug'\\Modules\\{fullname}\\Debug'REGISTRY_KEY_DEBUGDEBUG_BUILD_open_registry_winregOpenKeyHKEY_CURRENT_USERHKEY_LOCAL_MACHINE_search_registryregistry_key%d.%dsys_versionhkeyQueryValuefilepathFind module named in the registry. + + This method is deprecated. Use exec_module() instead. + + _LoaderBasicsBase class of common code needed by both SourceLoader and + SourcelessFileLoader.Concrete implementation of InspectLoader.is_package by checking if + the path returned by get_filename has a filename of '__init__.py'.filename_basetail_nameExecute the module.cannot load module {!r} when get_code() returns None'cannot load module {!r} when get_code() ''returns None'This module is deprecated.SourceLoaderpath_mtimeOptional method that returns the modification time (an int) for the + specified path (a str). + + Raises OSError when the path cannot be handled. + path_statsOptional method returning a metadata dict for the specified + path (a str). + + Possible keys: + - 'mtime' (mandatory) is the numeric timestamp of last source + code modification; + - 'size' (optional) is the size in bytes of the source code. + + Implementing this method allows the loader to read bytecode files. + Raises OSError when the path cannot be handled. + _cache_bytecodecache_pathOptional method which writes data (bytes) to a file path (a str). + + Implementing this method allows for the writing of bytecode files. + + The source path is needed in order to correctly transfer permissions + set_dataOptional method which writes data (bytes) to a file path (a str). + + Implementing this method allows for the writing of bytecode files. + Concrete implementation of InspectLoader.get_source.source not available through get_data()source_to_code_optimizeReturn the code object compiled from source. + + The 'data' argument can be any object type that compile() supports. + dont_inheritConcrete implementation of InspectLoader.get_code. + + Reading of bytecode requires path_stats to be implemented. To write + bytecode, set_data must also be implemented. + + hash_basedcheck_sourcestbytes_data0b10check_hash_based_pycsnever{} matches {}code_objectcode object from {}FileLoaderBase file loader class which implements the loader protocol methods that + require file system usage.Cache the module name and the path to the file found by the + finder.Load a module from a file. + + This method is deprecated. Use exec_module() instead. + + Return the path to the source file as found by the finder.Return the data from path as raw bytes.ExtensionFileLoaderopen_codeSourceFileLoaderConcrete implementation of SourceLoader using the file system.Return the metadata for the path.st_mtimest_size_modeWrite bytes data to a file.could not create {!r}: {!r}created {!r}SourcelessFileLoaderLoader which handles sourceless file imports.Return None as there is no source code.EXTENSION_SUFFIXESLoader for extension modules. + + The constructor is designed to work with FileFinder. + + Create an unitialized extension modulecreate_dynamicextension module {!r} loaded from {!r}Initialize an extension moduleexec_dynamicextension module {!r} executed from {!r}Return True if the extension module is a package.file_nameReturn None as an extension module cannot create a code object.Return None as extension modules have no source code._NamespacePathRepresents a namespace package's path. It uses the module name + to find its parent module, and from there it looks up the parent's + __path__. When this changes, the module's own path is recomputed, + using path_finder. For top-level modules, the parent module's path + is sys.path.path_finder_get_parent_path_last_parent_path_path_finder_find_parent_path_namesReturns a tuple of (parent-module-name, parent-path-attr-name)dotparent_module_namepath_attr_name_recalculateparent_path_NamespacePath({!r})Load a namespace module. + + This method is deprecated. Use exec_module() instead. + + namespace module loaded with path {!r}PathFinderMeta path finder for sys.path and package __path__ attributes.Call the invalidate_caches() method on all path entry finders + stored in sys.path_importer_caches (where implemented).Search sys.path_hooks for a finder for 'path'.sys.path_hooks is emptyhookGet the finder for the path entry from sys.path_importer_cache. + + If the path entry is not in the cache, find the appropriate finder + and cache it. If no finder is available, store None. + + Find the loader or namespace_path for this module/package name.namespace_pathspec missing loaderTry to find a spec for 'fullname' on sys.path or 'path'. + + The search is based on sys.path_hooks and sys.path_importer_cache. + find the module on sys.path or 'path' based on sys.path_hooks and + sys.path_importer_cache. + + This method is deprecated. Use find_spec() instead. + + + Find distributions. + + Return an iterable of all Distribution instances capable of + loading the metadata for packages matching ``context.name`` + (or all names if ``None`` indicated) along the paths in the list + of directories ``context.path``. + importlib.metadataMetadataPathFinderFileFinderFile-based finder. + + Interactions with the file system are cached for performance, being + refreshed when the directory the finder is handling has been modified. + + loader_detailsInitialize with the path to search on and a variable number of + 2-tuples containing the loader and the file suffixes the loader + recognizes.loaders_loaders_path_mtime_path_cache_relaxed_path_cacheInvalidate the directory mtime.Try to find a loader for the specified module, or the namespace + package portions. Returns (loader, list-of-portions). + + This method is deprecated. Use find_spec() instead. + + Try to find a spec for the specified module. + + Returns the matching spec, or None if not found. + is_namespacetail_module_fill_cachecachecache_moduleinit_filenamefull_pathtrying {}possible namespace for {}Fill the cache of potential modules and packages for this directory.lower_suffix_contentsnew_namepath_hookA class method which returns a closure to use on sys.path_hook + which will return an instance using the specified loaders and the path + called on the closure. + + If the path called on the closure is not a directory, ImportError is + raised. + + Path hook for importlib.machinery.FileFinder.only directories are supportedFileFinder({!r})_fix_up_modulecpathnameReturns a list of file-based module loaders. + + Each item is a tuple (loader, suffixes). + extension_suffixesextensionsbytecode_bootstrap_moduleSetup the path-based importers for importlib by importing needed + built-in modules and injecting them into the global namespace. + + Other components are extracted from the core bootstrap module. + + os_detailsbuiltin_osos_moduleimportlib requires posix or ntthread_moduleweakref_modulewinreg_module.pyw_d.pydInstall the path-based import components.supported_loaders# all others who don't have a ./python around to freeze the module in the early# stages of compilation.# Import builtin modules# Assumption made in _path_join()# Drive relative paths have to be resolved by the OS, so we reset the# tail but do not add a path_sep prefix.# Avoid losing the root's trailing separator when joining with nothing# id() is used to generate a pseudo-random filename.# We first write data to a temporary file, and then use os.replace() to# perform an atomic rename.# Finder/loader utility code ################################################ Magic word to reject .pyc files generated by other Python versions.# It should change for each incompatible change to the bytecode.# The value of CR and LF is incorporated so if you ever read or write# a .pyc file in text mode the magic number will be wrong; also, the# Apple MPW compiler swaps their values, botching string constants.# There were a variety of old schemes for setting the magic number.# The current working scheme is to increment the previous value by# 10.# Starting with the adoption of PEP 3147 in Python 3.2, every bump in magic# number also includes a new "magic tag", i.e. a human readable string used# to represent the magic number in __pycache__ directories. When you change# the magic number, you must also set a new unique magic tag. Generally this# can be named after the Python major version of the magic number bump, but# it can really be anything, as long as it's different than anything else# that's come before. The tags are included in the following table, starting# with Python 3.2a0.# Known values:# Python 1.5: 20121# Python 1.5.1: 20121# Python 1.5.2: 20121# Python 1.6: 50428# Python 2.0: 50823# Python 2.0.1: 50823# Python 2.1: 60202# Python 2.1.1: 60202# Python 2.1.2: 60202# Python 2.2: 60717# Python 2.3a0: 62011# Python 2.3a0: 62021# Python 2.3a0: 62011 (!)# Python 2.4a0: 62041# Python 2.4a3: 62051# Python 2.4b1: 62061# Python 2.5a0: 62071# Python 2.5a0: 62081 (ast-branch)# Python 2.5a0: 62091 (with)# Python 2.5a0: 62092 (changed WITH_CLEANUP opcode)# Python 2.5b3: 62101 (fix wrong code: for x, in ...)# Python 2.5b3: 62111 (fix wrong code: x += yield)# Python 2.5c1: 62121 (fix wrong lnotab with for loops and# storing constants that should have been removed)# Python 2.5c2: 62131 (fix wrong code: for x, in ... in listcomp/genexp)# Python 2.6a0: 62151 (peephole optimizations and STORE_MAP opcode)# Python 2.6a1: 62161 (WITH_CLEANUP optimization)# Python 2.7a0: 62171 (optimize list comprehensions/change LIST_APPEND)# Python 2.7a0: 62181 (optimize conditional branches:# introduce POP_JUMP_IF_FALSE and POP_JUMP_IF_TRUE)# Python 2.7a0 62191 (introduce SETUP_WITH)# Python 2.7a0 62201 (introduce BUILD_SET)# Python 2.7a0 62211 (introduce MAP_ADD and SET_ADD)# Python 3000: 3000# 3010 (removed UNARY_CONVERT)# 3020 (added BUILD_SET)# 3030 (added keyword-only parameters)# 3040 (added signature annotations)# 3050 (print becomes a function)# 3060 (PEP 3115 metaclass syntax)# 3061 (string literals become unicode)# 3071 (PEP 3109 raise changes)# 3081 (PEP 3137 make __file__ and __name__ unicode)# 3091 (kill str8 interning)# 3101 (merge from 2.6a0, see 62151)# 3103 (__file__ points to source file)# Python 3.0a4: 3111 (WITH_CLEANUP optimization).# Python 3.0b1: 3131 (lexical exception stacking, including POP_EXCEPT#3021)# Python 3.1a1: 3141 (optimize list, set and dict comprehensions:# change LIST_APPEND and SET_ADD, add MAP_ADD #2183)# Python 3.1a1: 3151 (optimize conditional branches:# introduce POP_JUMP_IF_FALSE and POP_JUMP_IF_TRUE#4715)# Python 3.2a1: 3160 (add SETUP_WITH #6101)# tag: cpython-32# Python 3.2a2: 3170 (add DUP_TOP_TWO, remove DUP_TOPX and ROT_FOUR #9225)# Python 3.2a3 3180 (add DELETE_DEREF #4617)# Python 3.3a1 3190 (__class__ super closure changed)# Python 3.3a1 3200 (PEP 3155 __qualname__ added #13448)# Python 3.3a1 3210 (added size modulo 2**32 to the pyc header #13645)# Python 3.3a2 3220 (changed PEP 380 implementation #14230)# Python 3.3a4 3230 (revert changes to implicit __class__ closure #14857)# Python 3.4a1 3250 (evaluate positional default arguments before# keyword-only defaults #16967)# Python 3.4a1 3260 (add LOAD_CLASSDEREF; allow locals of class to override# free vars #17853)# Python 3.4a1 3270 (various tweaks to the __class__ closure #12370)# Python 3.4a1 3280 (remove implicit class argument)# Python 3.4a4 3290 (changes to __qualname__ computation #19301)# Python 3.4a4 3300 (more changes to __qualname__ computation #19301)# Python 3.4rc2 3310 (alter __qualname__ computation #20625)# Python 3.5a1 3320 (PEP 465: Matrix multiplication operator #21176)# Python 3.5b1 3330 (PEP 448: Additional Unpacking Generalizations #2292)# Python 3.5b2 3340 (fix dictionary display evaluation order #11205)# Python 3.5b3 3350 (add GET_YIELD_FROM_ITER opcode #24400)# Python 3.5.2 3351 (fix BUILD_MAP_UNPACK_WITH_CALL opcode #27286)# Python 3.6a0 3360 (add FORMAT_VALUE opcode #25483)# Python 3.6a1 3361 (lineno delta of code.co_lnotab becomes signed #26107)# Python 3.6a2 3370 (16 bit wordcode #26647)# Python 3.6a2 3371 (add BUILD_CONST_KEY_MAP opcode #27140)# Python 3.6a2 3372 (MAKE_FUNCTION simplification, remove MAKE_CLOSURE# #27095)# Python 3.6b1 3373 (add BUILD_STRING opcode #27078)# Python 3.6b1 3375 (add SETUP_ANNOTATIONS and STORE_ANNOTATION opcodes# #27985)# Python 3.6b1 3376 (simplify CALL_FUNCTIONs & BUILD_MAP_UNPACK_WITH_CALL#27213)# Python 3.6b1 3377 (set __class__ cell from type.__new__ #23722)# Python 3.6b2 3378 (add BUILD_TUPLE_UNPACK_WITH_CALL #28257)# Python 3.6rc1 3379 (more thorough __class__ validation #23722)# Python 3.7a1 3390 (add LOAD_METHOD and CALL_METHOD opcodes #26110)# Python 3.7a2 3391 (update GET_AITER #31709)# Python 3.7a4 3392 (PEP 552: Deterministic pycs #31650)# Python 3.7b1 3393 (remove STORE_ANNOTATION opcode #32550)# Python 3.7b5 3394 (restored docstring as the first stmt in the body;# this might affected the first line number #32911)# Python 3.8a1 3400 (move frame block handling to compiler #17611)# Python 3.8a1 3401 (add END_ASYNC_FOR #33041)# Python 3.8a1 3410 (PEP570 Python Positional-Only Parameters #36540)# Python 3.8b2 3411 (Reverse evaluation order of key: value in dict# comprehensions #35224)# Python 3.8b2 3412 (Swap the position of positional args and positional# only args in ast.arguments #37593)# Python 3.8b4 3413 (Fix "break" and "continue" in "finally" #37830)# MAGIC must change whenever the bytecode emitted by the compiler may no# longer be understood by older implementations of the eval loop (usually# due to the addition of new opcodes).# Whenever MAGIC_NUMBER is changed, the ranges in the magic_values array# in PC/launcher.c must also be updated.# For import.c# _setup() adds .pyw as needed.# Deprecated.# We need an absolute path to the py file to avoid the possibility of# collisions within sys.pycache_prefix, if someone has two different# `foo/bar.py` on their system and they import both of them using the# same sys.pycache_prefix. Let's say sys.pycache_prefix is# `C:\Bytecode`; the idea here is that if we get `Foo\Bar`, we first# make it absolute (`C:\Somewhere\Foo\Bar`), then make it root-relative# (`Somewhere\Foo\Bar`), so we end up placing the bytecode file in an# unambiguous `C:\Bytecode\Somewhere\Foo\Bar\`.# Strip initial drive from a Windows path. We know we have an absolute# path here, so the second part of the check rules out a POSIX path that# happens to contain a colon at the second character.# Strip initial path separator from `head` to complete the conversion# back to a root-relative path before joining.# We always ensure write access so we can update cached files# later even when the source files are read-only on Windows (#6074)# XXX yuck# Call find_loader(). If it returns a string (indicating this# is a namespace package portion), generate a warning and# return None.# Only the first two flags are defined.# To avoid bootstrap issues.# The caller may simply want a partially populated location-# oriented spec. So we set the location to a bogus value and# fill in as much as we can.# ExecutionLoader# If the location is on the filesystem, but doesn't actually exist,# we could return None here, indicating that the location is not# valid. However, we don't have a good way of testing since an# indirect location (e.g. a zip file or URL) will look like a# non-existent file relative to the filesystem.# Pick a loader if one wasn't provided.# Set submodule_search_paths appropriately.# Check the loader.# Changed in _setup()# For backwards compatibility, we delegate to set_data()# The only reason for this method is for the name check.# Issue #14857: Avoid the zero-argument form of super so the implementation# of that form can be updated without breaking the frozen module# ResourceReader ABC API.# Adapt between the two APIs# Figure out what directories are missing.# Create needed directories.# Probably another Python process already created the dir.# Could be a permission error, read-only filesystem: just forget# about writing the data.# Same as above: just don't write the bytecode.# Call _classify_pyc to do basic validation of the pyc but ignore the# result. There's no source to check against.# Filled in by _setup().# This is a top-level module. sys.path contains the parent path.# Not a top-level module. parent-module.__path__ contains the# parent path.# If the parent's path has changed, recalculate _path# Make a copy# Note that no changes are made if a loader is returned, but we# do remember the new parent path# Save the copy# We use this exclusively in module_from_spec() for backward-compatibility.# The import system never calls this method.# Finders ###################################################################### Don't cache the failure as the cwd can easily change to# a valid directory later on.# If this ends up being a namespace package, namespace_path is# the list of paths that will become its __path__# This is possibly part of a namespace package.# Remember these path entries (if any) for when we# create a namespace package, and continue iterating# on path.# We found at least one namespace path. Return a spec which# can create the namespace package.# Base (directory) path# tail_module keeps the original casing, for __file__ and friends# Check if the module is the name of a directory (and thus a package).# If a namespace package, return the path if we don't# find a module in the next section.# Check for a file w/ a proper suffix exists.# Directory has either been removed, turned into a file, or made# unreadable.# We store two cached versions, to handle runtime changes of the# PYTHONCASEOK environment variable.# Windows users can import modules with case-insensitive file# suffixes (for legacy reasons). Make the suffix lowercase here# so it's done once instead of for every import. This is safe as# the specified suffixes to check against are always specified in a# case-sensitive manner.# Import setup ################################################################ This function is used by PyImport_ExecCodeModuleObject().# Not important enough to report.# Directly load the os module (needed during bootstrap).# Directly load the _thread module (needed during bootstrap).# Directly load the _weakref module (needed during bootstrap).# Directly load the winreg module (needed during bootstrap).# Constantsb'Core implementation of path-based import. + +This module is NOT meant to be directly imported! It has been designed such +that it can be bootstrapped into Python as the implementation of import. As +such it requires the injection of specific modules and attributes in order to +work. One should use importlib as the public-facing version of this module. + +'u'Core implementation of path-based import. + +This module is NOT meant to be directly imported! It has been designed such +that it can be bootstrapped into Python as the implementation of import. As +such it requires the injection of specific modules and attributes in order to +work. One should use importlib as the public-facing version of this module. + +'b'PYTHONCASEOK'u'PYTHONCASEOK'b'True if filenames must be checked case-insensitively.'u'True if filenames must be checked case-insensitively.'b'Convert a 32-bit integer to little-endian.'u'Convert a 32-bit integer to little-endian.'b'little'b'Convert 4 bytes in little-endian to an integer.'u'Convert 4 bytes in little-endian to an integer.'b'Convert 2 bytes in little-endian to an integer.'u'Convert 2 bytes in little-endian to an integer.'b'Replacement for os.path.join().'u'Replacement for os.path.join().'b'Replacement for os.path.split().'u'Replacement for os.path.split().'b'Stat the path. + + Made a separate function to make it easier to override in experiments + (e.g. cache stat results). + + 'u'Stat the path. + + Made a separate function to make it easier to override in experiments + (e.g. cache stat results). + + 'b'Test whether the path is the specified mode type.'u'Test whether the path is the specified mode type.'b'Replacement for os.path.isfile.'u'Replacement for os.path.isfile.'b'Replacement for os.path.isdir.'u'Replacement for os.path.isdir.'b'Replacement for os.path.isabs.'u'Replacement for os.path.isabs.'b'\\'u'\\'b'Best-effort function to write data to a path atomically. + Be prepared to handle a FileExistsError if concurrent writing of the + temporary file is attempted.'u'Best-effort function to write data to a path atomically. + Be prepared to handle a FileExistsError if concurrent writing of the + temporary file is attempted.'b'__pycache__'u'__pycache__'b'opt-'u'opt-'b'Given the path to a .py file, return the path to its .pyc file. + + The .py file does not need to exist; this simply returns the path to the + .pyc file calculated as if the .py file were imported. + + The 'optimization' parameter controls the presumed optimization level of + the bytecode file. If 'optimization' is not None, the string representation + of the argument is taken and verified to be alphanumeric (else ValueError + is raised). + + The debug_override parameter is deprecated. If debug_override is not None, + a True value is the same as setting 'optimization' to the empty string + while a False value is equivalent to setting 'optimization' to '1'. + + If sys.implementation.cache_tag is None then NotImplementedError is raised. + + 'u'Given the path to a .py file, return the path to its .pyc file. + + The .py file does not need to exist; this simply returns the path to the + .pyc file calculated as if the .py file were imported. + + The 'optimization' parameter controls the presumed optimization level of + the bytecode file. If 'optimization' is not None, the string representation + of the argument is taken and verified to be alphanumeric (else ValueError + is raised). + + The debug_override parameter is deprecated. If debug_override is not None, + a True value is the same as setting 'optimization' to the empty string + while a False value is equivalent to setting 'optimization' to '1'. + + If sys.implementation.cache_tag is None then NotImplementedError is raised. + + 'b'the debug_override parameter is deprecated; use 'optimization' instead'u'the debug_override parameter is deprecated; use 'optimization' instead'b'debug_override or optimization must be set to None'u'debug_override or optimization must be set to None'b'sys.implementation.cache_tag is None'u'sys.implementation.cache_tag is None'b'{!r} is not alphanumeric'u'{!r} is not alphanumeric'b'{}.{}{}'u'{}.{}{}'b'Given the path to a .pyc. file, return the path to its .py file. + + The .pyc file does not need to exist; this simply returns the path to + the .py file calculated to correspond to the .pyc file. If path does + not conform to PEP 3147/488 format, ValueError will be raised. If + sys.implementation.cache_tag is None then NotImplementedError is raised. + + 'u'Given the path to a .pyc. file, return the path to its .py file. + + The .pyc file does not need to exist; this simply returns the path to + the .py file calculated to correspond to the .pyc file. If path does + not conform to PEP 3147/488 format, ValueError will be raised. If + sys.implementation.cache_tag is None then NotImplementedError is raised. + + 'b' not bottom-level directory in 'u' not bottom-level directory in 'b'expected only 2 or 3 dots in 'u'expected only 2 or 3 dots in 'b'optimization portion of filename does not start with 'u'optimization portion of filename does not start with 'b'optimization level 'u'optimization level 'b' is not an alphanumeric value'u' is not an alphanumeric value'b'Convert a bytecode file path to a source path (if possible). + + This function exists purely for backwards-compatibility for + PyImport_ExecCodeModuleWithFilenames() in the C API. + + 'u'Convert a bytecode file path to a source path (if possible). + + This function exists purely for backwards-compatibility for + PyImport_ExecCodeModuleWithFilenames() in the C API. + + 'b'py'u'py'b'Calculate the mode permissions for a bytecode file.'u'Calculate the mode permissions for a bytecode file.'b'Decorator to verify that the module being requested matches the one the + loader can handle. + + The first argument (self) must define _name which the second argument is + compared against. If the comparison fails then ImportError is raised. + + 'u'Decorator to verify that the module being requested matches the one the + loader can handle. + + The first argument (self) must define _name which the second argument is + compared against. If the comparison fails then ImportError is raised. + + 'b'loader for %s cannot handle %s'u'loader for %s cannot handle %s'b'Try to find a loader for the specified module by delegating to + self.find_loader(). + + This method is deprecated in favor of finder.find_spec(). + + 'u'Try to find a loader for the specified module by delegating to + self.find_loader(). + + This method is deprecated in favor of finder.find_spec(). + + 'b'Not importing directory {}: missing __init__'u'Not importing directory {}: missing __init__'b'Perform basic validity checking of a pyc header and return the flags field, + which determines how the pyc should be further validated against the source. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required, though.) + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + ImportError is raised when the magic number is incorrect or when the flags + field is invalid. EOFError is raised when the data is found to be truncated. + + 'u'Perform basic validity checking of a pyc header and return the flags field, + which determines how the pyc should be further validated against the source. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required, though.) + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + ImportError is raised when the magic number is incorrect or when the flags + field is invalid. EOFError is raised when the data is found to be truncated. + + 'b'bad magic number in 'u'bad magic number in 'b'reached EOF while reading pyc header of 'u'reached EOF while reading pyc header of 'b'invalid flags 'u'invalid flags 'b' in 'u' in 'b'Validate a pyc against the source last-modified time. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required.) + + *source_mtime* is the last modified timestamp of the source file. + + *source_size* is None or the size of the source file in bytes. + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + An ImportError is raised if the bytecode is stale. + + 'u'Validate a pyc against the source last-modified time. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required.) + + *source_mtime* is the last modified timestamp of the source file. + + *source_size* is None or the size of the source file in bytes. + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + An ImportError is raised if the bytecode is stale. + + 'b'bytecode is stale for 'u'bytecode is stale for 'b'Validate a hash-based pyc by checking the real source hash against the one in + the pyc header. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required.) + + *source_hash* is the importlib.util.source_hash() of the source file. + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + An ImportError is raised if the bytecode is stale. + + 'u'Validate a hash-based pyc by checking the real source hash against the one in + the pyc header. + + *data* is the contents of the pyc file. (Only the first 16 bytes are + required.) + + *source_hash* is the importlib.util.source_hash() of the source file. + + *name* is the name of the module being imported. It is used for logging. + + *exc_details* is a dictionary passed to ImportError if it raised for + improved debugging. + + An ImportError is raised if the bytecode is stale. + + 'b'hash in bytecode doesn't match hash of source 'u'hash in bytecode doesn't match hash of source 'b'Compile bytecode as found in a pyc.'u'Compile bytecode as found in a pyc.'b'code object from {!r}'u'code object from {!r}'b'Non-code object in {!r}'u'Non-code object in {!r}'b'Produce the data for a timestamp-based pyc.'u'Produce the data for a timestamp-based pyc.'b'Produce the data for a hash-based pyc.'u'Produce the data for a hash-based pyc.'b'Decode bytes representing source code and return the string. + + Universal newline support is used in the decoding. + 'u'Decode bytes representing source code and return the string. + + Universal newline support is used in the decoding. + 'b'Return a module spec based on a file location. + + To indicate that the module is a package, set + submodule_search_locations to a list of directory paths. An + empty list is sufficient, though its not otherwise useful to the + import system. + + The loader must take a spec as its only __init__() arg. + + 'u'Return a module spec based on a file location. + + To indicate that the module is a package, set + submodule_search_locations to a list of directory paths. An + empty list is sufficient, though its not otherwise useful to the + import system. + + The loader must take a spec as its only __init__() arg. + + 'b''u''b'Meta path finder for modules declared in the Windows registry.'u'Meta path finder for modules declared in the Windows registry.'b'Software\Python\PythonCore\{sys_version}\Modules\{fullname}'u'Software\Python\PythonCore\{sys_version}\Modules\{fullname}'b'Software\Python\PythonCore\{sys_version}\Modules\{fullname}\Debug'u'Software\Python\PythonCore\{sys_version}\Modules\{fullname}\Debug'b'%d.%d'u'%d.%d'b'Find module named in the registry. + + This method is deprecated. Use exec_module() instead. + + 'u'Find module named in the registry. + + This method is deprecated. Use exec_module() instead. + + 'b'Base class of common code needed by both SourceLoader and + SourcelessFileLoader.'u'Base class of common code needed by both SourceLoader and + SourcelessFileLoader.'b'Concrete implementation of InspectLoader.is_package by checking if + the path returned by get_filename has a filename of '__init__.py'.'u'Concrete implementation of InspectLoader.is_package by checking if + the path returned by get_filename has a filename of '__init__.py'.'b'__init__'b'Execute the module.'u'Execute the module.'b'cannot load module {!r} when get_code() returns None'u'cannot load module {!r} when get_code() returns None'b'This module is deprecated.'u'This module is deprecated.'b'Optional method that returns the modification time (an int) for the + specified path (a str). + + Raises OSError when the path cannot be handled. + 'u'Optional method that returns the modification time (an int) for the + specified path (a str). + + Raises OSError when the path cannot be handled. + 'b'Optional method returning a metadata dict for the specified + path (a str). + + Possible keys: + - 'mtime' (mandatory) is the numeric timestamp of last source + code modification; + - 'size' (optional) is the size in bytes of the source code. + + Implementing this method allows the loader to read bytecode files. + Raises OSError when the path cannot be handled. + 'u'Optional method returning a metadata dict for the specified + path (a str). + + Possible keys: + - 'mtime' (mandatory) is the numeric timestamp of last source + code modification; + - 'size' (optional) is the size in bytes of the source code. + + Implementing this method allows the loader to read bytecode files. + Raises OSError when the path cannot be handled. + 'b'mtime'u'mtime'b'Optional method which writes data (bytes) to a file path (a str). + + Implementing this method allows for the writing of bytecode files. + + The source path is needed in order to correctly transfer permissions + 'u'Optional method which writes data (bytes) to a file path (a str). + + Implementing this method allows for the writing of bytecode files. + + The source path is needed in order to correctly transfer permissions + 'b'Optional method which writes data (bytes) to a file path (a str). + + Implementing this method allows for the writing of bytecode files. + 'u'Optional method which writes data (bytes) to a file path (a str). + + Implementing this method allows for the writing of bytecode files. + 'b'Concrete implementation of InspectLoader.get_source.'u'Concrete implementation of InspectLoader.get_source.'b'source not available through get_data()'u'source not available through get_data()'b'Return the code object compiled from source. + + The 'data' argument can be any object type that compile() supports. + 'u'Return the code object compiled from source. + + The 'data' argument can be any object type that compile() supports. + 'b'Concrete implementation of InspectLoader.get_code. + + Reading of bytecode requires path_stats to be implemented. To write + bytecode, set_data must also be implemented. + + 'u'Concrete implementation of InspectLoader.get_code. + + Reading of bytecode requires path_stats to be implemented. To write + bytecode, set_data must also be implemented. + + 'b'path'u'path'b'never'u'never'b'{} matches {}'u'{} matches {}'b'code object from {}'u'code object from {}'b'Base file loader class which implements the loader protocol methods that + require file system usage.'b'Cache the module name and the path to the file found by the + finder.'u'Cache the module name and the path to the file found by the + finder.'b'Load a module from a file. + + This method is deprecated. Use exec_module() instead. + + 'u'Load a module from a file. + + This method is deprecated. Use exec_module() instead. + + 'b'Return the path to the source file as found by the finder.'u'Return the path to the source file as found by the finder.'b'Return the data from path as raw bytes.'u'Return the data from path as raw bytes.'b'Concrete implementation of SourceLoader using the file system.'u'Concrete implementation of SourceLoader using the file system.'b'Return the metadata for the path.'u'Return the metadata for the path.'b'Write bytes data to a file.'u'Write bytes data to a file.'b'could not create {!r}: {!r}'u'could not create {!r}: {!r}'b'created {!r}'u'created {!r}'b'Loader which handles sourceless file imports.'u'Loader which handles sourceless file imports.'b'Return None as there is no source code.'u'Return None as there is no source code.'b'Loader for extension modules. + + The constructor is designed to work with FileFinder. + + 'b'Create an unitialized extension module'u'Create an unitialized extension module'b'extension module {!r} loaded from {!r}'u'extension module {!r} loaded from {!r}'b'Initialize an extension module'u'Initialize an extension module'b'extension module {!r} executed from {!r}'u'extension module {!r} executed from {!r}'b'Return True if the extension module is a package.'u'Return True if the extension module is a package.'b'Return None as an extension module cannot create a code object.'u'Return None as an extension module cannot create a code object.'b'Return None as extension modules have no source code.'u'Return None as extension modules have no source code.'b'Represents a namespace package's path. It uses the module name + to find its parent module, and from there it looks up the parent's + __path__. When this changes, the module's own path is recomputed, + using path_finder. For top-level modules, the parent module's path + is sys.path.'u'Represents a namespace package's path. It uses the module name + to find its parent module, and from there it looks up the parent's + __path__. When this changes, the module's own path is recomputed, + using path_finder. For top-level modules, the parent module's path + is sys.path.'b'Returns a tuple of (parent-module-name, parent-path-attr-name)'u'Returns a tuple of (parent-module-name, parent-path-attr-name)'b'sys'b'_NamespacePath({!r})'u'_NamespacePath({!r})'b''u''b''u''b'Load a namespace module. + + This method is deprecated. Use exec_module() instead. + + 'u'Load a namespace module. + + This method is deprecated. Use exec_module() instead. + + 'b'namespace module loaded with path {!r}'u'namespace module loaded with path {!r}'b'Meta path finder for sys.path and package __path__ attributes.'b'Call the invalidate_caches() method on all path entry finders + stored in sys.path_importer_caches (where implemented).'u'Call the invalidate_caches() method on all path entry finders + stored in sys.path_importer_caches (where implemented).'b'Search sys.path_hooks for a finder for 'path'.'u'Search sys.path_hooks for a finder for 'path'.'b'sys.path_hooks is empty'u'sys.path_hooks is empty'b'Get the finder for the path entry from sys.path_importer_cache. + + If the path entry is not in the cache, find the appropriate finder + and cache it. If no finder is available, store None. + + 'u'Get the finder for the path entry from sys.path_importer_cache. + + If the path entry is not in the cache, find the appropriate finder + and cache it. If no finder is available, store None. + + 'b'find_loader'u'find_loader'b'Find the loader or namespace_path for this module/package name.'u'Find the loader or namespace_path for this module/package name.'b'find_spec'u'find_spec'b'spec missing loader'u'spec missing loader'b'Try to find a spec for 'fullname' on sys.path or 'path'. + + The search is based on sys.path_hooks and sys.path_importer_cache. + 'u'Try to find a spec for 'fullname' on sys.path or 'path'. + + The search is based on sys.path_hooks and sys.path_importer_cache. + 'b'find the module on sys.path or 'path' based on sys.path_hooks and + sys.path_importer_cache. + + This method is deprecated. Use find_spec() instead. + + 'u'find the module on sys.path or 'path' based on sys.path_hooks and + sys.path_importer_cache. + + This method is deprecated. Use find_spec() instead. + + 'b' + Find distributions. + + Return an iterable of all Distribution instances capable of + loading the metadata for packages matching ``context.name`` + (or all names if ``None`` indicated) along the paths in the list + of directories ``context.path``. + 'u' + Find distributions. + + Return an iterable of all Distribution instances capable of + loading the metadata for packages matching ``context.name`` + (or all names if ``None`` indicated) along the paths in the list + of directories ``context.path``. + 'b'File-based finder. + + Interactions with the file system are cached for performance, being + refreshed when the directory the finder is handling has been modified. + + 'u'File-based finder. + + Interactions with the file system are cached for performance, being + refreshed when the directory the finder is handling has been modified. + + 'b'Initialize with the path to search on and a variable number of + 2-tuples containing the loader and the file suffixes the loader + recognizes.'u'Initialize with the path to search on and a variable number of + 2-tuples containing the loader and the file suffixes the loader + recognizes.'b'Invalidate the directory mtime.'u'Invalidate the directory mtime.'b'Try to find a loader for the specified module, or the namespace + package portions. Returns (loader, list-of-portions). + + This method is deprecated. Use find_spec() instead. + + 'u'Try to find a loader for the specified module, or the namespace + package portions. Returns (loader, list-of-portions). + + This method is deprecated. Use find_spec() instead. + + 'b'Try to find a spec for the specified module. + + Returns the matching spec, or None if not found. + 'u'Try to find a spec for the specified module. + + Returns the matching spec, or None if not found. + 'b'trying {}'u'trying {}'b'possible namespace for {}'u'possible namespace for {}'b'Fill the cache of potential modules and packages for this directory.'u'Fill the cache of potential modules and packages for this directory.'b'A class method which returns a closure to use on sys.path_hook + which will return an instance using the specified loaders and the path + called on the closure. + + If the path called on the closure is not a directory, ImportError is + raised. + + 'u'A class method which returns a closure to use on sys.path_hook + which will return an instance using the specified loaders and the path + called on the closure. + + If the path called on the closure is not a directory, ImportError is + raised. + + 'b'Path hook for importlib.machinery.FileFinder.'u'Path hook for importlib.machinery.FileFinder.'b'only directories are supported'u'only directories are supported'b'FileFinder({!r})'u'FileFinder({!r})'b'Returns a list of file-based module loaders. + + Each item is a tuple (loader, suffixes). + 'u'Returns a list of file-based module loaders. + + Each item is a tuple (loader, suffixes). + 'b'Setup the path-based importers for importlib by importing needed + built-in modules and injecting them into the global namespace. + + Other components are extracted from the core bootstrap module. + + 'u'Setup the path-based importers for importlib by importing needed + built-in modules and injecting them into the global namespace. + + Other components are extracted from the core bootstrap module. + + 'b'_io'b'builtins'b'marshal'b'importlib requires posix or nt'u'importlib requires posix or nt'b'_os'u'_os'b'path_sep'u'path_sep'b'path_separators'u'path_separators'b'_pathseps_with_colon'u'_pathseps_with_colon'b'winreg'u'winreg'b'_winreg'u'_winreg'b'_relax_case'u'_relax_case'b'.pyw'u'.pyw'b'_d.pyd'u'_d.pyd'b'Install the path-based import components.'u'Install the path-based import components.'u'_bootstrap_external'u'Create a compressor object for compressing data incrementally. + + compresslevel + Compression level, as a number between 1 and 9. + +For one-shot compression, use the compress() function instead.'compress_bz2.BZ2CompressorBZ2Compressoru'Create a decompressor object for decompressing data incrementally. + +For one-shot decompression, use the decompress() function instead.'decompresseofneeds_inputunused_data_bz2.BZ2DecompressorBZ2Decompressoru'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_bz2.cpython-38-darwin.so'u'_bz2'_bz2_forget_codecascii_decodeascii_encodecharmap_buildcharmap_decodecharmap_encodeescape_decodeescape_encodelatin_1_decodelatin_1_encodelookuplookup_errorraw_unicode_escape_decoderaw_unicode_escape_encodereadbuffer_encoderegister_errorunicode_escape_decodeunicode_escape_encodeutf_16_be_decodeutf_16_be_encodeutf_16_decodeutf_16_encodeutf_16_ex_decodeutf_16_le_decodeutf_16_le_encodeutf_32_be_decodeutf_32_be_encodeutf_32_decodeutf_32_encodeutf_32_ex_decodeutf_32_le_decodeutf_32_le_encodeutf_7_decodeutf_7_encodeutf_8_decodeutf_8_encode_codecsu'OrderedDict.__dict__'collections.OrderedDictu'High performance data structures. +- deque: ordered collection accessible from endpoints only +- defaultdict: dict subclass with a default value factory +'_collections._deque_iterator_deque_iterator_collections._deque_reverse_iterator_deque_reverse_iterator_collections._tuplegetteru'defaultdict(default_factory[, ...]) --> dict with default factory + +The default factory is called without arguments to produce +a new value when a key is not present, in __getitem__ only. +A defaultdict compares equal to a dict with the same items. +All remaining arguments are treated the same as if they were +passed to the dict constructor, including keyword arguments. +'default_factorycollections.defaultdictu'deque([iterable[, maxlen]]) --> deque object + +A list-like sequence optimized for data accesses near its endpoints.'appendleftextendleftu'maximum size of a deque or None if unbounded'u'deque.maxlen'maxlenrotatecollections.dequeAbstract Base Classes (ABCs) for collections, according to PEP 3119. + +Unit tests are in test_collections. +ABCMetaabstractmethodAwaitableCoroutineAsyncIterableAsyncIteratorAsyncGeneratorHashableIterableGeneratorReversibleSizedContainerCallableCollectionMutableSetMappingViewByteStringbytes_iteratorbytearray_iteratordict_keyiteratordict_valueiteratordict_itemiteratorlist_iteratorlist_reverseiteratorrange_iteratorlongrange_iteratorset_iteratorstr_iteratortuple_iteratorzip_iteratordict_keysdict_valuesdict_itemsmappingproxycoroutine_agasync_generator_check_methodsCmethodsmetaclassSend a value into the coroutine. + Return next yielded value or raise StopIteration. + Raise an exception in the coroutine. + Return next yielded value or raise StopIteration. + Raise GeneratorExit inside coroutine. + coroutine ignored GeneratorExit__aiter____anext__Return the next item or raise StopAsyncIteration when exhausted.Return the next item from the asynchronous generator. + When exhausted, raise StopAsyncIteration. + asendSend a value into the asynchronous generator. + Return next yielded value or raise StopAsyncIteration. + athrowRaise an exception in the asynchronous generator. + Return next yielded value or raise StopAsyncIteration. + acloseasynchronous generator ignored GeneratorExitReturn the next item from the iterator. When exhausted, raise StopIterationReturn the next item from the generator. + When exhausted, raise StopIteration. + Send a value into the generator. + Return next yielded value or raise StopIteration. + Raise an exception in the generator. + Return next yielded value or raise StopIteration. + Raise GeneratorExit inside generator. + generator ignored GeneratorExitA set is a finite, iterable container. + + This class provides concrete generic implementations of all + methods except for __contains__, __iter__ and __len__. + + To override the comparisons (presumably for speed, as the + semantics are fixed), redefine __le__ and __ge__, + then the other operations will automatically follow suit. + _from_iterableConstruct an instance of the class from any iterable input. + + Must override this method if the class constructor signature + does not accept an iterable for an input. + Return True if two sets have a null intersection._hashCompute the hash value of a set. + + Note that we don't define __hash__: not all sets are hashable. + But if you define a hashable set type, its __hash__ should + call this function. + + This must be compatible __eq__. + + All sets ought to compare equal if they contain the same + elements, regardless of how they are implemented, and + regardless of the order of the elements; so there's not much + freedom for __eq__ or __hash__. We match the algorithm used + by the built-in frozenset type. + MAXMASK1927868237hx89869747364479816769069907133923590923713A mutable set is a finite, iterable container. + + This class provides concrete generic implementations of all + methods except for __contains__, __iter__, __len__, + add(), and discard(). + + To override the comparisons (presumably for speed, as the + semantics are fixed), all you have to do is redefine __le__ and + then the other operations will automatically follow suit. + Add an element.Remove an element. Do not raise an exception if absent.Remove an element. If not a member, raise a KeyError.Return the popped value. Raise KeyError if empty.This is slow (creates N new iterators!) but effective.A Mapping is a generic container for associating key/value + pairs. + + This class provides concrete generic implementations of all + methods except for __getitem__, __iter__, and __len__. + + D.get(k[,d]) -> D[k] if k in D, else d. d defaults to None.{0.__class__.__name__}({0._mapping!r})A MutableMapping is a generic container for associating + key/value pairs. + + This class provides concrete generic implementations of all + methods except for __getitem__, __setitem__, __delitem__, + __iter__, and __len__. + + D.pop(k[,d]) -> v, remove specified key and return the corresponding value. + If key is not found, d is returned if given, otherwise KeyError is raised. + D.popitem() -> (k, v), remove and return some (key, value) pair + as a 2-tuple; but raise KeyError if D is empty. + D.clear() -> None. Remove all items from D. D.update([E, ]**F) -> None. Update D from mapping/iterable E and F. + If E present and has a .keys() method, does: for k in E: D[k] = E[k] + If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v + In either case, this is followed by: for k, v in F.items(): D[k] = v + D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in DAll the operations on a read-only sequence. + + Concrete subclasses must override __new__ or __init__, + __getitem__, and __len__. + S.index(value, [start, [stop]]) -> integer -- return first index of value. + Raises ValueError if the value is not present. + + Supporting start and stop arguments is optional, but + recommended. + S.count(value) -> integer -- return number of occurrences of valueThis unifies bytes and bytearray. + + XXX Should add all their methods. + All the operations on a read-write sequence. + + Concrete subclasses must provide __new__ or __init__, + __getitem__, __setitem__, __delitem__, __len__, and insert(). + + S.insert(index, value) -- insert value before indexS.append(value) -- append value to the end of the sequenceS.clear() -> None -- remove all items from SS.reverse() -- reverse *IN PLACE*S.extend(iterable) -- extend sequence by appending elements from the iterableS.pop([index]) -> item -- remove and return item at index (default last). + Raise IndexError if list is empty or index is out of range. + S.remove(value) -- remove first occurrence of value. + Raise ValueError if the value is not present. + # Copyright 2007 Google, Inc. All Rights Reserved.# This module has been renamed from collections.abc to _collections_abc to# speed up interpreter startup. Some of the types such as MutableMapping are# required early but collections module imports a lot of other modules.# See issue #19218# Private list of types that we want to register with the various ABCs# so that they will pass tests like:# it = iter(somebytearray)# assert isinstance(it, Iterable)# Note: in other implementations, these types might not be distinct# and they may have their own implementation specific types that# are not included on this list.#callable_iterator = ???## views #### misc #### coroutine ### Prevent ResourceWarning## asynchronous generator ##### ONE-TRICK PONIES ####Iterator.register(callable_iterator)### SETS ###### MAPPINGS ###### SEQUENCES #### Multiply inheriting, see ByteStringb'Abstract Base Classes (ABCs) for collections, according to PEP 3119. + +Unit tests are in test_collections. +'u'Abstract Base Classes (ABCs) for collections, according to PEP 3119. + +Unit tests are in test_collections. +'b'Awaitable'u'Awaitable'b'Coroutine'u'Coroutine'b'AsyncIterable'u'AsyncIterable'b'AsyncIterator'u'AsyncIterator'b'AsyncGenerator'u'AsyncGenerator'b'Hashable'u'Hashable'b'Iterable'u'Iterable'b'Iterator'u'Iterator'b'Generator'u'Generator'b'Reversible'u'Reversible'b'Sized'u'Sized'b'Container'u'Container'b'Callable'u'Callable'b'Collection'u'Collection'b'Set'u'Set'b'MutableSet'u'MutableSet'b'Mapping'u'Mapping'b'MutableMapping'u'MutableMapping'b'MappingView'u'MappingView'b'KeysView'u'KeysView'b'ItemsView'u'ItemsView'b'ValuesView'u'ValuesView'b'Sequence'u'Sequence'b'MutableSequence'u'MutableSequence'b'ByteString'u'ByteString'b'collections.abc'u'collections.abc'b'__hash__'u'__hash__'b'__await__'u'__await__'b'Send a value into the coroutine. + Return next yielded value or raise StopIteration. + 'u'Send a value into the coroutine. + Return next yielded value or raise StopIteration. + 'b'Raise an exception in the coroutine. + Return next yielded value or raise StopIteration. + 'u'Raise an exception in the coroutine. + Return next yielded value or raise StopIteration. + 'b'Raise GeneratorExit inside coroutine. + 'u'Raise GeneratorExit inside coroutine. + 'b'coroutine ignored GeneratorExit'u'coroutine ignored GeneratorExit'b'throw'u'throw'b'__aiter__'u'__aiter__'b'Return the next item or raise StopAsyncIteration when exhausted.'u'Return the next item or raise StopAsyncIteration when exhausted.'b'__anext__'u'__anext__'b'Return the next item from the asynchronous generator. + When exhausted, raise StopAsyncIteration. + 'u'Return the next item from the asynchronous generator. + When exhausted, raise StopAsyncIteration. + 'b'Send a value into the asynchronous generator. + Return next yielded value or raise StopAsyncIteration. + 'u'Send a value into the asynchronous generator. + Return next yielded value or raise StopAsyncIteration. + 'b'Raise an exception in the asynchronous generator. + Return next yielded value or raise StopAsyncIteration. + 'u'Raise an exception in the asynchronous generator. + Return next yielded value or raise StopAsyncIteration. + 'b'asynchronous generator ignored GeneratorExit'u'asynchronous generator ignored GeneratorExit'b'asend'u'asend'b'athrow'u'athrow'b'aclose'u'aclose'b'__iter__'u'__iter__'b'Return the next item from the iterator. When exhausted, raise StopIteration'u'Return the next item from the iterator. When exhausted, raise StopIteration'b'__next__'u'__next__'b'__reversed__'u'__reversed__'b'Return the next item from the generator. + When exhausted, raise StopIteration. + 'u'Return the next item from the generator. + When exhausted, raise StopIteration. + 'b'Send a value into the generator. + Return next yielded value or raise StopIteration. + 'u'Send a value into the generator. + Return next yielded value or raise StopIteration. + 'b'Raise an exception in the generator. + Return next yielded value or raise StopIteration. + 'u'Raise an exception in the generator. + Return next yielded value or raise StopIteration. + 'b'Raise GeneratorExit inside generator. + 'u'Raise GeneratorExit inside generator. + 'b'generator ignored GeneratorExit'u'generator ignored GeneratorExit'b'__len__'u'__len__'b'__contains__'u'__contains__'b'__call__'u'__call__'b'A set is a finite, iterable container. + + This class provides concrete generic implementations of all + methods except for __contains__, __iter__ and __len__. + + To override the comparisons (presumably for speed, as the + semantics are fixed), redefine __le__ and __ge__, + then the other operations will automatically follow suit. + 'u'A set is a finite, iterable container. + + This class provides concrete generic implementations of all + methods except for __contains__, __iter__ and __len__. + + To override the comparisons (presumably for speed, as the + semantics are fixed), redefine __le__ and __ge__, + then the other operations will automatically follow suit. + 'b'Construct an instance of the class from any iterable input. + + Must override this method if the class constructor signature + does not accept an iterable for an input. + 'u'Construct an instance of the class from any iterable input. + + Must override this method if the class constructor signature + does not accept an iterable for an input. + 'b'Return True if two sets have a null intersection.'u'Return True if two sets have a null intersection.'b'Compute the hash value of a set. + + Note that we don't define __hash__: not all sets are hashable. + But if you define a hashable set type, its __hash__ should + call this function. + + This must be compatible __eq__. + + All sets ought to compare equal if they contain the same + elements, regardless of how they are implemented, and + regardless of the order of the elements; so there's not much + freedom for __eq__ or __hash__. We match the algorithm used + by the built-in frozenset type. + 'u'Compute the hash value of a set. + + Note that we don't define __hash__: not all sets are hashable. + But if you define a hashable set type, its __hash__ should + call this function. + + This must be compatible __eq__. + + All sets ought to compare equal if they contain the same + elements, regardless of how they are implemented, and + regardless of the order of the elements; so there's not much + freedom for __eq__ or __hash__. We match the algorithm used + by the built-in frozenset type. + 'b'A mutable set is a finite, iterable container. + + This class provides concrete generic implementations of all + methods except for __contains__, __iter__, __len__, + add(), and discard(). + + To override the comparisons (presumably for speed, as the + semantics are fixed), all you have to do is redefine __le__ and + then the other operations will automatically follow suit. + 'u'A mutable set is a finite, iterable container. + + This class provides concrete generic implementations of all + methods except for __contains__, __iter__, __len__, + add(), and discard(). + + To override the comparisons (presumably for speed, as the + semantics are fixed), all you have to do is redefine __le__ and + then the other operations will automatically follow suit. + 'b'Add an element.'u'Add an element.'b'Remove an element. Do not raise an exception if absent.'u'Remove an element. Do not raise an exception if absent.'b'Remove an element. If not a member, raise a KeyError.'u'Remove an element. If not a member, raise a KeyError.'b'Return the popped value. Raise KeyError if empty.'u'Return the popped value. Raise KeyError if empty.'b'This is slow (creates N new iterators!) but effective.'u'This is slow (creates N new iterators!) but effective.'b'A Mapping is a generic container for associating key/value + pairs. + + This class provides concrete generic implementations of all + methods except for __getitem__, __iter__, and __len__. + + 'u'A Mapping is a generic container for associating key/value + pairs. + + This class provides concrete generic implementations of all + methods except for __getitem__, __iter__, and __len__. + + 'b'D.get(k[,d]) -> D[k] if k in D, else d. d defaults to None.'u'D.get(k[,d]) -> D[k] if k in D, else d. d defaults to None.'b'_mapping'u'_mapping'b'{0.__class__.__name__}({0._mapping!r})'u'{0.__class__.__name__}({0._mapping!r})'b'A MutableMapping is a generic container for associating + key/value pairs. + + This class provides concrete generic implementations of all + methods except for __getitem__, __setitem__, __delitem__, + __iter__, and __len__. + + 'u'A MutableMapping is a generic container for associating + key/value pairs. + + This class provides concrete generic implementations of all + methods except for __getitem__, __setitem__, __delitem__, + __iter__, and __len__. + + 'b'D.pop(k[,d]) -> v, remove specified key and return the corresponding value. + If key is not found, d is returned if given, otherwise KeyError is raised. + 'u'D.pop(k[,d]) -> v, remove specified key and return the corresponding value. + If key is not found, d is returned if given, otherwise KeyError is raised. + 'b'D.popitem() -> (k, v), remove and return some (key, value) pair + as a 2-tuple; but raise KeyError if D is empty. + 'u'D.popitem() -> (k, v), remove and return some (key, value) pair + as a 2-tuple; but raise KeyError if D is empty. + 'b'D.clear() -> None. Remove all items from D.'u'D.clear() -> None. Remove all items from D.'b' D.update([E, ]**F) -> None. Update D from mapping/iterable E and F. + If E present and has a .keys() method, does: for k in E: D[k] = E[k] + If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v + In either case, this is followed by: for k, v in F.items(): D[k] = v + 'u' D.update([E, ]**F) -> None. Update D from mapping/iterable E and F. + If E present and has a .keys() method, does: for k in E: D[k] = E[k] + If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v + In either case, this is followed by: for k, v in F.items(): D[k] = v + 'b'keys'b'D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in D'u'D.setdefault(k[,d]) -> D.get(k,d), also set D[k]=d if k not in D'b'All the operations on a read-only sequence. + + Concrete subclasses must override __new__ or __init__, + __getitem__, and __len__. + 'u'All the operations on a read-only sequence. + + Concrete subclasses must override __new__ or __init__, + __getitem__, and __len__. + 'b'S.index(value, [start, [stop]]) -> integer -- return first index of value. + Raises ValueError if the value is not present. + + Supporting start and stop arguments is optional, but + recommended. + 'u'S.index(value, [start, [stop]]) -> integer -- return first index of value. + Raises ValueError if the value is not present. + + Supporting start and stop arguments is optional, but + recommended. + 'b'S.count(value) -> integer -- return number of occurrences of value'u'S.count(value) -> integer -- return number of occurrences of value'b'This unifies bytes and bytearray. + + XXX Should add all their methods. + 'u'This unifies bytes and bytearray. + + XXX Should add all their methods. + 'b'All the operations on a read-write sequence. + + Concrete subclasses must provide __new__ or __init__, + __getitem__, __setitem__, __delitem__, __len__, and insert(). + + 'u'All the operations on a read-write sequence. + + Concrete subclasses must provide __new__ or __init__, + __getitem__, __setitem__, __delitem__, __len__, and insert(). + + 'b'S.insert(index, value) -- insert value before index'u'S.insert(index, value) -- insert value before index'b'S.append(value) -- append value to the end of the sequence'u'S.append(value) -- append value to the end of the sequence'b'S.clear() -> None -- remove all items from S'u'S.clear() -> None -- remove all items from S'b'S.reverse() -- reverse *IN PLACE*'u'S.reverse() -- reverse *IN PLACE*'b'S.extend(iterable) -- extend sequence by appending elements from the iterable'u'S.extend(iterable) -- extend sequence by appending elements from the iterable'b'S.pop([index]) -> item -- remove and return item at index (default last). + Raise IndexError if list is empty or index is out of range. + 'u'S.pop([index]) -> item -- remove and return item at index (default last). + Raise IndexError if list is empty or index is out of range. + 'b'S.remove(value) -- remove first occurrence of value. + Raise ValueError if the value is not present. + 'u'S.remove(value) -- remove first occurrence of value. + Raise ValueError if the value is not present. + 'u'_collections_abc'__builtin__copyregcopy_regqueueQueuesocketserverSocketServerconfigparserConfigParsertkinter.filedialogtkFileDialogtkinter.simpledialogtkSimpleDialogtkinter.colorchoosertkColorChoosertkinter.commondialogtkCommonDialogtkinter.dialogDialogtkinter.dndTkdndtkinter.fonttkFonttkinter.messageboxtkMessageBoxtkinter.scrolledtextScrolledTextTkconstantstkinter.tixTixtkinter.ttkttkTkinter_markupbasemarkupbase_dummy_threaddummy_threaddbm.bsddbhashdbm.dumbdumbdbmdbm.ndbmdbmdbm.gnugdbmxmlrpc.clientxmlrpclibxmlrpc.serverSimpleXMLRPCServerhttp.clienthttplibhtmlentitydefshtml.parserHTMLParserhttp.cookiesCookiehttp.cookiejarcookielibhttp.serverBaseHTTPServertest.test_supportcommandsurllib.robotparserrobotparserurllib2anydbm_abcollIMPORT_MAPPINGxrangereduceunichrlongizipimapifilterfilterfalseifilterfalsezip_longestizip_longestIterableUserDictwhichdbfromfd_socketmultiprocessing.connectionConnectionmultiprocessing.contextProcessmultiprocessing.popen_forkmultiprocessing.forkingContentTooShortErrorgetproxiespathname2urlquote_plusunquote_plusunquoteurl2pathnameurlcleanupurlencodeurlopenurlretrieveNAME_MAPPINGPYTHON2_EXCEPTIONSWindowsErrorexcnameAuthenticationErrorBufferTooShortProcessErrorMULTIPROCESSING_EXCEPTIONSREVERSE_IMPORT_MAPPINGREVERSE_NAME_MAPPINGcPicklexml.etree.ElementTreeFileDialogSimpleDialogDocXMLRPCServerSimpleHTTPServerCGIHTTPServercStringIO_dbm_functools_gdbm_picklebasestringStandardErrorSocketType_socketobjectLoadFileDialogSaveFileDialogServerHTMLDocXMLRPCDocGeneratorDocXMLRPCRequestHandlerDocCGIXMLRPCRequestHandlerSimpleHTTPRequestHandlerCGIHTTPRequestHandlerPYTHON3_OSERROR_EXCEPTIONSPYTHON3_IMPORTERROR_EXCEPTIONS# This module is used to map the old Python 2 names to the new names used in# Python 3 for the pickle module. This needed to make pickle streams# generated with Python 2 loadable by Python 3.# This is a copy of lib2to3.fixes.fix_imports.MAPPING. We cannot import# lib2to3 and use the mapping defined there, because lib2to3 uses pickle.# Thus, this could cause the module to be imported recursively.# This contains rename rules that are easy to handle. We ignore the more# complex stuff (e.g. mapping the names in the urllib and types modules).# These rules should be run before import names are fixed.# StandardError is gone in Python 3, so we map it to Exception# Same, but for 3.x to 2.x# Non-mutual mappings.# For compatibility with broken pickles saved in old Python 3 versionsb'__builtin__'u'__builtin__'b'copyreg'u'copyreg'b'copy_reg'u'copy_reg'b'queue'u'queue'b'Queue'u'Queue'b'socketserver'u'socketserver'b'SocketServer'u'SocketServer'b'configparser'u'configparser'b'ConfigParser'u'ConfigParser'b'reprlib'u'reprlib'b'repr'u'repr'b'tkinter.filedialog'u'tkinter.filedialog'b'tkFileDialog'u'tkFileDialog'b'tkinter.simpledialog'u'tkinter.simpledialog'b'tkSimpleDialog'u'tkSimpleDialog'b'tkinter.colorchooser'u'tkinter.colorchooser'b'tkColorChooser'u'tkColorChooser'b'tkinter.commondialog'u'tkinter.commondialog'b'tkCommonDialog'u'tkCommonDialog'b'tkinter.dialog'u'tkinter.dialog'b'Dialog'u'Dialog'b'tkinter.dnd'u'tkinter.dnd'b'Tkdnd'u'Tkdnd'b'tkinter.font'u'tkinter.font'b'tkFont'u'tkFont'b'tkinter.messagebox'u'tkinter.messagebox'b'tkMessageBox'u'tkMessageBox'b'tkinter.scrolledtext'u'tkinter.scrolledtext'b'ScrolledText'u'ScrolledText'b'tkinter.constants'u'tkinter.constants'b'Tkconstants'u'Tkconstants'b'tkinter.tix'u'tkinter.tix'b'Tix'u'Tix'b'tkinter.ttk'u'tkinter.ttk'b'ttk'u'ttk'b'tkinter'b'Tkinter'u'Tkinter'b'_markupbase'u'_markupbase'b'markupbase'u'markupbase'b'thread'u'thread'b'_dummy_thread'u'_dummy_thread'b'dummy_thread'u'dummy_thread'b'dbm.bsd'u'dbm.bsd'b'dbhash'u'dbhash'b'dbm.dumb'u'dbm.dumb'b'dumbdbm'u'dumbdbm'b'dbm.ndbm'u'dbm.ndbm'b'dbm'u'dbm'b'dbm.gnu'u'dbm.gnu'b'gdbm'u'gdbm'b'xmlrpc.client'u'xmlrpc.client'b'xmlrpclib'u'xmlrpclib'b'xmlrpc.server'u'xmlrpc.server'b'SimpleXMLRPCServer'u'SimpleXMLRPCServer'b'http.client'u'http.client'b'httplib'u'httplib'b'html.entities'u'html.entities'b'htmlentitydefs'u'htmlentitydefs'b'html.parser'u'html.parser'b'HTMLParser'u'HTMLParser'b'http.cookies'u'http.cookies'b'Cookie'u'Cookie'b'http.cookiejar'u'http.cookiejar'b'cookielib'u'cookielib'b'http.server'u'http.server'b'BaseHTTPServer'u'BaseHTTPServer'b'test.test_support'u'test.test_support'b'subprocess'u'subprocess'b'commands'u'commands'b'urllib.parse'u'urllib.parse'b'urlparse'u'urlparse'b'urllib.robotparser'u'urllib.robotparser'b'robotparser'u'robotparser'b'urllib.request'u'urllib.request'b'urllib2'u'urllib2'b'anydbm'u'anydbm'b'_abcoll'u'_abcoll'b'xrange'u'xrange'b'functools'u'functools'b'reduce'u'reduce'b'intern'u'intern'b'chr'u'chr'b'unichr'u'unichr'b'str'u'str'b'int'u'int'b'long'u'long'b'zip'u'zip'b'itertools'b'izip'u'izip'b'map'u'map'b'imap'u'imap'b'ifilter'u'ifilter'b'filterfalse'u'filterfalse'b'ifilterfalse'u'ifilterfalse'b'zip_longest'u'zip_longest'b'izip_longest'u'izip_longest'b'collections'b'IterableUserDict'u'IterableUserDict'b'whichdb'u'whichdb'b'socket'u'socket'b'fromfd'u'fromfd'b'_socket'u'_socket'b'multiprocessing.connection'u'multiprocessing.connection'b'Connection'u'Connection'b'multiprocessing.context'u'multiprocessing.context'b'Process'u'Process'b'multiprocessing.process'u'multiprocessing.process'b'multiprocessing.popen_fork'u'multiprocessing.popen_fork'b'Popen'u'Popen'b'multiprocessing.forking'u'multiprocessing.forking'b'urllib.error'u'urllib.error'b'ContentTooShortError'u'ContentTooShortError'b'urllib'b'getproxies'u'getproxies'b'pathname2url'u'pathname2url'b'quote_plus'u'quote_plus'b'quote'u'quote'b'unquote_plus'u'unquote_plus'b'unquote'u'unquote'b'url2pathname'u'url2pathname'b'urlcleanup'u'urlcleanup'b'urlencode'u'urlencode'b'urlopen'u'urlopen'b'urlretrieve'u'urlretrieve'b'HTTPError'u'HTTPError'b'URLError'u'URLError'b'ArithmeticError'u'ArithmeticError'b'AssertionError'u'AssertionError'b'AttributeError'u'AttributeError'b'BaseException'u'BaseException'b'BufferError'u'BufferError'b'BytesWarning'u'BytesWarning'b'DeprecationWarning'u'DeprecationWarning'b'EnvironmentError'u'EnvironmentError'b'Exception'u'Exception'b'FloatingPointError'u'FloatingPointError'b'FutureWarning'u'FutureWarning'b'GeneratorExit'u'GeneratorExit'b'IOError'u'IOError'b'ImportError'u'ImportError'b'ImportWarning'u'ImportWarning'b'IndentationError'u'IndentationError'b'IndexError'u'IndexError'b'KeyError'u'KeyError'b'KeyboardInterrupt'u'KeyboardInterrupt'b'LookupError'u'LookupError'b'MemoryError'u'MemoryError'b'NameError'u'NameError'b'NotImplementedError'u'NotImplementedError'b'OSError'u'OSError'b'OverflowError'u'OverflowError'b'PendingDeprecationWarning'u'PendingDeprecationWarning'b'ReferenceError'u'ReferenceError'b'RuntimeError'u'RuntimeError'b'RuntimeWarning'u'RuntimeWarning'b'StopIteration'u'StopIteration'b'SyntaxError'u'SyntaxError'b'SyntaxWarning'u'SyntaxWarning'b'SystemError'u'SystemError'b'SystemExit'u'SystemExit'b'TabError'u'TabError'b'TypeError'u'TypeError'b'UnboundLocalError'u'UnboundLocalError'b'UnicodeDecodeError'u'UnicodeDecodeError'b'UnicodeEncodeError'u'UnicodeEncodeError'b'UnicodeError'u'UnicodeError'b'UnicodeTranslateError'u'UnicodeTranslateError'b'UnicodeWarning'u'UnicodeWarning'b'UserWarning'u'UserWarning'b'ValueError'u'ValueError'b'Warning'u'Warning'b'ZeroDivisionError'u'ZeroDivisionError'b'WindowsError'u'WindowsError'b'exceptions'u'exceptions'b'AuthenticationError'u'AuthenticationError'b'BufferTooShort'u'BufferTooShort'b'ProcessError'u'ProcessError'b'pickle'u'pickle'b'cPickle'u'cPickle'b'xml.etree.ElementTree'b'_elementtree'u'_elementtree'b'FileDialog'u'FileDialog'b'SimpleDialog'u'SimpleDialog'b'DocXMLRPCServer'u'DocXMLRPCServer'b'SimpleHTTPServer'u'SimpleHTTPServer'b'CGIHTTPServer'u'CGIHTTPServer'b'io'u'io'b'StringIO'u'StringIO'b'cStringIO'u'cStringIO'b'bz2'u'bz2'b'_bz2'b'_dbm'u'_dbm'b'_functools'b'_gdbm'u'_gdbm'b'_pickle'u'_pickle'b'basestring'u'basestring'b'StandardError'u'StandardError'b'SocketType'u'SocketType'b'_socketobject'u'_socketobject'b'LoadFileDialog'u'LoadFileDialog'b'SaveFileDialog'u'SaveFileDialog'b'ServerHTMLDoc'u'ServerHTMLDoc'b'XMLRPCDocGenerator'u'XMLRPCDocGenerator'b'DocXMLRPCRequestHandler'u'DocXMLRPCRequestHandler'b'DocCGIXMLRPCRequestHandler'u'DocCGIXMLRPCRequestHandler'b'SimpleHTTPRequestHandler'u'SimpleHTTPRequestHandler'b'CGIHTTPRequestHandler'u'CGIHTTPRequestHandler'b'BrokenPipeError'u'BrokenPipeError'b'ChildProcessError'u'ChildProcessError'b'ConnectionAbortedError'u'ConnectionAbortedError'b'ConnectionError'u'ConnectionError'b'ConnectionResetError'u'ConnectionResetError'b'FileExistsError'u'FileExistsError'b'FileNotFoundError'u'FileNotFoundError'b'InterruptedError'u'InterruptedError'b'IsADirectoryError'u'IsADirectoryError'b'NotADirectoryError'u'NotADirectoryError'b'PermissionError'u'PermissionError'b'ProcessLookupError'u'ProcessLookupError'b'ModuleNotFoundError'u'ModuleNotFoundError'u'_compat_pickle'Internal classes used by the gzip, lzma and bz2 modulesDEFAULT_BUFFER_SIZEBUFFER_SIZEBaseStreamMode-checking helper functions._check_not_closedI/O operation on closed file_check_can_readUnsupportedOperationFile not open for reading_check_can_writeFile not open for writing_check_can_seekSeeking is only supported on files open for reading"Seeking is only supported ""on files open for reading"The underlying file object does not support seeking"The underlying file object ""does not support seeking"DecompressReaderAdapts the decompressor API to a RawIOBase reader APIdecomp_factorytrailing_errordecomp_args_fp_eof_pos_size_decomp_factory_decomp_args_decompressor_trailing_errorreadintoviewbyte_viewreadallrawblockCompressed file ended before the end-of-stream marker was reached"Compressed file ended before the ""end-of-stream marker was reached"_rewindSEEK_SETwhenceSEEK_CURSEEK_ENDInvalid value for whence: {}Return the current file position.# Compressed data read chunk size# Current offset in decompressed stream# Set to size of decompressed stream once it is known, for SEEK_END# Save the decompressor factory and arguments.# If the file contains multiple compressed streams, each# stream will need a separate decompressor object. A new decompressor# object is also needed when implementing a backwards seek().# Exception class to catch from decompressor signifying invalid# trailing data to ignore# Default if EOF is encountered# Depending on the input data, our call to the decompressor may not# return any data. In this case, try again after reading another block.# Continue to next stream.# Trailing data isn't a valid compressed stream; ignore it.# Rewind the file to the beginning of the data stream.# Recalculate offset as an absolute file position.# Seeking relative to EOF - we need to know the file's size.# Make it so that offset is the number of bytes to skip forward.# Read and discard data until we reach the desired position.b'Internal classes used by the gzip, lzma and bz2 modules'u'Internal classes used by the gzip, lzma and bz2 modules'b'Mode-checking helper functions.'u'Mode-checking helper functions.'b'I/O operation on closed file'u'I/O operation on closed file'b'File not open for reading'u'File not open for reading'b'File not open for writing'u'File not open for writing'b'Seeking is only supported on files open for reading'u'Seeking is only supported on files open for reading'b'The underlying file object does not support seeking'u'The underlying file object does not support seeking'b'Adapts the decompressor API to a RawIOBase reader API'u'Adapts the decompressor API to a RawIOBase reader API'b'Compressed file ended before the end-of-stream marker was reached'u'Compressed file ended before the end-of-stream marker was reached'b'Invalid value for whence: {}'u'Invalid value for whence: {}'b'Return the current file position.'u'Return the current file position.'u'_compression'Context__class_getitem__ContextVarToken.MISSINGMISSINGu'Token.old_value'u'Token.var'Tokenu'Context Variables'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_contextvars.cpython-38-darwin.so'u'_contextvars'copy_context_contextvarsu'ArgumentError.__weakref__'ctypes.ArgumentErroru'metatype for the Array Objects'from_addressfrom_buffer_copyin_dll_ctypes.PyCArrayTypeu'XXX to be provided'__ctypes_from_outparam___b_base__b_needsfree__objects_ctypes._CData_ctypes.Arrayu'metatype for C function pointers'_ctypes.PyCFuncPtrTypeu'Function Pointer'u'specify the argument types'u'PyCFuncPtr.argtypes'u'a function to check for errors'u'PyCFuncPtr.errcheck'errchecku'specify the result type'u'PyCFuncPtr.restype'_ctypes.PyCFuncPtrPyObj_FromPtrPy_DECREFPy_INCREFu'metatype for the CData Objects'_ctypes.PyCStructTypeu'Structure base class'_ctypes.Structure_ctypes.UnionTypeu'Union base class'_ctypes.Unionu'metatype for the Pointer Objects'_ctypes.PyCPointerTypeu'the object this pointer points to (read-write)'u'_Pointer.contents'_ctypes._Pointeru'metatype for the PyCSimpleType Objects'_ctypes.PyCSimpleTypeu'current value'u'_SimpleCData.value'_ctypes._SimpleCDatau'Create and manipulate C compatible data types in Python.'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_ctypes.cpython-38-darwin.so'u'_ctypes'4333954608_dyld_shared_cache_contains_path679858336067985826404333954472_unpickle4333955340buffer_infocall_cdeclfunctioncall_functiondlclosedlsym9999MAXYEARMINYEARu'Fast implementation of the datetime type.'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_datetime.cpython-38-darwin.so'u'_datetime'u'date(year, month, day) --> date object'ctimeu'date.day'dayfromisocalendarfromisoformatfromordinalfromtimestampisocalendarisoformatisoweekdayu'date.month'monthu'Difference between two datetime values. + +timedelta(days=0, seconds=0, microseconds=0, milliseconds=0, minutes=0, hours=0, weeks=0) + +All arguments are optional and default to 0. +Arguments may be integers or floats, and may be positive or negative.'daysmicrosecondsresolutionsecondstotal_secondsdatetime.timedeltatimetupletodaytoordinalweekdayu'date.year'yeardatetime.datedateu'datetime(year, month, day[, hour[, minute[, second[, microsecond[,tzinfo]]]]]) + +The year, month and day arguments are required. tzinfo may be None, or an +instance of a tzinfo subclass. The remaining arguments may be ints. +'astimezonecombinedstu'datetime.fold'foldu'datetime.hour'houru'datetime.microsecond'microsecondu'datetime.minute'minutenowu'datetime.second'secondstrptimetimestamptimetzu'datetime.tzinfo'tzinfotznameutcfromtimestamputcnowutcoffsetutctimetupledatetime.datetimedatetimeu'Capsule objects let you wrap a C "void *" pointer in a Python +object. They're a way of passing data through the Python interpreter +without creating your own custom type. + +Capsules are used for communication between extension modules. +They provide a way for an extension module to export a C interface +to other extension modules, so that extension modules can use the +Python import mechanism to link to one another. +'PyCapsuledatetime_CAPIu'time([hour[, minute[, second[, microsecond[, tzinfo]]]]]) --> a time object + +All arguments are optional. tzinfo may be None, or an instance of +a tzinfo subclass. The remaining arguments may be ints. +'u'time.fold'u'time.hour'u'time.microsecond'u'time.minute'u'time.second'u'time.tzinfo'datetime.timetimedeltau'Fixed offset from UTC implementation of tzinfo.'__getinitargs__fromutcutcu'Abstract base class for time zone info objects.'datetime.tzinfodatetime.timezonetimezone_datetimeu'Context.Emax'Emaxu'Context.Emin'EminEtinyEtopu'The context affects almost all operations and controls rounding, +Over/Underflow, raising of exceptions and much more. A new context +can be constructed as follows: + + >>> c = Context(prec=28, Emin=-425000000, Emax=425000000, + ... rounding=ROUND_HALF_EVEN, capitals=1, clamp=1, + ... traps=[InvalidOperation, DivisionByZero, Overflow], + ... flags=[]) + >>> + + +'u'decimal'_applycanonicalu'Context.capitals'capitalsu'Context.clamp'clampclear_flagsclear_trapscompare_signalcompare_totalcompare_total_magcopy_abscopy_decimalcopy_negatecopy_signcreate_decimalcreate_decimal_from_floatdividedivide_intexpfmais_canonicalis_finiteis_infiniteis_nanis_normalis_qnanis_signedis_snanis_subnormalis_zerolnlog10logblogical_andlogical_invertlogical_orlogical_xormax_magmin_magminusmultiplynext_minusnext_plusnext_towardnumber_classpluspoweru'Context.prec'quantizeremainderremainder_nearu'Context.rounding'roundingsame_quantumscalebshiftto_eng_stringto_integralto_integral_exactto_integral_valueto_sci_stringdecimal.ContextBasicContextu'DecimalException.__weakref__'decimal.DecimalExceptiondecimal.ClampedClampeddecimal.InvalidOperationdecimal.ConversionSyntaxConversionSyntax__deepcopy__u'Construct a new Decimal object. 'value' can be an integer, string, tuple, +or another Decimal object. If no value is given, return Decimal('0'). The +context does not affect the conversion and is only passed to determine if +the InvalidOperation trap is active. + +'adjustedas_tuplefrom_floatu'Decimal.imag'u'Decimal.real'decimal.DecimalDecimalExceptionu'DecimalTuple(sign, digits, exponent)'u'sign'u'digits'u'exponent'digitsexponentsigndecimal.DecimalTupleDecimalTupleDefaultContextdecimal.DivisionByZeroDivisionByZerodecimal.DivisionImpossibleDivisionImpossibledecimal.DivisionUndefinedDivisionUndefinedExtendedContextdecimal.FloatOperationFloatOperationHAVE_CONTEXTVARHAVE_THREADSdecimal.InexactInexactdecimal.InvalidContextInvalidContextInvalidOperation999999999999999999MAX_EMAXMAX_PREC-999999999999999999MIN_EMIN-1999999999999999997MIN_ETINYdecimal.OverflowOverflowu'ROUND_05UP'ROUND_05UPu'ROUND_CEILING'ROUND_CEILINGu'ROUND_DOWN'ROUND_DOWNu'ROUND_FLOOR'ROUND_FLOORu'ROUND_HALF_DOWN'ROUND_HALF_DOWNu'ROUND_HALF_EVEN'ROUND_HALF_EVENu'ROUND_HALF_UP'ROUND_HALF_UPu'ROUND_UP'ROUND_UPdecimal.RoundedRoundeddecimal.SubnormalSubnormaldecimal.UnderflowUnderflowu'C decimal arithmetic module'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_decimal.cpython-38-darwin.so'u'2.4.2'__libmpdec_version__u'1.70'getcontextsetcontext__getstate__u'A dictionary containing the element's attributes'u'Element.attrib'u'A string identifying what kind of data this element represents'u'Element.tag'u'A string of text directly after the end tag, or None'u'Element.tail'u'A string of text directly after the start tag, or None'u'Element.text'xml.etree.ElementTree.Elementu'ParseError.__weakref__'xml.etree.ElementTree.ParseErrorxml.etree.ElementTree.TreeBuilderu'XMLParser.version'xml.etree.ElementTree.XMLParseru'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_elementtree.cpython-38-darwin.so' Routines for manipulating RFC2047 encoded words. + +This is currently a package-private API, but will be considered for promotion +to a public API if there is demand. + +base64binasciiascii_lettersemaildecode_qencode_qdecode_bencode_blen_qlen_bpartial=([a-fA-F0-9]{2})br'_q_byte_subberencoded_QByteMap-!*+/safe={:02X}_q_byte_mapbstringpad_err===missing_paddingb64decodeInvalidBase64PaddingDefectInvalidBase64CharactersDefect==InvalidBase64LengthDefectb64encodegroups_of_3leftover_cte_decodersewDecode encoded word and return (string, charset, lang, defects) tuple. + + An RFC 2047/2243 encoded word has the form: + + =?charset*lang?cte?encoded_string?= + + where '*lang' may be omitted but the other parts may not be. + + This function expects exactly such a string (that is, it does not check the + syntax and may raise errors if the string is not well formed), and returns + the encoded_string decoded first from its Content Transfer Encoding and + then from the resulting bytes into unicode using the specified charset. If + the cte-decoded string does not successfully decode using the specified + character set, a defect is added to the defects list and the unknown octets + are replaced by the unicode 'unknown' character \uFDFF. + + The specified charset and language are returned. The default for language, + which is rarely if ever encountered, is the empty string. + + ctecte_stringlangdefectsUndecodableBytesDefectEncoded word contains bytes not decodable using {} charset"Encoded word ""contains bytes not decodable using {} charset"unknown-8bitCharsetErrorUnknown charset {} in encoded word; decoded as unknown bytes"Unknown charset {} ""in encoded word; decoded as unknown bytes"_cte_encoders_cte_encode_lengthEncode string using the CTE encoding that produces the shorter result. + + Produces an RFC 2047/2243 encoded word of the form: + + =?charset*lang?cte?encoded_string?= + + where '*lang' is omitted unless the 'lang' parameter is given a value. + Optional argument charset (defaults to utf-8) specifies the charset to use + to encode the string to binary before CTE encoding it. Optional argument + 'encoding' is the cte specifier for the encoding that should be used ('q' + or 'b'); if it is None (the default) the encoding which produces the + shortest encoded sequence is used, except that 'q' is preferred if it is up + to five characters longer. Optional argument 'lang' (default '') gives the + RFC 2243 language string to specify in the encoded word. + + qlenblen=?{}{}?{}?{}?=# An ecoded word looks like this:# =?charset[*lang]?cte?encoded_string?=# for more information about charset see the charset module. Here it is one# of the preferred MIME charset names (hopefully; you never know when parsing).# cte (Content Transfer Encoding) is either 'q' or 'b' (ignoring case). In# theory other letters could be used for other encodings, but in practice this# (almost?) never happens. There could be a public API for adding entries# to the CTE tables, but YAGNI for now. 'q' is Quoted Printable, 'b' is# Base64. The meaning of encoded_string should be obvious. 'lang' is optional# as indicated by the brackets (they are not part of the syntax) but is almost# never encountered in practice.# The general interface for a CTE decoder is that it takes the encoded_string# as its argument, and returns a tuple (cte_decoded_string, defects). The# cte_decoded_string is the original binary that was encoded using the# specified cte. 'defects' is a list of MessageDefect instances indicating any# problems encountered during conversion. 'charset' and 'lang' are the# corresponding strings extracted from the EW, case preserved.# The general interface for a CTE encoder is that it takes a binary sequence# as input and returns the cte_encoded_string, which is an ascii-only string.# Each decoder must also supply a length function that takes the binary# sequence as its argument and returns the length of the resulting encoded# string.# The main API functions for the module are decode, which calls the decoder# referenced by the cte specifier, and encode, which adds the appropriate# RFC 2047 "chrome" to the encoded string, and can optionally automatically# select the shortest possible encoding. See their docstrings below for# details.# Quoted Printable# regex based decoder.# dict mapping bytes to their encoded form# In headers spaces are mapped to '_'.# Base64# First try encoding with validate=True, fixing the padding if needed.# This will succeed only if encoded includes no invalid characters.# Since we had correct padding, this is likely an invalid char error.# The non-alphabet characters are ignored as far as padding# goes, but we don't know how many there are. So try without adding# padding to see if it works.# Add as much padding as could possibly be necessary (extra padding# is ignored).# This only happens when the encoded string's length is 1 more# than a multiple of 4, which is invalid.# bpo-27397: Just return the encoded string since there's no# way to decode.# 4 bytes out for each 3 bytes (or nonzero fraction thereof) in.# Recover the original bytes and do CTE decoding.# Turn the CTE decoded bytes into unicode.# Bias toward q. 5 is arbitrary.b' Routines for manipulating RFC2047 encoded words. + +This is currently a package-private API, but will be considered for promotion +to a public API if there is demand. + +'u' Routines for manipulating RFC2047 encoded words. + +This is currently a package-private API, but will be considered for promotion +to a public API if there is demand. + +'b'decode_q'u'decode_q'b'encode_q'u'encode_q'b'decode_b'u'decode_b'b'encode_b'u'encode_b'b'len_q'u'len_q'b'len_b'u'len_b'b'decode'u'decode'b'encode'u'encode'b'=([a-fA-F0-9]{2})'b'-!*+/'b'={:02X}'u'={:02X}'b'==='b'=='b'Decode encoded word and return (string, charset, lang, defects) tuple. + + An RFC 2047/2243 encoded word has the form: + + =?charset*lang?cte?encoded_string?= + + where '*lang' may be omitted but the other parts may not be. + + This function expects exactly such a string (that is, it does not check the + syntax and may raise errors if the string is not well formed), and returns + the encoded_string decoded first from its Content Transfer Encoding and + then from the resulting bytes into unicode using the specified charset. If + the cte-decoded string does not successfully decode using the specified + character set, a defect is added to the defects list and the unknown octets + are replaced by the unicode 'unknown' character \uFDFF. + + The specified charset and language are returned. The default for language, + which is rarely if ever encountered, is the empty string. + + 'u'Decode encoded word and return (string, charset, lang, defects) tuple. + + An RFC 2047/2243 encoded word has the form: + + =?charset*lang?cte?encoded_string?= + + where '*lang' may be omitted but the other parts may not be. + + This function expects exactly such a string (that is, it does not check the + syntax and may raise errors if the string is not well formed), and returns + the encoded_string decoded first from its Content Transfer Encoding and + then from the resulting bytes into unicode using the specified charset. If + the cte-decoded string does not successfully decode using the specified + character set, a defect is added to the defects list and the unknown octets + are replaced by the unicode 'unknown' character \uFDFF. + + The specified charset and language are returned. The default for language, + which is rarely if ever encountered, is the empty string. + + 'b'Encoded word contains bytes not decodable using {} charset'u'Encoded word contains bytes not decodable using {} charset'b'unknown-8bit'u'unknown-8bit'b'Unknown charset {} in encoded word; decoded as unknown bytes'u'Unknown charset {} in encoded word; decoded as unknown bytes'b'Encode string using the CTE encoding that produces the shorter result. + + Produces an RFC 2047/2243 encoded word of the form: + + =?charset*lang?cte?encoded_string?= + + where '*lang' is omitted unless the 'lang' parameter is given a value. + Optional argument charset (defaults to utf-8) specifies the charset to use + to encode the string to binary before CTE encoding it. Optional argument + 'encoding' is the cte specifier for the encoding that should be used ('q' + or 'b'); if it is None (the default) the encoding which produces the + shortest encoded sequence is used, except that 'q' is preferred if it is up + to five characters longer. Optional argument 'lang' (default '') gives the + RFC 2243 language string to specify in the encoded word. + + 'u'Encode string using the CTE encoding that produces the shorter result. + + Produces an RFC 2047/2243 encoded word of the form: + + =?charset*lang?cte?encoded_string?= + + where '*lang' is omitted unless the 'lang' parameter is given a value. + Optional argument charset (defaults to utf-8) specifies the charset to use + to encode the string to binary before CTE encoding it. Optional argument + 'encoding' is the cte specifier for the encoding that should be used ('q' + or 'b'); if it is None (the default) the encoding which produces the + shortest encoded sequence is used, except that 'q' is preferred if it is up + to five characters longer. Optional argument 'lang' (default '') gives the + RFC 2243 language string to specify in the encoded word. + + 'b'=?{}{}?{}?{}?='u'=?{}{}?{}?{}?='u'email._encoded_words'u'_encoded_words'_array_type_other_endianReturn the type with the 'other' byte order. Simple types like + c_int and so on already have __ctype_be__ and __ctype_le__ + attributes which contain the types, for more complicated types + arrays and structures are supported. + _OTHER_ENDIAN_length_This type does not support other endian: %s_swapped_metaattrnamedescStructure with big endian byte order_swappedbytes_bigStructure with little endian byte orderInvalid byteorder# check _OTHER_ENDIAN attribute (present if typ is primitive type)# if typ is array# if typ is structure# Note: The Structure metaclass checks for the *presence* (not the# value!) of a _swapped_bytes_ attribute to determine the bit order in# structures containing bit fields.b'Return the type with the 'other' byte order. Simple types like + c_int and so on already have __ctype_be__ and __ctype_le__ + attributes which contain the types, for more complicated types + arrays and structures are supported. + 'u'Return the type with the 'other' byte order. Simple types like + c_int and so on already have __ctype_be__ and __ctype_le__ + attributes which contain the types, for more complicated types + arrays and structures are supported. + 'b'This type does not support other endian: %s'u'This type does not support other endian: %s'b'_fields_'u'_fields_'b'__ctype_be__'u'__ctype_be__'b'Structure with big endian byte order'u'Structure with big endian byte order'b'big'u'big'b'__ctype_le__'u'__ctype_le__'b'Structure with little endian byte order'u'Structure with little endian byte order'b'Invalid byteorder'u'Invalid byteorder'u'ctypes._endian'u'_endian'u'Tools that operate on functions.'u'_lru_cache_wrapper.__dict__'u'Create a cached callable that wraps another function. + +user_function: the function being cached + +maxsize: 0 for no caching + None for unlimited cache size + n for a bounded cache + +typed: False cache f(3) and f(3.0) as identical calls + True cache f(3) and f(3.0) as distinct calls + +cache_info_type: namedtuple class with the fields: + hits misses currsize maxsize +'cache_clearcache_infofunctools._lru_cache_wrapper_lru_cache_wrappercmp_to_keyu'partial.__dict__'u'partial(func, *args, **keywords) - new function with partial application + of the given arguments and keywords. +'keywordsfunctools.partialu'A hash is an object used to calculate a checksum of a string of information. + +Methods: + +update() -- updates the current digest with an additional string +digest() -- return the current digest value +hexdigest() -- return the current digest as a string of hexadecimal digits +copy() -- return a copy of the current hash object + +Attributes: + +name -- the hash algorithm being used by this object +digest_size -- number of bytes in this hashes output'u'HASH.block_size'u'HASH.digest_size'u'HASH.name'_hashlib.HASHHASHu'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_hashlib.cpython-38-darwin.so'u'_hashlib'hmac_digestopenssl_md5openssl_md_meth_namesopenssl_sha1openssl_sha224openssl_sha256openssl_sha384openssl_sha512pbkdf2_hmacscryptu'Heap queues + +[explanation by François Pinard] + +Heaps are arrays for which a[k] <= a[2*k+1] and a[k] <= a[2*k+2] for +all k, counting elements from 0. For the sake of comparison, +non-existing elements are considered to be infinite. The interesting +property of a heap is that a[0] is always its smallest element. + +The strange invariant above is meant to be an efficient memory +representation for a tournament. The numbers below are `k', not a[k]: + + 0 + + 1 2 + + 3 4 5 6 + + 7 8 9 10 11 12 13 14 + + 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 + + +In the tree above, each cell `k' is topping `2*k+1' and `2*k+2'. In +a usual binary tournament we see in sports, each cell is the winner +over the two cells it tops, and we can trace the winner down the tree +to see all opponents s/he had. However, in many computer applications +of such tournaments, we do not need to trace the history of a winner. +To be more memory efficient, when a winner is promoted, we try to +replace it by something else at a lower level, and the rule becomes +that a cell and the two cells it tops contain three different items, +but the top cell "wins" over the two topped cells. + +If this heap invariant is protected at all time, index 0 is clearly +the overall winner. The simplest algorithmic way to remove it and +find the "next" winner is to move some loser (let's say cell 30 in the +diagram above) into the 0 position, and then percolate this new 0 down +the tree, exchanging values, until the invariant is re-established. +This is clearly logarithmic on the total number of items in the tree. +By iterating over all items, you get an O(n ln n) sort. + +A nice feature of this sort is that you can efficiently insert new +items while the sort is going on, provided that the inserted items are +not "better" than the last 0'th element you extracted. This is +especially useful in simulation contexts, where the tree holds all +incoming events, and the "win" condition means the smallest scheduled +time. When an event schedule other events for execution, they are +scheduled into the future, so they can easily go into the heap. So, a +heap is a good structure for implementing schedulers (this is what I +used for my MIDI sequencer :-). + +Various structures for implementing schedulers have been extensively +studied, and heaps are good for this, as they are reasonably speedy, +the speed is almost constant, and the worst case is not much different +than the average case. However, there are other representations which +are more efficient overall, yet the worst cases might be terrible. + +Heaps are also very useful in big disk sorts. You most probably all +know that a big sort implies producing "runs" (which are pre-sorted +sequences, which size is usually related to the amount of CPU memory), +followed by a merging passes for these runs, which merging is often +very cleverly organised[1]. It is very important that the initial +sort produces the longest runs possible. Tournaments are a good way +to that. If, using all the memory available to hold a tournament, you +replace and percolate items that happen to fit the current run, you'll +produce runs which are twice the size of the memory for random input, +and much better for input fuzzily ordered. + +Moreover, if you output the 0'th item on disk and get an input which +may not fit in the current tournament (because the value "wins" over +the last output value), it cannot fit in the heap, so the size of the +heap decreases. The freed memory could be cleverly reused immediately +for progressively building a second heap, which grows at exactly the +same rate the first heap is melting. When the first heap completely +vanishes, you switch heaps and start a new run. Clever and quite +effective! + +In a word, heaps are useful memory structures to know. I use them in +a few applications, and I think it is good to keep a `heap' module +around. :-) + +-------------------- +[1] The disk balancing algorithms which are current, nowadays, are +more annoying than clever, and this is a consequence of the seeking +capabilities of the disks. On devices which cannot seek, like big +tape drives, the story was quite different, and one had to be very +clever to ensure (far in advance) that each tape movement will be the +most effective possible (that is, will best participate at +"progressing" the merge). Some tapes were even able to read +backwards, and this was also used to avoid the rewinding time. +Believe me, real good tape sorts were quite spectacular to watch! +From all times, sorting has always been a Great Art! :-) +'__about__u'Heap queue algorithm (a.k.a. priority queue). + +Heaps are arrays for which a[k] <= a[2*k+1] and a[k] <= a[2*k+2] for +all k, counting elements from 0. For the sake of comparison, +non-existing elements are considered to be infinite. The interesting +property of a heap is that a[0] is always its smallest element. + +Usage: + +heap = [] # creates an empty heap +heappush(heap, item) # pushes a new item on the heap +item = heappop(heap) # pops the smallest item from the heap +item = heap[0] # smallest item on the heap without popping it +heapify(x) # transforms list into a heap, in-place, in linear time +item = heapreplace(heap, item) # pops and returns smallest item, and adds + # new item; the heap size is unchanged + +Our API differs from textbook heap algorithms as follows: + +- We use 0-based indexing. This makes the relationship between the + index for a node and the indexes for its children slightly less + obvious, but is more suitable since Python uses 0-based indexing. + +- Our heappop() method returns the smallest item, not the largest. + +These two make it possible to view the heap as a regular Python list +without surprises: heap[0] is the smallest item, and heap.sort() +maintains the heap invariant! +'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_heapq.cpython-38-darwin.so'u'_heapq'_heapify_max_heappop_max_heapreplace_maxheapifyheappopheappushheappushpopheapreplaceu'(Extremely) low-level import machinery bits as used by importlib and imp.'u'default'init_frozenlock_heldu'A buffered reader and writer object together. + +A buffered reader object and buffered writer object put together to +form a sequential IO object that can read and write. This is typically +used with a socket or two-way pipe. + +reader and writer are RawIOBase objects that are readable and +writeable respectively. If the buffer_size is omitted it defaults to +DEFAULT_BUFFER_SIZE.'u'BufferedRWPair.closed'peekread1readinto1u'Base class for buffered IO objects. + +The main difference with RawIOBase is that the read() method +supports omitting the size argument, and does not have a default +implementation that defers to readinto(). + +In addition, read(), readinto() and write() may raise +BlockingIOError if the underlying raw stream is in non-blocking +mode and not ready; unlike their raw counterparts, they will never +return None. + +A typical implementation should not inherit from a RawIOBase +implementation, but wrap one. +'_io._BufferedIOBase_io.BufferedRWPairBufferedRWPairu'A buffered interface to random access streams. + +The constructor creates a reader and writer for a seekable stream, +raw, given in the first argument. If the buffer_size is omitted it +defaults to DEFAULT_BUFFER_SIZE.'_dealloc_warnu'BufferedRandom.closed'u'BufferedRandom.mode'u'BufferedRandom.name'raw_io.BufferedRandomBufferedRandomu'Create a new buffered reader using the given readable raw IO object.'u'BufferedReader.closed'u'BufferedReader.mode'u'BufferedReader.name'_io.BufferedReaderBufferedReaderu'A buffer for a writeable sequential RawIO object. + +The constructor creates a BufferedWriter for the given writeable raw +stream. If the buffer_size is not given, it defaults to +DEFAULT_BUFFER_SIZE.'u'BufferedWriter.closed'u'BufferedWriter.mode'u'BufferedWriter.name'_io.BufferedWriteru'Buffered I/O implementation using an in-memory bytes buffer.'u'True if the file is closed.'u'BytesIO.closed'getbuffer_io.BytesIOu'Open a file. + +The mode can be 'r' (default), 'w', 'x' or 'a' for reading, +writing, exclusive creation or appending. The file will be created if it +doesn't exist when opened for writing or appending; it will be truncated +when opened for writing. A FileExistsError will be raised if it already +exists when opened for creating. Opening a file for creating implies +writing so this mode behaves in a similar way to 'w'.Add a '+' to the mode +to allow simultaneous reading and writing. A custom opener can be used by +passing a callable as *opener*. The underlying file descriptor for the file +object is then obtained by calling opener with (*name*, *flags*). +*opener* must return an open file descriptor (passing os.open as *opener* +results in functionality similar to passing None).'_blksizeu'True if the file is closed'u'FileIO.closed'u'True if the file descriptor will be closed by close().'u'FileIO.closefd'closefdu'String giving the file mode'u'FileIO.mode'u'Base class for raw binary I/O.'_io._RawIOBase_io.FileIOu'Codec used when reading a file in universal newlines mode. + +It wraps another incremental decoder, translating \r\n and \r into \n. +It also records the types of newlines encountered. When used with +translate=False, it ensures that the newline sequence is returned in +one piece. When used with decoder=None, it expects unicode strings as +decode input and translates newlines without first invoking an external +decoder.'getstateu'IncrementalNewlineDecoder.newlines'setstate_io.IncrementalNewlineDecoderu'Text I/O implementation using an in-memory buffer. + +The initial_value argument sets the value of object. The newline +argument is like the one of TextIOWrapper's constructor.'u'StringIO.closed'u'StringIO.line_buffering'u'StringIO.newlines'_io.StringIOu'UnsupportedOperation.__weakref__'io.UnsupportedOperation_BufferedIOBase_IOBase_RawIOBase_TextIOBaseu'The io module provides the Python interfaces to stream handling. The +builtin open function is defined in this module. + +At the top of the I/O hierarchy is the abstract base class IOBase. It +defines the basic interface to a stream. Note, however, that there is no +separation between reading and writing to streams; implementations are +allowed to raise an OSError if they do not support a given operation. + +Extending IOBase is RawIOBase which deals simply with the reading and +writing of raw bytes to a stream. FileIO subclasses RawIOBase to provide +an interface to OS files. + +BufferedIOBase deals with buffering on a raw byte stream (RawIOBase). Its +subclasses, BufferedWriter, BufferedReader, and BufferedRWPair buffer +streams that are readable, writable, and both respectively. +BufferedRandom provides a buffered interface to random access +streams. BytesIO is a simple stream of in-memory bytes. + +Another IOBase subclass, TextIOBase, deals with the encoding and decoding +of streams into text. TextIOWrapper, which extends it, is a buffered text +interface to a buffered raw stream (`BufferedIOBase`). Finally, StringIO +is an in-memory stream for text. + +Argument names are not part of the specification, and only the arguments +of open() are intended to be used as keyword arguments. + +data: + +DEFAULT_BUFFER_SIZE + + An int containing the default buffer size used by the module's buffered + I/O classes. open() uses the file's blksize (as obtained by os.stat) if + possible. +'ABDAY_1ABDAY_2ABDAY_3ABDAY_4ABDAY_5ABDAY_6ABDAY_7ABMON_1ABMON_1043ABMON_1144ABMON_12ABMON_2ABMON_3ABMON_4ABMON_5ABMON_6ABMON_7ABMON_841ABMON_949ALT_DIGITSAM_STRCHAR_MAX56CRNCYSTRDAY_1DAY_2DAY_3DAY_4DAY_5DAY_6DAY_7D_FMTD_T_FMT45ERA46ERA_D_FMT47ERA_D_T_FMT48ERA_T_FMTu'locale'u'Error.__weakref__'locale.ErrorLC_ALLLC_COLLATELC_CTYPELC_MESSAGESLC_MONETARYLC_NUMERICLC_TIMEMON_1MON_10MON_11MON_12MON_2MON_3MON_4MON_5MON_6MON_7MON_8MON_9NOEXPRPM_STRRADIXCHAR51THOUSEPT_FMTT_FMT_AMPM52YESEXPRu'Support for POSIX locales.'bind_textdomain_codesetbindtextdomaindcgettextdgettextgettextlocaleconvstrcollstrxfrmtextdomainCHECK_CRC32CHECK_CRC64CHECK_ID_MAXCHECK_NONECHECK_SHA256CHECK_UNKNOWNFILTER_ARMFILTER_ARMTHUMBFILTER_DELTAFILTER_IA644611686018427387905FILTER_LZMA1FILTER_LZMA2FILTER_POWERPCFILTER_SPARCFILTER_X86FORMAT_ALONEFORMAT_AUTOFORMAT_RAWFORMAT_XZu'LZMACompressor(format=FORMAT_XZ, check=-1, preset=None, filters=None) + +Create a compressor object for compressing data incrementally. + +format specifies the container format to use for the output. This can +be FORMAT_XZ (default), FORMAT_ALONE, or FORMAT_RAW. + +check specifies the integrity check to use. For FORMAT_XZ, the default +is CHECK_CRC64. FORMAT_ALONE and FORMAT_RAW do not support integrity +checks; for these formats, check must be omitted, or be CHECK_NONE. + +The settings used by the compressor can be specified either as a +preset compression level (with the 'preset' argument), or in detail +as a custom filter chain (with the 'filters' argument). For FORMAT_XZ +and FORMAT_ALONE, the default is to use the PRESET_DEFAULT preset +level. For FORMAT_RAW, the caller must always specify a filter chain; +the raw compressor does not support preset compression levels. + +preset (if provided) should be an integer in the range 0-9, optionally +OR-ed with the constant PRESET_EXTREME. + +filters (if provided) should be a sequence of dicts. Each dict should +have an entry for "id" indicating the ID of the filter, plus +additional entries for options to the filter. + +For one-shot compression, use the compress() function instead. +'_lzma.LZMACompressorLZMACompressoru'Create a decompressor object for decompressing data incrementally. + + format + Specifies the container format of the input stream. If this is + FORMAT_AUTO (the default), the decompressor will automatically detect + whether the input is FORMAT_XZ or FORMAT_ALONE. Streams created with + FORMAT_RAW cannot be autodetected. + memlimit + Limit the amount of memory used by the decompressor. This will cause + decompression to fail if the input cannot be decompressed within the + given limit. + filters + A custom filter chain. This argument is required for FORMAT_RAW, and + not accepted with any other format. When provided, this should be a + sequence of dicts, each indicating the ID and options for a single + filter. + +For one-shot decompression, use the decompress() function instead.'_lzma.LZMADecompressorLZMADecompressoru'Call to liblzma failed.'u'_lzma'u'LZMAError.__weakref__'_lzma.LZMAErrorLZMAErrorMF_BT2MF_BT3MF_BT4MF_HC3MF_HC4MODE_FASTMODE_NORMALPRESET_DEFAULT2147483648PRESET_EXTREMEu'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_lzma.cpython-38-darwin.so'_decode_filter_properties_encode_filter_propertiesis_check_supported_lzmau'md5.block_size'u'md5.digest_size'u'md5.name'_md5.md5MD5Typeu'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_md5.cpython-38-darwin.so'u'_md5'md5_md532767SEM_VALUE_MAXu'Semaphore/Mutex type'_after_fork_get_value_is_mine_is_zero_rebuildmaxvalue_multiprocessing.SemLockSemLocku'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_multiprocessing.cpython-38-darwin.so'sem_unlinku'Opcode support module.'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_opcode.cpython-38-darwin.so'u'_opcode'stack_effect_opcodeu'Operator interface. + +This module exports a set of functions implemented in C corresponding +to the intrinsic operators of Python. For example, operator.add(x, y) +is equivalent to the expression x+y. The function names are those +used for special methods; variants without leading and trailing +'__' are also provided for convenience.'_compare_digestand_u'attrgetter(attr, ...) --> attrgetter object + +Return a callable object that fetches the given attribute(s) from its operand. +After f = attrgetter('name'), the call f(r) returns r.name. +After g = attrgetter('name', 'date'), the call g(r) returns (r.name, r.date). +After h = attrgetter('name.first', 'name.last'), the call h(r) returns +(r.name.first, r.name.last).'operator.attrgetterattrgetterconcatcontainscountOfdelitemfloordivgegetitemgtiaddiandiconcatifloordivilshiftimatmulimodimulindexOfinvinvertioripowirshiftis_is_notisubu'itemgetter(item, ...) --> itemgetter object + +Return a callable object that fetches the given item(s) from its operand. +After f = itemgetter(2), the call f(r) returns r[2]. +After g = itemgetter(2, 5, 3), the call g(r) returns (r[2], r[5], r[3])'operator.itemgetteritruedivixorlelength_hintlshiftltmatmulu'methodcaller(name, ...) --> methodcaller object + +Return a callable object that calls the given method on its operand. +After f = methodcaller('name'), the call f(r) returns r.name(). +After g = methodcaller('name', 'date', foo=1), the call g(r) returns +r.name('date', foo=1).'operator.methodcallermethodcallermulnenegnot_or_posrshiftsetitemtruedivtruthxor_operatorShared OS X support functions.compiler_fixupcustomize_config_varsget_platform_osxCFLAGSLDFLAGSCPPFLAGSBASECFLAGSBLDSHAREDLDSHAREDCCCXXPY_LDFLAGSPY_CPPFLAGSPY_CORE_CFLAGSPY_CORE_LDFLAGS_UNIVERSAL_CONFIG_VARS_COMPILER_CONFIG_VARS_OSX_SUPPORT_INITIAL__INITPRE_find_executableTries to find 'executable' in the directories listed in 'path'. + + A string listing directories separated by 'os.pathsep'; defaults to + os.environ['PATH']. Returns the complete filename or None if not found. + PATHpathsep.exe_read_outputcommandstringcapture_stderrOutput from successful command execution or None/tmp/_osx_support.%sw+bclosing%s >'%s' 2>&1%s 2>/dev/null >'%s'_find_build_tooltoolnameFind a build tool on current path or using xcrun/usr/bin/xcrun -find %s_SYSTEM_VERSION_get_system_versionReturn the OS X system version as a string/System/Library/CoreServices/SystemVersion.plistProductUserVisibleVersion\s*(.*?)r'ProductUserVisibleVersion\s*'r'(.*?)'_SYSTEM_VERSION_TUPLE_get_system_version_tuple + Return the macOS system version as a tuple + + The return value is safe to use to compare + two version numbers. + osx_version_remove_original_values_config_varsRemove original unmodified values for testing_save_modified_valuecvnewvalueSave modified and original unmodified value of configuration varoldvalue_cache_default_sysroot_default_sysrootcc Returns the root of the default SDK for this system, or '/' %s -c -E -v - End of search list/usr/include.sdk/usr/include_supports_universal_buildsReturns True if universal builds are supported on this system_supports_arm64_buildsReturns True if arm64 builds are supported on this system_find_appropriate_compilerFind appropriate C compiler for extension module buildsoldccclanggcc'%s' --version'"'"'llvm-gccCannot locate working compilercv_split++_remove_universal_flagsRemove all universal build arguments from config vars-arch\s+\w+\s-isysroot\s*\S+_remove_unsupported_archsRemove any unsupported archs from config vars-arch\s+ppcecho 'int main{};' | '%s' -c -arch ppc -x c -o /dev/null /dev/null 2>/dev/null"""echo 'int main{};' | """"""'%s' -c -arch ppc -x c -o /dev/null /dev/null 2>/dev/null"""-arch\s+ppc\w*\s_override_all_archsAllow override of all archs with ARCHFLAGS env varARCHFLAGSarch-arch_check_for_unavailable_sdkRemove references to any SDKs not available-isysroot\s*(\S+)sdk-isysroot\s*\S+(?:\s|$)compiler_socc_args + This function will strip '-isysroot PATH' and '-arch ARCH' from the + compile flags if the user has specified one them in extra_compile_flags. + + This is needed because '-arch ARCH' adds another architecture to the + build, without a way to remove an architecture. Furthermore GCC will + barf if multiple '-isysroot' arguments are present. + stripArchstripSysroot-isysrootidxarm64sysrootargvarisdirCompiling with an SDK that doesn't seem to exist: %sPlease check your Xcode installationCustomize Python build configuration variables. + + Called internally from sysconfig with a mutable mapping + containing name/value pairs parsed from the configured + makefile used to build this interpreter. Returns + the mapping updated as needed to reflect the environment + in which the interpreter is running; in the case of + a Python from a binary installer, the installed + environment may be very different from the build + environment, i.e. different OS levels, different + built tools, different available CPU architectures. + + This customization is performed whenever + distutils.sysconfig.get_config_vars() is first + called. It may be used in environments where no + compilers are present, i.e. when installing pure + Python dists. Customization of compiler paths + and detection of unavailable archs is deferred + until the first extension module build is + requested (in distutils.sysconfig.customize_compiler). + + Currently called from distutils.sysconfig + Customize compiler path and configuration variables. + + This customization is performed when the first + extension module build is requested + in distutils.sysconfig.customize_compiler). + osnamemachineFilter values for get_platform()MACOSX_DEPLOYMENT_TARGETmacvermacreleasemacosxfat-arch\s+(\S+)archsx86_64universal2i386ppcintelfat3ppc64fat64universalDon't know machine value for archs=%rPowerPCPower_Macintosh# configuration variables that may contain universal build flags,# like "-arch" or "-isdkroot", that may need customization for# the user environment# configuration variables that may contain compiler calls# prefix added to original configuration variable names# the file exists, we have a shot at spawn working# Similar to os.popen(commandstring, "r").read(),# but without actually using os.popen because that# function is not usable during python bootstrap.# tempfile is also not available then.# Reading this plist is a documented way to get the system# version (see the documentation for the Gestalt Manager)# We avoid using platform.mac_ver to avoid possible bootstrap issues during# the build of Python itself (distutils is used to build standard library# extensions).# We're on a plain darwin box, fall back to the default# behaviour.# else: fall back to the default behaviour# This is needed for higher-level cross-platform tests of get_platform.# As an approximation, we assume that if we are running on 10.4 or above,# then we are running with an Xcode environment that supports universal# builds, in particular -isysroot and -arch arguments to the compiler. This# is in support of allowing 10.4 universal builds to run on 10.3.x systems.# There are two sets of systems supporting macOS/arm64 builds:# 1. macOS 11 and later, unconditionally# 2. macOS 10.15 with Xcode 12.2 or later# For now the second category is ignored.# Issue #13590:# The OSX location for the compiler varies between OSX# (or rather Xcode) releases. With older releases (up-to 10.5)# the compiler is in /usr/bin, with newer releases the compiler# can only be found inside Xcode.app if the "Command Line Tools"# are not installed.# Furthermore, the compiler that can be used varies between# Xcode releases. Up to Xcode 4 it was possible to use 'gcc-4.2'# as the compiler, after that 'clang' should be used because# gcc-4.2 is either not present, or a copy of 'llvm-gcc' that# miscompiles Python.# skip checks if the compiler was overridden with a CC env variable# The CC config var might contain additional arguments.# Ignore them while searching.# Compiler is not found on the shell search PATH.# Now search for clang, first on PATH (if the Command LIne# Tools have been installed in / or if the user has provided# another location via CC). If not found, try using xcrun# to find an uninstalled clang (within a selected Xcode).# NOTE: Cannot use subprocess here because of bootstrap# issues when building Python itself (and os.popen is# implemented on top of subprocess and is therefore not# usable as well)# Compiler is GCC, check if it is LLVM-GCC# Found LLVM-GCC, fall back to clang# Found a replacement compiler.# Modify config vars using new compiler, if not already explicitly# overridden by an env variable, preserving additional arguments.# Do not alter a config var explicitly overridden by env var# Different Xcode releases support different sets for '-arch'# flags. In particular, Xcode 4.x no longer supports the# PPC architectures.# This code automatically removes '-arch ppc' and '-arch ppc64'# when these are not supported. That makes it possible to# build extensions on OSX 10.7 and later with the prebuilt# 32-bit installer on the python.org website.# issues when building Python itself# The compile failed for some reason. Because of differences# across Xcode and compiler versions, there is no reliable way# to be sure why it failed. Assume here it was due to lack of# PPC support and remove the related '-arch' flags from each# config variables not explicitly overridden by an environment# variable. If the error was for some other reason, we hope the# failure will show up again when trying to compile an extension# module.# NOTE: This name was introduced by Apple in OSX 10.5 and# is used by several scripting languages distributed with# that OS release.# If we're on OSX 10.5 or later and the user tries to# compile an extension using an SDK that is not present# on the current machine it is better to not use an SDK# than to fail. This is particularly important with# the standalone Command Line Tools alternative to a# full-blown Xcode install since the CLT packages do not# provide SDKs. If the SDK is not present, it is assumed# that the header files and dev libs have been installed# to /usr and /System/Library by either a standalone CLT# package or the CLT component within Xcode.# OSX before 10.4.0, these don't support -arch and -isysroot at# all.# Strip this argument and the next one:# Look for "-arch arm64" and drop that# User specified different -arch flags in the environ,# see also distutils.sysconfig# It's '-isysroot/some/path' in one arg# Check if the SDK that is used during compilation actually exists,# the universal build requires the usage of a universal SDK and not all# users have that installed by default.# On Mac OS X before 10.4, check if -arch and -isysroot# are in CFLAGS or LDFLAGS and remove them if they are.# This is needed when building extensions on a 10.3 system# using a universal build of python.# Allow user to override all archs with ARCHFLAGS env var# Remove references to sdks that are not found# Find a compiler to use for extension module builds# Remove ppc arch flags if not supported here# called from get_platform() in sysconfig and distutils.util# For our purposes, we'll assume that the system version from# distutils' perspective is what MACOSX_DEPLOYMENT_TARGET is set# to. This makes the compatibility story a bit more sane because the# machine is going to compile and link as if it were# MACOSX_DEPLOYMENT_TARGET.# Use the original CFLAGS value, if available, so that we# return the same machine type for the platform string.# Otherwise, distutils may consider this a cross-compiling# case and disallow installs.# assume no universal support# The universal build will build fat binaries, but not on# systems before 10.4# On OSX the machine type returned by uname is always the# 32-bit variant, even if the executable architecture is# the 64-bit variant# Pick a sane name for the PPC architecture.# See 'i386' caseb'Shared OS X support functions.'u'Shared OS X support functions.'b'compiler_fixup'u'compiler_fixup'b'customize_config_vars'u'customize_config_vars'b'customize_compiler'u'customize_compiler'b'get_platform_osx'u'get_platform_osx'b'CFLAGS'u'CFLAGS'b'LDFLAGS'u'LDFLAGS'b'CPPFLAGS'u'CPPFLAGS'b'BASECFLAGS'u'BASECFLAGS'b'BLDSHARED'u'BLDSHARED'b'LDSHARED'u'LDSHARED'b'CC'u'CC'b'CXX'u'CXX'b'PY_LDFLAGS'u'PY_LDFLAGS'b'PY_CPPFLAGS'u'PY_CPPFLAGS'b'PY_CORE_CFLAGS'u'PY_CORE_CFLAGS'b'PY_CORE_LDFLAGS'u'PY_CORE_LDFLAGS'b'_OSX_SUPPORT_INITIAL_'u'_OSX_SUPPORT_INITIAL_'b'Tries to find 'executable' in the directories listed in 'path'. + + A string listing directories separated by 'os.pathsep'; defaults to + os.environ['PATH']. Returns the complete filename or None if not found. + 'u'Tries to find 'executable' in the directories listed in 'path'. + + A string listing directories separated by 'os.pathsep'; defaults to + os.environ['PATH']. Returns the complete filename or None if not found. + 'b'PATH'u'PATH'b'.exe'u'.exe'b'Output from successful command execution or None'u'Output from successful command execution or None'b'/tmp/_osx_support.%s'u'/tmp/_osx_support.%s'b'w+b'u'w+b'b'%s >'%s' 2>&1'u'%s >'%s' 2>&1'b'%s 2>/dev/null >'%s''u'%s 2>/dev/null >'%s''b'Find a build tool on current path or using xcrun'u'Find a build tool on current path or using xcrun'b'/usr/bin/xcrun -find %s'u'/usr/bin/xcrun -find %s'b'Return the OS X system version as a string'u'Return the OS X system version as a string'b'/System/Library/CoreServices/SystemVersion.plist'u'/System/Library/CoreServices/SystemVersion.plist'b'ProductUserVisibleVersion\s*(.*?)'u'ProductUserVisibleVersion\s*(.*?)'b' + Return the macOS system version as a tuple + + The return value is safe to use to compare + two version numbers. + 'u' + Return the macOS system version as a tuple + + The return value is safe to use to compare + two version numbers. + 'b'Remove original unmodified values for testing'u'Remove original unmodified values for testing'b'Save modified and original unmodified value of configuration var'u'Save modified and original unmodified value of configuration var'b' Returns the root of the default SDK for this system, or '/' 'u' Returns the root of the default SDK for this system, or '/' 'b'%s -c -E -v - 'u'#include <...>'b'End of search list'u'End of search list'b'/usr/include'u'/usr/include'b'.sdk/usr/include'u'.sdk/usr/include'b'Returns True if universal builds are supported on this system'u'Returns True if universal builds are supported on this system'b'Returns True if arm64 builds are supported on this system'u'Returns True if arm64 builds are supported on this system'b'Find appropriate C compiler for extension module builds'u'Find appropriate C compiler for extension module builds'b'clang'u'clang'b'gcc'u'gcc'b''%s' --version'u''%s' --version'b''"'"''u''"'"''b'llvm-gcc'u'llvm-gcc'b'Cannot locate working compiler'u'Cannot locate working compiler'b'++'u'++'b'Remove all universal build arguments from config vars'u'Remove all universal build arguments from config vars'b'-arch\s+\w+\s'u'-arch\s+\w+\s'b'-isysroot\s*\S+'u'-isysroot\s*\S+'b'Remove any unsupported archs from config vars'u'Remove any unsupported archs from config vars'b'-arch\s+ppc'u'-arch\s+ppc'b'echo 'int main{};' | '%s' -c -arch ppc -x c -o /dev/null /dev/null 2>/dev/null'u'echo 'int main{};' | '%s' -c -arch ppc -x c -o /dev/null /dev/null 2>/dev/null'b'-arch\s+ppc\w*\s'u'-arch\s+ppc\w*\s'b'Allow override of all archs with ARCHFLAGS env var'u'Allow override of all archs with ARCHFLAGS env var'b'ARCHFLAGS'u'ARCHFLAGS'b'-arch'u'-arch'b'Remove references to any SDKs not available'u'Remove references to any SDKs not available'b'-isysroot\s*(\S+)'u'-isysroot\s*(\S+)'b'-isysroot\s*\S+(?:\s|$)'u'-isysroot\s*\S+(?:\s|$)'b' + This function will strip '-isysroot PATH' and '-arch ARCH' from the + compile flags if the user has specified one them in extra_compile_flags. + + This is needed because '-arch ARCH' adds another architecture to the + build, without a way to remove an architecture. Furthermore GCC will + barf if multiple '-isysroot' arguments are present. + 'u' + This function will strip '-isysroot PATH' and '-arch ARCH' from the + compile flags if the user has specified one them in extra_compile_flags. + + This is needed because '-arch ARCH' adds another architecture to the + build, without a way to remove an architecture. Furthermore GCC will + barf if multiple '-isysroot' arguments are present. + 'b'-isysroot'u'-isysroot'b'arm64'u'arm64'b'Compiling with an SDK that doesn't seem to exist: %s'u'Compiling with an SDK that doesn't seem to exist: %s'b'Please check your Xcode installation'u'Please check your Xcode installation'b'Customize Python build configuration variables. + + Called internally from sysconfig with a mutable mapping + containing name/value pairs parsed from the configured + makefile used to build this interpreter. Returns + the mapping updated as needed to reflect the environment + in which the interpreter is running; in the case of + a Python from a binary installer, the installed + environment may be very different from the build + environment, i.e. different OS levels, different + built tools, different available CPU architectures. + + This customization is performed whenever + distutils.sysconfig.get_config_vars() is first + called. It may be used in environments where no + compilers are present, i.e. when installing pure + Python dists. Customization of compiler paths + and detection of unavailable archs is deferred + until the first extension module build is + requested (in distutils.sysconfig.customize_compiler). + + Currently called from distutils.sysconfig + 'u'Customize Python build configuration variables. + + Called internally from sysconfig with a mutable mapping + containing name/value pairs parsed from the configured + makefile used to build this interpreter. Returns + the mapping updated as needed to reflect the environment + in which the interpreter is running; in the case of + a Python from a binary installer, the installed + environment may be very different from the build + environment, i.e. different OS levels, different + built tools, different available CPU architectures. + + This customization is performed whenever + distutils.sysconfig.get_config_vars() is first + called. It may be used in environments where no + compilers are present, i.e. when installing pure + Python dists. Customization of compiler paths + and detection of unavailable archs is deferred + until the first extension module build is + requested (in distutils.sysconfig.customize_compiler). + + Currently called from distutils.sysconfig + 'b'Customize compiler path and configuration variables. + + This customization is performed when the first + extension module build is requested + in distutils.sysconfig.customize_compiler). + 'u'Customize compiler path and configuration variables. + + This customization is performed when the first + extension module build is requested + in distutils.sysconfig.customize_compiler). + 'b'Filter values for get_platform()'u'Filter values for get_platform()'b'MACOSX_DEPLOYMENT_TARGET'u'MACOSX_DEPLOYMENT_TARGET'b'macosx'u'macosx'b'fat'u'fat'b'-arch\s+(\S+)'u'-arch\s+(\S+)'b'x86_64'u'x86_64'b'universal2'u'universal2'b'i386'u'i386'b'ppc'u'ppc'b'intel'u'intel'b'fat3'u'fat3'b'ppc64'u'ppc64'b'fat64'u'fat64'b'universal'u'universal'b'Don't know machine value for archs=%r'u'Don't know machine value for archs=%r'b'PowerPC'u'PowerPC'b'Power_Macintosh'u'Power_Macintosh'u'_osx_support'Email address parsing code. + +Lifted directly from rfc822.py. This should eventually be rewritten. +mktime_tzparsedateparsedate_tzcalendarSPACEEMPTYSTRINGCOMMASPACEjanfebmaraprmayjunjulaugnovjanuaryfebruarymarchapriljunejulyaugustseptemberoctobernovemberdecember_monthnamesmontuewedthufrisatsun_daynamesUTUTCGMTADTESTEDT600CSTCDT700MSTMDT800PSTPDT_timezonesConvert a date string to a time tuple. + + Accounts for military timezones. + _parsedate_tzConvert date to extended time tuple. + + The last (additional) element is the time zone offset in seconds, except if + the timezone was specified as -0000. In that case the last element is + None. This indicates a UTC timestamp that explicitly declaims knowledge of + the source timezone, as opposed to a +0000 timestamp that indicates the + source timezone really was UTC. + + stuffddmmyytmthhtmmtss6819002000tzoffsettzsign3600Convert a time string to a time tuple.Turn a 10-tuple as returned by parsedate_tz() into a POSIX timestamp.mktimetimegmPrepare string to be used in a quoted string. + + Turns backslash and double quote characters into quoted pairs. These + are the only characters that need to be quoted inside a quoted string. + Does not add the surrounding double quotes. + \"AddrlistClassAddress parser class by Ben Escoto. + + To understand what this class does, it helps to have a copy of RFC 2822 in + front of you. + + Note: this class interface is deprecated and may be removed in the future. + Use email.utils.AddressList instead. + fieldInitialize a new instance. + + `field' is an unparsed address header field, containing + one or more addresses. + ()<>@,:;."[]specials LWSCRFWSatomendsphraseendscommentlistgotonextSkip white space and extract comments.wslist + getcommentgetaddrlistParse all addresses. + + Returns a list containing all of the addresses. + getaddressadParse the next address.oldposoldclgetphraselistplistreturnlist.@getaddrspecaddrspecfieldlengetrouteaddrrouteaddr (Parse a route address (Return-path value). + + This method just skips all the route stuff and returns the addrspec. + expectrouteadlistgetdomainParse an RFC 2822 addr-spec.aslistpreserve_ws"%s"getquotegetatomdomainGet the complete domain name from an address.sdlistgetdomainliteralgetdelimitedbegincharendcharsallowcommentsParse a header fragment delimited by special characters. + + `beginchar' is the start character for the fragment. + If self is not looking at an instance of `beginchar' then + getdelimited returns the empty string. + + `endchars' is a sequence of allowable end-delimiting characters. + Parsing stops when one of these is encountered. + + If `allowcomments' is non-zero, embedded RFC 2822 comments are allowed + within the parsed fragment. + slistGet a quote-delimited fragment from self's field." Get a parenthesis-delimited fragment from self's field.) Parse an RFC 2822 domain-literal.] Parse an RFC 2822 atom. + + Optional atomends specifies a different set of end token delimiters + (the default is to use self.atomends). This is used e.g. in + getphraselist() since phrase endings must not include the `.' (which + is legal in phrases).atomlistParse a sequence of RFC 2822 phrases. + + A phrase is a sequence of words, which are in turn either RFC 2822 + atoms or quoted-strings. Phrases are canonicalized by squeezing all + runs of continuous whitespace into one space. + AddressListAn AddressList encapsulates a list of parsed RFC 2822 addresses.addresslistnewaddr# Copyright (C) 2002-2007 Python Software Foundation# Parse a date field# The timezone table does not include the military time zones defined# in RFC822, other than Z. According to RFC1123, the description in# RFC822 gets the signs wrong, so we can't rely on any such time# zones. RFC1123 recommends that numeric timezone indicators be used# instead of timezone names.# Atlantic (used in Canada)# Eastern# Central# Mountain# Pacific# This happens for whitespace-only input.# The FWS after the comma after the day-of-week is optional, so search and# adjust for this.# There's a dayname here. Skip it# RFC 850 date, deprecated# Dummy tz# Some non-compliant MUAs use '.' to separate time elements.# Check for a yy specified in two-digit format, then convert it to the# appropriate four-digit format, according to the POSIX standard. RFC 822# calls for a two-digit yy, but RFC 2822 (which obsoletes RFC 822)# mandates a 4-digit yy. For more information, see the documentation for# the time module.# The year is between 1969 and 1999 (inclusive).# The year is between 2000 and 2068 (inclusive).# Convert a timezone offset into seconds ; -0500 -> -18000# Daylight Saving Time flag is set to -1, since DST is unknown.# No zone info, so localtime is better assumption than GMT# Note that RFC 2822 now specifies `.' as obs-phrase, meaning that it# is obsolete syntax. RFC 2822 requires that we recognize obsolete# syntax, so allow dots in phrases.# Bad email address technically, no domain.# email address is just an addrspec# this isn't very efficient since we start over# address is a group# Address is a phrase then a route addr# Invalid domain, return an empty address instead of returning a# local part to denote failed parsing.# bpo-34155: Don't parse domains with two `@` like# `a@malicious.org@important.com`.# have already advanced pos from getcomment# Set union# Set union, in-place# Set difference# Set difference, in-place# Make indexing, slices, and 'in' workb'Email address parsing code. + +Lifted directly from rfc822.py. This should eventually be rewritten. +'u'Email address parsing code. + +Lifted directly from rfc822.py. This should eventually be rewritten. +'b'mktime_tz'u'mktime_tz'b'parsedate'u'parsedate'b'parsedate_tz'u'parsedate_tz'b'jan'u'jan'b'feb'u'feb'b'mar'u'mar'b'apr'u'apr'b'may'u'may'b'jun'u'jun'b'jul'u'jul'b'aug'u'aug'b'sep'u'sep'b'oct'u'oct'b'nov'u'nov'b'dec'u'dec'b'january'u'january'b'february'u'february'b'march'u'march'b'april'u'april'b'june'u'june'b'july'u'july'b'august'u'august'b'september'u'september'b'october'u'october'b'november'u'november'b'december'u'december'b'mon'u'mon'b'tue'u'tue'b'wed'u'wed'b'thu'u'thu'b'fri'u'fri'b'sat'u'sat'b'sun'u'sun'b'UT'u'UT'b'UTC'u'UTC'b'GMT'u'GMT'b'AST'u'AST'b'ADT'u'ADT'b'EST'u'EST'b'EDT'u'EDT'b'CST'u'CST'b'CDT'u'CDT'b'MST'u'MST'b'MDT'u'MDT'b'PST'u'PST'b'PDT'u'PDT'b'Convert a date string to a time tuple. + + Accounts for military timezones. + 'u'Convert a date string to a time tuple. + + Accounts for military timezones. + 'b'Convert date to extended time tuple. + + The last (additional) element is the time zone offset in seconds, except if + the timezone was specified as -0000. In that case the last element is + None. This indicates a UTC timestamp that explicitly declaims knowledge of + the source timezone, as opposed to a +0000 timestamp that indicates the + source timezone really was UTC. + + 'u'Convert date to extended time tuple. + + The last (additional) element is the time zone offset in seconds, except if + the timezone was specified as -0000. In that case the last element is + None. This indicates a UTC timestamp that explicitly declaims knowledge of + the source timezone, as opposed to a +0000 timestamp that indicates the + source timezone really was UTC. + + 'b'0'u'0'b'Convert a time string to a time tuple.'u'Convert a time string to a time tuple.'b'Turn a 10-tuple as returned by parsedate_tz() into a POSIX timestamp.'u'Turn a 10-tuple as returned by parsedate_tz() into a POSIX timestamp.'b'Prepare string to be used in a quoted string. + + Turns backslash and double quote characters into quoted pairs. These + are the only characters that need to be quoted inside a quoted string. + Does not add the surrounding double quotes. + 'u'Prepare string to be used in a quoted string. + + Turns backslash and double quote characters into quoted pairs. These + are the only characters that need to be quoted inside a quoted string. + Does not add the surrounding double quotes. + 'b'\"'u'\"'b'Address parser class by Ben Escoto. + + To understand what this class does, it helps to have a copy of RFC 2822 in + front of you. + + Note: this class interface is deprecated and may be removed in the future. + Use email.utils.AddressList instead. + 'u'Address parser class by Ben Escoto. + + To understand what this class does, it helps to have a copy of RFC 2822 in + front of you. + + Note: this class interface is deprecated and may be removed in the future. + Use email.utils.AddressList instead. + 'b'Initialize a new instance. + + `field' is an unparsed address header field, containing + one or more addresses. + 'u'Initialize a new instance. + + `field' is an unparsed address header field, containing + one or more addresses. + 'b'()<>@,:;."[]'u'()<>@,:;."[]'b' 'u' 'b'Skip white space and extract comments.'u'Skip white space and extract comments.'b' + 'u' + 'b'Parse all addresses. + + Returns a list containing all of the addresses. + 'u'Parse all addresses. + + Returns a list containing all of the addresses. + 'b'Parse the next address.'u'Parse the next address.'b'.@'u'.@'b' ('u' ('b'Parse a route address (Return-path value). + + This method just skips all the route stuff and returns the addrspec. + 'u'Parse a route address (Return-path value). + + This method just skips all the route stuff and returns the addrspec. + 'b'Parse an RFC 2822 addr-spec.'u'Parse an RFC 2822 addr-spec.'b'"%s"'u'"%s"'b'Get the complete domain name from an address.'u'Get the complete domain name from an address.'b'Parse a header fragment delimited by special characters. + + `beginchar' is the start character for the fragment. + If self is not looking at an instance of `beginchar' then + getdelimited returns the empty string. + + `endchars' is a sequence of allowable end-delimiting characters. + Parsing stops when one of these is encountered. + + If `allowcomments' is non-zero, embedded RFC 2822 comments are allowed + within the parsed fragment. + 'u'Parse a header fragment delimited by special characters. + + `beginchar' is the start character for the fragment. + If self is not looking at an instance of `beginchar' then + getdelimited returns the empty string. + + `endchars' is a sequence of allowable end-delimiting characters. + Parsing stops when one of these is encountered. + + If `allowcomments' is non-zero, embedded RFC 2822 comments are allowed + within the parsed fragment. + 'b'Get a quote-delimited fragment from self's field.'u'Get a quote-delimited fragment from self's field.'b'" 'u'" 'b'Get a parenthesis-delimited fragment from self's field.'u'Get a parenthesis-delimited fragment from self's field.'b') 'u') 'b'Parse an RFC 2822 domain-literal.'u'Parse an RFC 2822 domain-literal.'b'] 'u'] 'b'Parse an RFC 2822 atom. + + Optional atomends specifies a different set of end token delimiters + (the default is to use self.atomends). This is used e.g. in + getphraselist() since phrase endings must not include the `.' (which + is legal in phrases).'u'Parse an RFC 2822 atom. + + Optional atomends specifies a different set of end token delimiters + (the default is to use self.atomends). This is used e.g. in + getphraselist() since phrase endings must not include the `.' (which + is legal in phrases).'b'Parse a sequence of RFC 2822 phrases. + + A phrase is a sequence of words, which are in turn either RFC 2822 + atoms or quoted-strings. Phrases are canonicalized by squeezing all + runs of continuous whitespace into one space. + 'u'Parse a sequence of RFC 2822 phrases. + + A phrase is a sequence of words, which are in turn either RFC 2822 + atoms or quoted-strings. Phrases are canonicalized by squeezing all + runs of continuous whitespace into one space. + 'b'An AddressList encapsulates a list of parsed RFC 2822 addresses.'u'An AddressList encapsulates a list of parsed RFC 2822 addresses.'u'email._parseaddr'u'_parseaddr'u'Wrapper for potentially out-of-band buffers'pickle.PickleBufferPickleBufferu'PickleError.__weakref__'_pickle.PickleErrorPickleErroru'This takes a binary file for writing a pickle data stream. + +The optional *protocol* argument tells the pickler to use the given +protocol; supported protocols are 0, 1, 2, 3, 4 and 5. The default +protocol is 4. It was introduced in Python 3.4, and is incompatible +with previous versions. + +Specifying a negative protocol version selects the highest protocol +version supported. The higher the protocol used, the more recent the +version of Python needed to read the pickle produced. + +The *file* argument must have a write() method that accepts a single +bytes argument. It can thus be a file object opened for binary +writing, an io.BytesIO instance, or any other custom object that meets +this interface. + +If *fix_imports* is True and protocol is less than 3, pickle will try +to map the new Python 3 names to the old module names used in Python +2, so that the pickle data stream is readable with Python 2. + +If *buffer_callback* is None (the default), buffer views are +serialized into *file* as part of the pickle stream. + +If *buffer_callback* is not None, then it can be called any number +of times with a buffer view. If the callback returns a false value +(such as None), the given buffer is out-of-band; otherwise the +buffer is serialized in-band, i.e. inside the pickle stream. + +It is an error if *buffer_callback* is not None and *protocol* +is None or smaller than 5.'clear_memodispatch_tablefastu'Pickler.memo'memou'Pickler.persistent_id'persistent_id_pickle.PicklerPickler_pickle.PicklingErroru'This takes a binary file for reading a pickle data stream. + +The protocol version of the pickle is detected automatically, so no +protocol argument is needed. Bytes past the pickled object's +representation are ignored. + +The argument *file* must have two methods, a read() method that takes +an integer argument, and a readline() method that requires no +arguments. Both methods should return bytes. Thus *file* can be a +binary file object opened for reading, an io.BytesIO object, or any +other custom object that meets this interface. + +Optional keyword arguments are *fix_imports*, *encoding* and *errors*, +which are used to control compatibility support for pickle stream +generated by Python 2. If *fix_imports* is True, pickle will try to +map the old Python 2 names to the new names used in Python 3. The +*encoding* and *errors* tell pickle how to decode 8-bit string +instances pickled by Python 2; these default to 'ASCII' and 'strict', +respectively. The *encoding* can be 'bytes' to read these 8-bit +string instances as bytes objects.'find_classloadu'Unpickler.memo'u'Unpickler.persistent_load'persistent_load_pickle.UnpicklerUnpickler_pickle.UnpicklingErrorUnpicklingErroru'Optimized C implementation for the Python pickle module.'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_pickle.cpython-38-darwin.so'Policy framework for the email package. + +Allows fine grained feature control of how the package parses and emits data. +_charsetemail.utils_has_surrogatesPolicyCompat32compat32_PolicyBasePolicy Object basic framework. + + This class is useless unless subclassed. A subclass should define + class attributes with defaults for any values that are to be + managed by the Policy object. The constructor will then allow + non-default values to be set for these attributes at instance + creation time. The instance will be callable, taking these same + attributes keyword arguments, and returning a new instance + identical to the called instance except for those values changed + by the keyword arguments. Instances may be added, yielding new + instances with any non-default values from the right hand + operand overriding those in the left hand operand. That is, + + A + B == A() + + The repr of an instance can be used to reconstruct the object + if and only if the repr of the values can be used to reconstruct + those values. + + Create new Policy, possibly overriding some defaults. + + See class docstring for a list of overridable attributes. + + {!r} is an invalid keyword argument for {}{}={!r}cloneReturn a new instance with specified attributes changed. + + The new instance has the same attribute values as the current object, + except for the changes passed in as keyword arguments. + + newpolicy{!r} object attribute {!r} is read-only{!r} object has no attribute {!r}Non-default values from right operand override those from left. + + The object returned is a new instance of the subclass. + + _append_docadded_doc_extend_docstringsControls for how messages are interpreted and formatted. + + Most of the classes and many of the methods in the email package accept + Policy objects as parameters. A Policy object contains a set of values and + functions that control how input is interpreted and how output is rendered. + For example, the parameter 'raise_on_defect' controls whether or not an RFC + violation results in an error being raised or not, while 'max_line_length' + controls the maximum length of output lines when a Message is serialized. + + Any valid attribute may be overridden when a Policy is created by passing + it as a keyword argument to the constructor. Policy objects are immutable, + but a new Policy object can be created with only certain values changed by + calling the Policy instance with keyword arguments. Policy objects can + also be added, producing a new Policy object in which the non-default + attributes set in the right hand operand overwrite those specified in the + left operand. + + Settable attributes: + + raise_on_defect -- If true, then defects should be raised as errors. + Default: False. + + linesep -- string containing the value to use as separation + between output lines. Default '\n'. + + cte_type -- Type of allowed content transfer encodings + + 7bit -- ASCII only + 8bit -- Content-Transfer-Encoding: 8bit is allowed + + Default: 8bit. Also controls the disposition of + (RFC invalid) binary data in headers; see the + documentation of the binary_fold method. + + max_line_length -- maximum length of lines, excluding 'linesep', + during serialization. None or 0 means no line + wrapping is done. Default is 78. + + mangle_from_ -- a flag that, when True escapes From_ lines in the + body of the message by putting a `>' in front of + them. This is used when the message is being + serialized by a generator. Default: True. + + message_factory -- the class to use to create new message objects. + If the value is None, the default is Message. + + r"""raise_on_defectlinesep8bitcte_type78max_line_lengthmangle_from_message_factoryhandle_defectdefectBased on policy, either raise defect or call register_defect. + + handle_defect(obj, defect) + + defect should be a Defect subclass, but in any case must be an + Exception subclass. obj is the object on which the defect should be + registered if it is not raised. If the raise_on_defect is True, the + defect is raised as an error, otherwise the object and the defect are + passed to register_defect. + + This method is intended to be called by parsers that discover defects. + The email package parsers always call it with Defect instances. + + register_defectRecord 'defect' on 'obj'. + + Called by handle_defect if raise_on_defect is False. This method is + part of the Policy API so that Policy subclasses can implement custom + defect handling. The default implementation calls the append method of + the defects attribute of obj. The objects used by the email package by + default that get passed to this method will always have a defects + attribute with an append method. + + header_max_countReturn the maximum allowed number of headers named 'name'. + + Called when a header is added to a Message object. If the returned + value is not 0 or None, and there are already a number of headers with + the name 'name' equal to the value returned, a ValueError is raised. + + Because the default behavior of Message's __setitem__ is to append the + value to the list of headers, it is easy to create duplicate headers + without realizing it. This method allows certain headers to be limited + in the number of instances of that header that may be added to a + Message programmatically. (The limit is not observed by the parser, + which will faithfully produce as many headers as exist in the message + being parsed.) + + The default implementation returns None for all header names. + header_source_parsesourcelinesGiven a list of linesep terminated strings constituting the lines of + a single header, return the (name, value) tuple that should be stored + in the model. The input lines should retain their terminating linesep + characters. The lines passed in by the email package may contain + surrogateescaped binary data. + header_store_parseGiven the header name and the value provided by the application + program, return the (name, value) that should be stored in the model. + header_fetch_parseGiven the header name and the value from the model, return the value + to be returned to the application program that is requesting that + header. The value passed in by the email package may contain + surrogateescaped binary data if the lines were parsed by a BytesParser. + The returned value should not contain any surrogateescaped data. + + Given the header name and the value from the model, return a string + containing linesep characters that implement the folding of the header + according to the policy controls. The value passed in by the email + package may contain surrogateescaped binary data if the lines were + parsed by a BytesParser. The returned value should not contain any + surrogateescaped data. + + fold_binaryGiven the header name and the value from the model, return binary + data containing linesep characters that implement the folding of the + header according to the policy controls. The value passed in by the + email package may contain surrogateescaped binary data. + + + + This particular policy is the backward compatibility Policy. It + replicates the behavior of the email package version 5.1. + _sanitize_headerHeaderUNKNOWN8BITheader_name+ + The name is parsed as everything up to the ':' and returned unmodified. + The value is determined by stripping leading whitespace off the + remainder of the first line, joining all subsequent lines together, and + stripping any trailing carriage return or linefeed characters. + + + + The name and value are returned unmodified. + + + If the value contains binary data, it is converted into a Header object + using the unknown-8bit charset. Otherwise it is returned unmodified. + + + Headers are folded using the Header folding algorithm, which preserves + existing line breaks in the value, and wraps each resulting line to the + max_line_length. Non-ASCII binary data are CTE encoded using the + unknown-8bit charset. + + _foldsanitize+ + Headers are folded using the Header folding algorithm, which preserves + existing line breaks in the value, and wraps each resulting line to the + max_line_length. If cte_type is 7bit, non-ascii binary data is CTE + encoded using the unknown-8bit charset. Otherwise the original source + header is used, with its existing line breaks and/or binary data. + + 7bitfolded%s: maxlinelen# If the header value contains surrogates, return a Header using# the unknown-8bit charset to encode the bytes as encoded words.# Assume it is already a header object# If we have raw 8bit data in a byte string, we have no idea# what the encoding is. There is no safe way to split this# string. If it's ascii-subset, then we could do a normal# ascii split, but if it's multibyte then we could break the# string. There's no way to know so the least harm seems to# be to not split the string and risk it being too long.# Assume it is a Header-like object.# The Header class interprets a value of None for maxlinelen as the# default value of 78, as recommended by RFC 2822.b'Policy framework for the email package. + +Allows fine grained feature control of how the package parses and emits data. +'u'Policy framework for the email package. + +Allows fine grained feature control of how the package parses and emits data. +'b'Policy'u'Policy'b'Compat32'u'Compat32'b'compat32'u'compat32'b'Policy Object basic framework. + + This class is useless unless subclassed. A subclass should define + class attributes with defaults for any values that are to be + managed by the Policy object. The constructor will then allow + non-default values to be set for these attributes at instance + creation time. The instance will be callable, taking these same + attributes keyword arguments, and returning a new instance + identical to the called instance except for those values changed + by the keyword arguments. Instances may be added, yielding new + instances with any non-default values from the right hand + operand overriding those in the left hand operand. That is, + + A + B == A() + + The repr of an instance can be used to reconstruct the object + if and only if the repr of the values can be used to reconstruct + those values. + + 'u'Policy Object basic framework. + + This class is useless unless subclassed. A subclass should define + class attributes with defaults for any values that are to be + managed by the Policy object. The constructor will then allow + non-default values to be set for these attributes at instance + creation time. The instance will be callable, taking these same + attributes keyword arguments, and returning a new instance + identical to the called instance except for those values changed + by the keyword arguments. Instances may be added, yielding new + instances with any non-default values from the right hand + operand overriding those in the left hand operand. That is, + + A + B == A() + + The repr of an instance can be used to reconstruct the object + if and only if the repr of the values can be used to reconstruct + those values. + + 'b'Create new Policy, possibly overriding some defaults. + + See class docstring for a list of overridable attributes. + + 'u'Create new Policy, possibly overriding some defaults. + + See class docstring for a list of overridable attributes. + + 'b'{!r} is an invalid keyword argument for {}'u'{!r} is an invalid keyword argument for {}'b'{}={!r}'u'{}={!r}'b'Return a new instance with specified attributes changed. + + The new instance has the same attribute values as the current object, + except for the changes passed in as keyword arguments. + + 'u'Return a new instance with specified attributes changed. + + The new instance has the same attribute values as the current object, + except for the changes passed in as keyword arguments. + + 'b'{!r} object attribute {!r} is read-only'u'{!r} object attribute {!r} is read-only'b'{!r} object has no attribute {!r}'u'{!r} object has no attribute {!r}'b'Non-default values from right operand override those from left. + + The object returned is a new instance of the subclass. + + 'u'Non-default values from right operand override those from left. + + The object returned is a new instance of the subclass. + + 'b'Controls for how messages are interpreted and formatted. + + Most of the classes and many of the methods in the email package accept + Policy objects as parameters. A Policy object contains a set of values and + functions that control how input is interpreted and how output is rendered. + For example, the parameter 'raise_on_defect' controls whether or not an RFC + violation results in an error being raised or not, while 'max_line_length' + controls the maximum length of output lines when a Message is serialized. + + Any valid attribute may be overridden when a Policy is created by passing + it as a keyword argument to the constructor. Policy objects are immutable, + but a new Policy object can be created with only certain values changed by + calling the Policy instance with keyword arguments. Policy objects can + also be added, producing a new Policy object in which the non-default + attributes set in the right hand operand overwrite those specified in the + left operand. + + Settable attributes: + + raise_on_defect -- If true, then defects should be raised as errors. + Default: False. + + linesep -- string containing the value to use as separation + between output lines. Default '\n'. + + cte_type -- Type of allowed content transfer encodings + + 7bit -- ASCII only + 8bit -- Content-Transfer-Encoding: 8bit is allowed + + Default: 8bit. Also controls the disposition of + (RFC invalid) binary data in headers; see the + documentation of the binary_fold method. + + max_line_length -- maximum length of lines, excluding 'linesep', + during serialization. None or 0 means no line + wrapping is done. Default is 78. + + mangle_from_ -- a flag that, when True escapes From_ lines in the + body of the message by putting a `>' in front of + them. This is used when the message is being + serialized by a generator. Default: True. + + message_factory -- the class to use to create new message objects. + If the value is None, the default is Message. + + 'u'Controls for how messages are interpreted and formatted. + + Most of the classes and many of the methods in the email package accept + Policy objects as parameters. A Policy object contains a set of values and + functions that control how input is interpreted and how output is rendered. + For example, the parameter 'raise_on_defect' controls whether or not an RFC + violation results in an error being raised or not, while 'max_line_length' + controls the maximum length of output lines when a Message is serialized. + + Any valid attribute may be overridden when a Policy is created by passing + it as a keyword argument to the constructor. Policy objects are immutable, + but a new Policy object can be created with only certain values changed by + calling the Policy instance with keyword arguments. Policy objects can + also be added, producing a new Policy object in which the non-default + attributes set in the right hand operand overwrite those specified in the + left operand. + + Settable attributes: + + raise_on_defect -- If true, then defects should be raised as errors. + Default: False. + + linesep -- string containing the value to use as separation + between output lines. Default '\n'. + + cte_type -- Type of allowed content transfer encodings + + 7bit -- ASCII only + 8bit -- Content-Transfer-Encoding: 8bit is allowed + + Default: 8bit. Also controls the disposition of + (RFC invalid) binary data in headers; see the + documentation of the binary_fold method. + + max_line_length -- maximum length of lines, excluding 'linesep', + during serialization. None or 0 means no line + wrapping is done. Default is 78. + + mangle_from_ -- a flag that, when True escapes From_ lines in the + body of the message by putting a `>' in front of + them. This is used when the message is being + serialized by a generator. Default: True. + + message_factory -- the class to use to create new message objects. + If the value is None, the default is Message. + + 'b'8bit'u'8bit'b'Based on policy, either raise defect or call register_defect. + + handle_defect(obj, defect) + + defect should be a Defect subclass, but in any case must be an + Exception subclass. obj is the object on which the defect should be + registered if it is not raised. If the raise_on_defect is True, the + defect is raised as an error, otherwise the object and the defect are + passed to register_defect. + + This method is intended to be called by parsers that discover defects. + The email package parsers always call it with Defect instances. + + 'u'Based on policy, either raise defect or call register_defect. + + handle_defect(obj, defect) + + defect should be a Defect subclass, but in any case must be an + Exception subclass. obj is the object on which the defect should be + registered if it is not raised. If the raise_on_defect is True, the + defect is raised as an error, otherwise the object and the defect are + passed to register_defect. + + This method is intended to be called by parsers that discover defects. + The email package parsers always call it with Defect instances. + + 'b'Record 'defect' on 'obj'. + + Called by handle_defect if raise_on_defect is False. This method is + part of the Policy API so that Policy subclasses can implement custom + defect handling. The default implementation calls the append method of + the defects attribute of obj. The objects used by the email package by + default that get passed to this method will always have a defects + attribute with an append method. + + 'u'Record 'defect' on 'obj'. + + Called by handle_defect if raise_on_defect is False. This method is + part of the Policy API so that Policy subclasses can implement custom + defect handling. The default implementation calls the append method of + the defects attribute of obj. The objects used by the email package by + default that get passed to this method will always have a defects + attribute with an append method. + + 'b'Return the maximum allowed number of headers named 'name'. + + Called when a header is added to a Message object. If the returned + value is not 0 or None, and there are already a number of headers with + the name 'name' equal to the value returned, a ValueError is raised. + + Because the default behavior of Message's __setitem__ is to append the + value to the list of headers, it is easy to create duplicate headers + without realizing it. This method allows certain headers to be limited + in the number of instances of that header that may be added to a + Message programmatically. (The limit is not observed by the parser, + which will faithfully produce as many headers as exist in the message + being parsed.) + + The default implementation returns None for all header names. + 'u'Return the maximum allowed number of headers named 'name'. + + Called when a header is added to a Message object. If the returned + value is not 0 or None, and there are already a number of headers with + the name 'name' equal to the value returned, a ValueError is raised. + + Because the default behavior of Message's __setitem__ is to append the + value to the list of headers, it is easy to create duplicate headers + without realizing it. This method allows certain headers to be limited + in the number of instances of that header that may be added to a + Message programmatically. (The limit is not observed by the parser, + which will faithfully produce as many headers as exist in the message + being parsed.) + + The default implementation returns None for all header names. + 'b'Given a list of linesep terminated strings constituting the lines of + a single header, return the (name, value) tuple that should be stored + in the model. The input lines should retain their terminating linesep + characters. The lines passed in by the email package may contain + surrogateescaped binary data. + 'u'Given a list of linesep terminated strings constituting the lines of + a single header, return the (name, value) tuple that should be stored + in the model. The input lines should retain their terminating linesep + characters. The lines passed in by the email package may contain + surrogateescaped binary data. + 'b'Given the header name and the value provided by the application + program, return the (name, value) that should be stored in the model. + 'u'Given the header name and the value provided by the application + program, return the (name, value) that should be stored in the model. + 'b'Given the header name and the value from the model, return the value + to be returned to the application program that is requesting that + header. The value passed in by the email package may contain + surrogateescaped binary data if the lines were parsed by a BytesParser. + The returned value should not contain any surrogateescaped data. + + 'u'Given the header name and the value from the model, return the value + to be returned to the application program that is requesting that + header. The value passed in by the email package may contain + surrogateescaped binary data if the lines were parsed by a BytesParser. + The returned value should not contain any surrogateescaped data. + + 'b'Given the header name and the value from the model, return a string + containing linesep characters that implement the folding of the header + according to the policy controls. The value passed in by the email + package may contain surrogateescaped binary data if the lines were + parsed by a BytesParser. The returned value should not contain any + surrogateescaped data. + + 'u'Given the header name and the value from the model, return a string + containing linesep characters that implement the folding of the header + according to the policy controls. The value passed in by the email + package may contain surrogateescaped binary data if the lines were + parsed by a BytesParser. The returned value should not contain any + surrogateescaped data. + + 'b'Given the header name and the value from the model, return binary + data containing linesep characters that implement the folding of the + header according to the policy controls. The value passed in by the + email package may contain surrogateescaped binary data. + + 'u'Given the header name and the value from the model, return binary + data containing linesep characters that implement the folding of the + header according to the policy controls. The value passed in by the + email package may contain surrogateescaped binary data. + + 'b'+ + This particular policy is the backward compatibility Policy. It + replicates the behavior of the email package version 5.1. + 'u'+ + This particular policy is the backward compatibility Policy. It + replicates the behavior of the email package version 5.1. + 'b'+ + The name is parsed as everything up to the ':' and returned unmodified. + The value is determined by stripping leading whitespace off the + remainder of the first line, joining all subsequent lines together, and + stripping any trailing carriage return or linefeed characters. + + 'u'+ + The name is parsed as everything up to the ':' and returned unmodified. + The value is determined by stripping leading whitespace off the + remainder of the first line, joining all subsequent lines together, and + stripping any trailing carriage return or linefeed characters. + + 'b'+ + The name and value are returned unmodified. + 'u'+ + The name and value are returned unmodified. + 'b'+ + If the value contains binary data, it is converted into a Header object + using the unknown-8bit charset. Otherwise it is returned unmodified. + 'u'+ + If the value contains binary data, it is converted into a Header object + using the unknown-8bit charset. Otherwise it is returned unmodified. + 'b'+ + Headers are folded using the Header folding algorithm, which preserves + existing line breaks in the value, and wraps each resulting line to the + max_line_length. Non-ASCII binary data are CTE encoded using the + unknown-8bit charset. + + 'u'+ + Headers are folded using the Header folding algorithm, which preserves + existing line breaks in the value, and wraps each resulting line to the + max_line_length. Non-ASCII binary data are CTE encoded using the + unknown-8bit charset. + + 'b'+ + Headers are folded using the Header folding algorithm, which preserves + existing line breaks in the value, and wraps each resulting line to the + max_line_length. If cte_type is 7bit, non-ascii binary data is CTE + encoded using the unknown-8bit charset. Otherwise the original source + header is used, with its existing line breaks and/or binary data. + + 'u'+ + Headers are folded using the Header folding algorithm, which preserves + existing line breaks in the value, and wraps each resulting line to the + max_line_length. If cte_type is 7bit, non-ascii binary data is CTE + encoded using the unknown-8bit charset. Otherwise the original source + header is used, with its existing line breaks and/or binary data. + + 'b'7bit'u'7bit'b'%s: 'u'%s: 'u'email._policybase'u'_policybase'u'POSIX shared memory module'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_posixshmem.cpython-38-darwin.so'u'_posixshmem'shm_openshm_unlink_posixshmemu'A POSIX helper for the subprocess module.'u'/Users/pwntester/.pyenv/versions/3.8.13/lib/python3.8/lib-dynload/_posixsubprocess.cpython-38-darwin.so'u'_posixsubprocess'fork_exec_posixsubprocess_weakrefsetReturns the current ABC cache token. + + The token is an opaque object (supporting equality testing) identifying the + current version of the ABC cache for virtual subclasses. The token changes + with every call to ``register()`` on any ABC. + _abc_invalidation_counterMetaclass for defining Abstract Base Classes (ABCs). + + Use this metaclass to create an ABC. An ABC can be subclassed + directly, and then acts as a mix-in class. You can also register + unrelated concrete classes (even built-in classes) and unrelated + ABCs as 'virtual subclasses' -- these and their descendants will + be considered subclasses of the registering ABC by the built-in + issubclass() function, but the registering ABC won't show up in + their MRO (Method Resolution Order) nor will method + implementations defined by the registering ABC be callable (not + even via super()). + mclsbasesabstracts_abc_registry_abc_cache_abc_negative_cache_abc_negative_cache_versionsubclassRegister a virtual subclass of an ABC. + + Returns the subclass, to allow usage as a class decorator. + Can only register classesRefusing to create an inheritance cycle_dump_registryDebug helper to print the ABC registry.Class: Inv. counter: _abc__abc_registry_clearClear the registry (for debugging or testing)._abc_caches_clearClear the caches (for debugging or testing).Override for isinstance(instance, cls).subtypeOverride for issubclass(subclass, cls).issubclass() arg 1 must be a classrclsscls# A global counter that is incremented each time a class is# registered as a virtual subclass of anything. It forces the# negative cache to be cleared before its next use.# Note: this counter is private. Use `abc.get_cache_token()` for# external code.# Compute set of abstract method names# Set up inheritance registry# Already a subclass# Subtle: test for cycles *after* testing for "already a subclass";# this means we allow X.register(X) and interpret it as a no-op.# This would create a cycle, which is bad for the algorithm below# Invalidate negative cache# Inline the cache checking# Fall back to the subclass check.# Check cache# Check negative cache; may have to invalidate# Invalidate the negative cache# Check the subclass hook# Check if it's a direct subclass# Check if it's a subclass of a registered class (recursive)# Check if it's a subclass of a subclass (recursive)# No dice; update negative cacheb'Returns the current ABC cache token. + + The token is an opaque object (supporting equality testing) identifying the + current version of the ABC cache for virtual subclasses. The token changes + with every call to ``register()`` on any ABC. + 'u'Returns the current ABC cache token. + + The token is an opaque object (supporting equality testing) identifying the + current version of the ABC cache for virtual subclasses. The token changes + with every call to ``register()`` on any ABC. + 'b'Metaclass for defining Abstract Base Classes (ABCs). + + Use this metaclass to create an ABC. An ABC can be subclassed + directly, and then acts as a mix-in class. You can also register + unrelated concrete classes (even built-in classes) and unrelated + ABCs as 'virtual subclasses' -- these and their descendants will + be considered subclasses of the registering ABC by the built-in + issubclass() function, but the registering ABC won't show up in + their MRO (Method Resolution Order) nor will method + implementations defined by the registering ABC be callable (not + even via super()). + 'u'Metaclass for defining Abstract Base Classes (ABCs). + + Use this metaclass to create an ABC. An ABC can be subclassed + directly, and then acts as a mix-in class. You can also register + unrelated concrete classes (even built-in classes) and unrelated + ABCs as 'virtual subclasses' -- these and their descendants will + be considered subclasses of the registering ABC by the built-in + issubclass() function, but the registering ABC won't show up in + their MRO (Method Resolution Order) nor will method + implementations defined by the registering ABC be callable (not + even via super()). + 'b'__isabstractmethod__'u'__isabstractmethod__'b'__abstractmethods__'u'__abstractmethods__'b'Register a virtual subclass of an ABC. + + Returns the subclass, to allow usage as a class decorator. + 'u'Register a virtual subclass of an ABC. + + Returns the subclass, to allow usage as a class decorator. + 'b'Can only register classes'u'Can only register classes'b'Refusing to create an inheritance cycle'u'Refusing to create an inheritance cycle'b'Debug helper to print the ABC registry.'u'Debug helper to print the ABC registry.'b'Class: 'u'Class: 'b'Inv. counter: 'u'Inv. counter: 'b'_abc_'u'_abc_'b'Clear the registry (for debugging or testing).'u'Clear the registry (for debugging or testing).'b'Clear the caches (for debugging or testing).'u'Clear the caches (for debugging or testing).'b'Override for isinstance(instance, cls).'u'Override for isinstance(instance, cls).'b'Override for issubclass(subclass, cls).'u'Override for issubclass(subclass, cls).'b'issubclass() arg 1 must be a class'u'issubclass() arg 1 must be a class'b'__mro__'u'__mro__'u'_py_abc' +This is an implementation of decimal floating point arithmetic based on +the General Decimal Arithmetic Specification: + + http://speleotrove.com/decimal/decarith.html + +and IEEE standard 854-1987: + + http://en.wikipedia.org/wiki/IEEE_854-1987 + +Decimal floating point has finite precision with arbitrarily large bounds. + +The purpose of this module is to support arithmetic using familiar +"schoolhouse" rules and to avoid some of the tricky representation +issues associated with binary floating point. The package is especially +useful for financial applications or for contexts where users have +expectations that are at odds with binary floating point (for instance, +in binary floating point, 1.00 % 0.1 gives 0.09999999999999995 instead +of 0.0; Decimal('1.00') % Decimal('0.1') returns the expected +Decimal('0.00')). + +Here are some examples of using the decimal module: + +>>> from decimal import * +>>> setcontext(ExtendedContext) +>>> Decimal(0) +Decimal('0') +>>> Decimal('1') +Decimal('1') +>>> Decimal('-.0123') +Decimal('-0.0123') +>>> Decimal(123456) +Decimal('123456') +>>> Decimal('123.45e12345678') +Decimal('1.2345E+12345680') +>>> Decimal('1.33') + Decimal('1.27') +Decimal('2.60') +>>> Decimal('12.34') + Decimal('3.87') - Decimal('18.41') +Decimal('-2.20') +>>> dig = Decimal(1) +>>> print(dig / Decimal(3)) +0.333333333 +>>> getcontext().prec = 18 +>>> print(dig / Decimal(3)) +0.333333333333333333 +>>> print(dig.sqrt()) +1 +>>> print(Decimal(3).sqrt()) +1.73205080756887729 +>>> print(Decimal(3) ** 123) +4.85192780976896427E+58 +>>> inf = Decimal(1) / Decimal(0) +>>> print(inf) +Infinity +>>> neginf = Decimal(-1) / Decimal(0) +>>> print(neginf) +-Infinity +>>> print(neginf + inf) +NaN +>>> print(neginf * inf) +-Infinity +>>> print(dig / 0) +Infinity +>>> getcontext().traps[DivisionByZero] = 1 +>>> print(dig / 0) +Traceback (most recent call last): + ... + ... + ... +decimal.DivisionByZero: x / 0 +>>> c = Context() +>>> c.traps[InvalidOperation] = 0 +>>> print(c.flags[InvalidOperation]) +0 +>>> c.divide(Decimal(0), Decimal(0)) +Decimal('NaN') +>>> c.traps[InvalidOperation] = 1 +>>> print(c.flags[InvalidOperation]) +1 +>>> c.flags[InvalidOperation] = 0 +>>> print(c.flags[InvalidOperation]) +0 +>>> print(c.divide(Decimal(0), Decimal(0))) +Traceback (most recent call last): + ... + ... + ... +decimal.InvalidOperation: 0 / 0 +>>> print(c.flags[InvalidOperation]) +1 +>>> c.flags[InvalidOperation] = 0 +>>> c.traps[InvalidOperation] = 0 +>>> print(c.divide(Decimal(0), Decimal(0))) +NaN +>>> print(c.flags[InvalidOperation]) +1 +>>> +__xname__1.702.4.2math_mathnumbers_numbers_namedtuplesign digits exponent425000000Base exception class. + + Used exceptions derive from this. + If an exception derives from another exception besides this (such as + Underflow (Inexact, Rounded, Subnormal) that indicates that it is only + called if the others are present. This isn't actually used for + anything, though. + + handle -- Called when context._raise_error is called and the + trap_enabler is not set. First argument is self, second is the + context. More arguments can be given, those being after + the explanation in _raise_error (For example, + context._raise_error(NewError, '(-x)!', self._sign) would + call NewError().handle(context, self._sign).) + + To define a new exception, it should be sufficient to have it derive + from DecimalException. + Exponent of a 0 changed to fit bounds. + + This occurs and signals clamped if the exponent of a result has been + altered in order to fit the constraints of a specific concrete + representation. This may occur when the exponent of a zero result would + be outside the bounds of a representation, or when a large normal + number would have an encoded exponent that cannot be represented. In + this latter case, the exponent is reduced to fit and the corresponding + number of zero digits are appended to the coefficient ("fold-down"). + An invalid operation was performed. + + Various bad things cause this: + + Something creates a signaling NaN + -INF + INF + 0 * (+-)INF + (+-)INF / (+-)INF + x % 0 + (+-)INF % x + x._rescale( non-integer ) + sqrt(-x) , x > 0 + 0 ** 0 + x ** (non-integer) + x ** (+-)INF + An operand is invalid + + The result of the operation after these is a quiet positive NaN, + except when the cause is a signaling NaN, in which case the result is + also a quiet NaN, but with the original sign, and an optional + diagnostic information. + _dec_from_triple_sign_intans_fix_nan_NaNTrying to convert badly formed string. + + This occurs and signals invalid-operation if a string is being + converted to a number and it does not conform to the numeric string + syntax. The result is [0,qNaN]. + Division by 0. + + This occurs and signals division-by-zero if division of a finite number + by zero was attempted (during a divide-integer or divide operation, or a + power operation with negative right-hand operand), and the dividend was + not zero. + + The result of the operation is [sign,inf], where sign is the exclusive + or of the signs of the operands for divide, or is 1 for an odd power of + -0, for power. + _SignedInfinityCannot perform the division adequately. + + This occurs and signals invalid-operation if the integer result of a + divide-integer or remainder operation had too many digits (would be + longer than precision). The result is [0,qNaN]. + Undefined result of division. + + This occurs and signals invalid-operation if division by zero was + attempted (during a divide-integer, divide, or remainder operation), and + the dividend is also zero. The result is [0,qNaN]. + Had to round, losing information. + + This occurs and signals inexact whenever the result of an operation is + not exact (that is, it needed to be rounded and any discarded digits + were non-zero), or if an overflow or underflow condition occurs. The + result in all cases is unchanged. + + The inexact signal may be tested (or trapped) to determine if a given + operation (or sequence of operations) was inexact. + Invalid context. Unknown rounding, for example. + + This occurs and signals invalid-operation if an invalid context was + detected during an operation. This can occur if contexts are not checked + on creation and either the precision exceeds the capability of the + underlying concrete representation or an unknown or unsupported rounding + was specified. These aspects of the context need only be checked when + the values are required to be used. The result is [0,qNaN]. + Number got rounded (not necessarily changed during rounding). + + This occurs and signals rounded whenever the result of an operation is + rounded (that is, some zero or non-zero digits were discarded from the + coefficient), or if an overflow or underflow condition occurs. The + result in all cases is unchanged. + + The rounded signal may be tested (or trapped) to determine if a given + operation (or sequence of operations) caused a loss of precision. + Exponent < Emin before rounding. + + This occurs and signals subnormal whenever the result of a conversion or + operation is subnormal (that is, its adjusted exponent is less than + Emin, before any rounding). The result in all cases is unchanged. + + The subnormal signal may be tested (or trapped) to determine if a given + or operation (or sequence of operations) yielded a subnormal result. + Numerical overflow. + + This occurs and signals overflow if the adjusted exponent of a result + (from a conversion or from an operation that is not an attempt to divide + by zero), after rounding, would be greater than the largest value that + can be handled by the implementation (the value Emax). + + The result depends on the rounding mode: + + For round-half-up and round-half-even (and for round-half-down and + round-up, if implemented), the result of the operation is [sign,inf], + where sign is the sign of the intermediate result. For round-down, the + result is the largest finite number that can be represented in the + current precision, with the sign of the intermediate result. For + round-ceiling, the result is the same as for round-down if the sign of + the intermediate result is 1, or is [0,inf] otherwise. For round-floor, + the result is the same as for round-down if the sign of the intermediate + result is 0, or is [1,inf] otherwise. In all cases, Inexact and Rounded + will also be raised. + Numerical underflow with result rounded to 0. + + This occurs and signals underflow if a result is inexact and the + adjusted exponent of the result would be smaller (more negative) than + the smallest value that can be handled by the implementation (the value + Emin). That is, the result is both inexact and subnormal. + + The result after an underflow will be a subnormal number rounded, if + necessary, so that its exponent is not less than Etiny. This may result + in 0 with the sign of the intermediate result and an exponent of Etiny. + + In all cases, Inexact, Rounded, and Subnormal will also be raised. + Enable stricter semantics for mixing floats and Decimals. + + If the signal is not trapped (default), mixing floats and Decimals is + permitted in the Decimal() constructor, context.create_decimal() and + all comparison operators. Both conversion and comparisons are exact. + Any occurrence of a mixed operation is silently recorded by setting + FloatOperation in the context flags. Explicit conversions with + Decimal.from_float() or context.create_decimal_from_float() do not + set the flag. + + Otherwise (the signal is trapped), only equality comparisons and explicit + conversions are silent. All other mixed operations raise FloatOperation. + _signals_condition_map_rounding_modescontextvarsdecimal_context_current_context_varReturns this thread's context. + + If this thread does not yet have a context, returns + a new context and sets this thread's context. + New contexts are copies of DefaultContext. + Set this thread's context to context.Return a context manager for a copy of the supplied context + + Uses a copy of the current context if no context is specified + The returned context manager creates a local decimal context + in a with statement: + def sin(x): + with localcontext() as ctx: + ctx.prec += 2 + # Rest of sin calculation algorithm + # uses a precision 2 greater than normal + return +s # Convert result to normal precision + + def sin(x): + with localcontext(ExtendedContext): + # Rest of sin calculation algorithm + # uses the Extended Context from the + # General Decimal Arithmetic Specification + return +s # Convert result to normal context + + >>> setcontext(DefaultContext) + >>> print(getcontext().prec) + 28 + >>> with localcontext(): + ... ctx = getcontext() + ... ctx.prec += 2 + ... print(ctx.prec) + ... + 30 + >>> with localcontext(ExtendedContext): + ... print(getcontext().prec) + ... + 9 + >>> print(getcontext().prec) + 28 + _ContextManagerFloating point class for decimal arithmetic._exp_is_specialCreate a decimal point instance. + + >>> Decimal('3.14') # string input + Decimal('3.14') + >>> Decimal((0, (3, 1, 4), -2)) # tuple (sign, digit_tuple, exponent) + Decimal('3.14') + >>> Decimal(314) # int + Decimal('314') + >>> Decimal(Decimal(314)) # another decimal instance + Decimal('314') + >>> Decimal(' 3.14 \n') # leading and trailing whitespace okay + Decimal('3.14') + _raise_errorInvalid literal for Decimal: %rintpartfracfracpartdiagF_WorkRepInvalid tuple size in creation of Decimal from list or tuple. The list or tuple should have exactly three elements.'Invalid tuple size in creation of Decimal ''from list or tuple. The list or tuple ''should have exactly three elements.'Invalid sign. The first value in the tuple should be an integer; either 0 for a positive number or 1 for a negative number."Invalid sign. The first value in the tuple ""should be an integer; either 0 for a ""positive number or 1 for a negative number."digitThe second value in the tuple must be composed of integers in the range 0 through 9."The second value in the tuple must ""be composed of integers in the range ""0 through 9."The third value in the tuple must be an integer, or one of the strings 'F', 'n', 'N'."The third value in the tuple must ""be an integer, or one of the ""strings 'F', 'n', 'N'."strict semantics for mixing floats and Decimals are enabled"strict semantics for mixing floats and Decimals are ""enabled"Cannot convert %r to DecimalConverts a float to a decimal number, exactly. + + Note that Decimal.from_float(0.1) is not the same as Decimal('0.1'). + Since 0.1 is not exactly representable in binary floating point, the + value is stored as the nearest representable value which is + 0x1.999999999999ap-4. The exact equivalent of the value in decimal + is 0.1000000000000000055511151231257827021181583404541015625. + + >>> Decimal.from_float(0.1) + Decimal('0.1000000000000000055511151231257827021181583404541015625') + >>> Decimal.from_float(float('nan')) + Decimal('NaN') + >>> Decimal.from_float(float('inf')) + Decimal('Infinity') + >>> Decimal.from_float(-float('inf')) + Decimal('-Infinity') + >>> Decimal.from_float(-0.0) + Decimal('-0') + + coeffisinfisnancopysignargument must be int or float._isnanReturns whether the number is not actually one. + + 0 if a number + 1 if NaN + 2 if sNaN + _isinfinityReturns whether the number is infinite + + 0 if finite or not a number + 1 if +INF + -1 if -INF + _check_nansReturns whether the number is not actually one. + + if self, other are sNaN, signal + if self, other are NaN return nan + return 0 + + Done before operations. + self_is_nanother_is_nansNaN_compare_check_nansVersion of _check_nans used for the signaling comparisons + compare_signal, __le__, __lt__, __ge__, __gt__. + + Signal InvalidOperation if either self or other is a (quiet + or signaling) NaN. Signaling NaNs take precedence over quiet + NaNs. + + Return 0 if neither operand is a NaN. + + comparison involving sNaNcomparison involving NaNReturn True if self is nonzero; otherwise return False. + + NaNs and infinities are considered nonzero. + _cmpCompare the two non-NaN decimal instances self and other. + + Returns -1 if self < other, 0 if self == other and 1 + if self > other. This routine is for internal use only.self_infother_infself_adjustedother_adjustedself_paddedother_padded_convert_for_comparisonequality_opCompare self to other. Return a decimal value: + + a or b is a NaN ==> Decimal('NaN') + a < b ==> Decimal('-1') + a == b ==> Decimal('0') + a > b ==> Decimal('1') + _convert_otherraiseitx.__hash__() <==> hash(x)Cannot hash a signaling NaN value._PyHASH_NAN_PyHASH_INF_PyHASH_MODULUSexp_hash_PyHASH_10INVhash_Represents the number as a triple tuple. + + To show the internals exactly as they are. + Express a finite Decimal instance in the form n / d. + + Returns a pair (n, d) of integers. When called on an infinity + or NaN, raises OverflowError or ValueError respectively. + + >>> Decimal('3.14').as_integer_ratio() + (157, 50) + >>> Decimal('-123e5').as_integer_ratio() + (-12300000, 1) + >>> Decimal('0.00').as_integer_ratio() + (0, 1) + + cannot convert NaN to integer ratiocannot convert Infinity to integer ratiod5d2shift2Represents the number as an instance of Decimal.Decimal('%s')engReturn string representation of the number in scientific notation. + + Captures all of the information in the underlying representation. + InfinityNaNleftdigitsdotplace%+dConvert to a string, using engineering notation if an exponent is needed. + + Engineering notation has an exponent which is a multiple of 3. This + can leave up to 3 digits to the left of the decimal place and may + require the addition of either one or two trailing zeros. + Returns a copy with the sign switched. + + Rounds, if it has reason. + _fixReturns a copy, unless it is a sNaN. + + Rounds the number (if more than precision digits) + Returns the absolute value of self. + + If the keyword argument 'round' is false, do not round. The + expression self.__abs__(round=False) is equivalent to + self.copy_abs(). + Returns self + other. + + -INF + INF (or the reverse) cause InvalidOperation errors. + -INF + INFnegativezero_rescaleop1op2_normalizeReturn self - otherReturn other - selfReturn self * other. + + (+-) INF * 0 (or its reverse) raise InvalidOperation. + resultsign(+-)INF * 00 * (+-)INFresultexpReturn self / other.(+-)INF/(+-)INFDivision by infinity0 / 0x / 0ideal_exp_divideReturn (self // other, self % other), to context.prec precision. + + Assumes that neither self nor other is a NaN, that self is not + infinite and that other is nonzero. + expdiffquotient too large in //, % or divmodSwaps self/other and returns __truediv__. + Return (self // other, self % other) + divmod(INF, INF)INF % xdivmod(0, 0)x // 0x % 0quotientSwaps self/other and returns __divmod__. + self % other + 0 % 0Swaps self/other and returns __mod__. + Remainder nearest to 0- abs(remainder-near) <= other/2 + remainder_near(infinity, x)remainder_near(x, 0)remainder_near(0, 0)ideal_exponentself // otherINF // INF0 // 0Swaps self/other and returns __floordiv__.Float representation.Cannot convert signaling NaN to float-nanConverts self to an int, truncating if necessary.Cannot convert NaN to integerCannot convert infinity to integerDecapitate the payload of a NaN to fit the contextpayloadmax_payload_lenRound if it is necessary to keep self within prec precision. + + Rounds and fixes the exponent. Does not raise on a sNaN. + + Arguments: + self - Decimal instance + context - context used. + exp_maxnew_expexp_minabove Emaxself_is_subnormal_pick_rounding_functionrounding_methodchanged_round_downAlso known as round-towards-0, truncate._all_zeros_round_upRounds away from 0._round_half_upRounds 5 up (away from 0)56789_round_half_downRound 5 down_exact_half_round_half_evenRound 5 to even, rest to nearest.02468_round_ceilingRounds up (not away from 0 if negative.)_round_floorRounds down (not towards 0 if negative)_round_05upRound down unless digit prec-1 is 0 or 5.05Round self to the nearest integer, or to a given precision. + + If only one argument is supplied, round a finite Decimal + instance self to the nearest integer. If self is infinite or + a NaN then a Python exception is raised. If self is finite + and lies exactly halfway between two integers then it is + rounded to the integer with even last digit. + + >>> round(Decimal('123.456')) + 123 + >>> round(Decimal('-456.789')) + -457 + >>> round(Decimal('-3.0')) + -3 + >>> round(Decimal('2.5')) + 2 + >>> round(Decimal('3.5')) + 4 + >>> round(Decimal('Inf')) + Traceback (most recent call last): + ... + OverflowError: cannot round an infinity + >>> round(Decimal('NaN')) + Traceback (most recent call last): + ... + ValueError: cannot round a NaN + + If a second argument n is supplied, self is rounded to n + decimal places using the rounding mode for the current + context. + + For an integer n, round(self, -n) is exactly equivalent to + self.quantize(Decimal('1En')). + + >>> round(Decimal('123.456'), 0) + Decimal('123') + >>> round(Decimal('123.456'), 2) + Decimal('123.46') + >>> round(Decimal('123.456'), -2) + Decimal('1E+2') + >>> round(Decimal('-Infinity'), 37) + Decimal('NaN') + >>> round(Decimal('sNaN123'), 0) + Decimal('NaN123') + + Second argument to round should be integralcannot round a NaNcannot round an infinityReturn the floor of self, as an integer. + + For a finite Decimal instance self, return the greatest + integer n such that n <= self. If self is infinite or a NaN + then a Python exception is raised. + + Return the ceiling of self, as an integer. + + For a finite Decimal instance self, return the least integer n + such that n >= self. If self is infinite or a NaN then a + Python exception is raised. + + thirdFused multiply-add. + + Returns self*other+third with no rounding of the intermediate + product self*other. + + self and other are multiplied together, with no rounding of + the result. The third operand is then added to the result, + and a single final rounding is performed. + productINF * 0 in fma0 * INF in fma_power_modulomoduloThree argument version of __pow__modulo_is_nan_isintegerpow() 3rd argument not allowed unless all arguments are integers'pow() 3rd argument not allowed ''unless all arguments are integers'pow() 2nd argument cannot be negative when 3rd argument specified'pow() 2nd argument cannot be ''negative when 3rd argument specified'pow() 3rd argument cannot be 0insufficient precision: pow() 3rd argument must not have more than precision digits'insufficient precision: pow() 3rd ''argument must not have more than ''precision digits'at least one of pow() 1st argument and 2nd argument must be nonzero; 0**0 is not defined'at least one of pow() 1st argument ''and 2nd argument must be nonzero; ''0**0 is not defined'_iseven_power_exactAttempt to compute self**other exactly. + + Given Decimals self and other and an integer p, attempt to + compute an exact result for the power self**other, with p + digits of precision. Return None if self**other is not + exactly representable in p digits. + + Assumes that elimination of special cases has already been + performed: self and other must both be nonspecial; self must + be positive and not numerically equal to 1; other must be + nonzero. For efficiency, other._exp should not be too large, + so that 10**abs(other._exp) is a feasible calculation.xcxeycyezeroslast_digit_nbits9365emax_decimal_lshift_exactxc_bitsrem_log10_lbstr_xcReturn self ** other [ % modulo]. + + With two arguments, compute self**other. + + With three arguments, compute (self**other) % modulo. For the + three argument form, the following restrictions on the + arguments hold: + + - all three arguments must be integral + - other must be nonnegative + - either self or other (or both) must be nonzero + - modulo must be nonzero and must have at most p digits, + where p is the context precision. + + If any of these restrictions is violated the InvalidOperation + flag is raised. + + The result of pow(self, other, modulo) is identical to the + result that would be obtained by computing (self**other) % + modulo with unbounded precision, but is computed more + efficiently. It is always exact. + 0 ** 0_Oneresult_signx ** y with x negative and y not an integermultiplierself_adj_log10_exp_boundbound_dpowernewcontexttrapsSwaps self/other and returns __pow__.Normalize- strip trailing 0s, change anything equal to 0 to 0e0Quantize self so its exponent is the same as that of exp. + + Similar to self._rescale(exp._exp) but with error checking. + quantize with one INFtarget exponent out of bounds in quantizeexponent of quantize result too large for current contextquantize result has too many digits for current contextReturn True if self and other have the same exponent; otherwise + return False. + + If either operand is a special value, the following rules are used: + * return True if both operands are infinities + * return True if both operands are NaNs + * otherwise, return False. + Rescale self so that the exponent is exp, either by padding with zeros + or by truncating digits, using the given rounding mode. + + Specials are returned without change. This operation is + quiet: it raises no flags, and uses no information from the + context. + + exp = exp to scale to (an integer) + rounding = rounding mode + this_function_roundplacesRound a nonzero, nonspecial Decimal to a fixed number of + significant figures, using the given rounding mode. + + Infinities, NaNs and zeros are returned unaltered. + + This operation is quiet: it raises no flags, and uses no + information from the context. + + argument should be at least 1 in _roundRounds to a nearby integer. + + If no rounding mode is specified, take the rounding mode from + the context. This method raises the Rounded and Inexact flags + when appropriate. + + See also: to_integral_value, which does exactly the same as + this method except that it doesn't raise Inexact or Rounded. + Rounds to the nearest integer, without raising inexact, rounded.Return the square root of self.sqrt(-x), x > 0_shallow_copy_set_roundingReturns the larger value. + + Like max(self, other) except if one is not a number, returns + NaN (and signals if one is sNaN). Also rounds. + snonReturns the smaller value. + + Like min(self, other) except if one is not a number, returns + NaN (and signals if one is sNaN). Also rounds. + Returns whether self is an integerReturns True if self is even. Assumes self is an integer.Return the adjusted exponent of selfReturns the same Decimal object. + + As we do not have different encodings for the same number, the + received object already is in its canonical form. + Compares self to the other operand numerically. + + It's pretty much like compare(), but all NaNs signal, with signaling + NaNs taking precedence over quiet NaNs. + Compares self to other using the abstract representations. + + This is not like the standard compare, which use their numerical + value. Note that a total ordering is defined for all possible abstract + representations. + _NegativeOneself_nanother_nanself_keyother_key_ZeroCompares self to other using abstract repr., ignoring sign. + + Like compare_total, but with operand's sign ignored and assumed to be 0. + Returns a copy with the sign set to 0. Returns a copy with the sign inverted.Returns self with the sign of other.Returns e ** self.adj_dexpReturn True if self is canonical; otherwise return False. + + Currently, the encoding of a Decimal instance is always + canonical, so this method returns True for any Decimal. + Return True if self is finite; otherwise return False. + + A Decimal instance is considered finite if it is neither + infinite nor a NaN. + Return True if self is infinite; otherwise return False.Return True if self is a qNaN or sNaN; otherwise return False.Return True if self is a normal number; otherwise return False.Return True if self is a quiet NaN; otherwise return False.Return True if self is negative; otherwise return False.Return True if self is a signaling NaN; otherwise return False.Return True if self is subnormal; otherwise return False.Return True if self is a zero; otherwise return False._ln_exp_boundCompute a lower bound for the adjusted exponent of self.ln(). + In other words, compute r such that self.ln() >= 10**r. Assumes + that self is finite and positive and that self != 1. + denReturns the natural (base e) logarithm of self._NegativeInfinity_Infinityln of a negative value_dlogCompute a lower bound for the adjusted exponent of self.log10(). + In other words, find r such that self.log10() >= 10**r. + Assumes that self is finite and positive and that self != 1. + 231Returns the base 10 logarithm of self.log10 of a negative value_dlog10 Returns the exponent of the magnitude of self's MSD. + + The result is the integer which is the exponent of the magnitude + of the most significant digit of self (as though it were truncated + to a single digit while maintaining the value of that digit and + without limiting the resulting exponent). + logb(0)_islogicalReturn True if self is a logical operand. + + For being logical, it must be a finite number with a sign of 0, + an exponent of 0, and a coefficient whose digits must all be + either 0 or 1. + 01_fill_logicalopaopbdifApplies an 'and' operation between self and other's digits.Invert all its digits.Applies an 'or' operation between self and other's digits.Applies an 'xor' operation between self and other's digits.Compares the values numerically with their sign ignored.Returns the largest representable number smaller than itself._ignore_all_flagsnew_selfReturns the smallest representable number larger than itself.Returns the number closest to self, in the direction towards other. + + The result is the closest representable number to self + (excluding self) that is in the direction towards other, + unless both have the same value. If the two operands are + numerically equal, then the result is a copy of self with the + sign set to be the same as the sign of other. + comparisonInfinite result from next_towardReturns an indication of the class of self. + + The class is one of the following strings: + sNaN + NaN + -Infinity + -Normal + -Subnormal + -Zero + +Zero + +Subnormal + +Normal + +Infinity + +Infinity-Infinity-Zero+Zero-Subnormal+Subnormal-Normal+NormalJust returns 10, as this is Decimal, :)Returns a rotated copy of self, value-of-other times.torotrotdigtopadrotatedReturns self operand after adding the second value to its exp.liminflimsupReturns a shifted copy of self, value-of-other times.shiftedspecifier_localeconvFormat a Decimal instance according to the given specifier. + + The specifier should be a standard format specifier, with the + form described in PEP 3101. Formatting types 'e', 'E', 'f', + 'F', 'g', 'G', 'n' and '%' are supported. If the formatting + type is omitted it defaults to 'g' or 'G', depending on the + value of context.capitals. + _parse_format_specifier_format_signbody_format_alignGprecisioneEfF%gG_format_numbercoefficientspecialCreate a decimal instance directly, without any validation, + normalization (e.g. removal of leading zeros) or argument + conversion. + + This function is for *internal use only*. + NumberContext manager class to support localcontext(). + + Sets a copy of the supplied context in __enter__() and restores + the previous decimal context in __exit__() + new_contextsaved_contextContains the context for a Decimal instance. + + Contains: + prec - precision (for use in rounding, division, square roots..) + rounding - rounding type (how you round) + traps - If traps[exception] = 1, then the exception is + raised when it is caused. Otherwise, a value is + substituted in. + flags - When an exception is caused, flags[exception] is set. + (Whether or not the trap_enabler is set) + Should be reset by user of Decimal instance. + Emin - Minimum exponent + Emax - Maximum exponent + capitals - If 1, 1*10^1 is printed as 1E+1. + If 0, printed as 1e1 + clamp - If 1, change exponents if too high (Default 0) + _ignored_flags_set_integer_checkvminvmax%s must be an integer-inf%s must be in [%s, %d]. got: %s%s must be in [%d, %s]. got: %s%s must be in [%d, %d]. got %s_set_signal_dict%s must be a signal dict%s is not a valid signal dict%s: invalid rounding mode'decimal.Context' object has no attribute '%s'%s cannot be deletedsigShow the current context.Context(prec=%(prec)d, rounding=%(rounding)s, Emin=%(Emin)d, Emax=%(Emax)d, capitals=%(capitals)d, clamp=%(clamp)d'Context(prec=%(prec)d, rounding=%(rounding)s, ''Emin=%(Emin)d, Emax=%(Emax)d, capitals=%(capitals)d, ''clamp=%(clamp)d'flags=[traps=[Reset all flags to zeroReset all traps to zeroReturns a shallow copy from self.ncReturns a deep copy from self.explanationHandles an error + + If the flag is in _ignored_flags, returns the default response. + Otherwise, it sets the flag, then, if the corresponding + trap_enabler is set, it reraises the exception. Otherwise, it returns + the default value after setting the flag. + Ignore all flags, if they are raised_ignore_flagsIgnore the flags, if they are raised_regard_flagsStop ignoring the flags, if they are raisedReturns Etiny (= Emin - prec + 1)Returns maximum exponent (= Emax - prec + 1)Sets the rounding type. + + Sets the rounding type, and returns the current (previous) + rounding type. Often used like: + + context = context.copy() + # so you don't change the calling context + # if an error occurs in the middle. + rounding = context._set_rounding(ROUND_UP) + val = self.__sub__(other, context=context) + context._set_rounding(rounding) + + This will make it round up for that operation. + Creates a new Decimal instance but using self as context. + + This method implements the to-number operation of the + IBM Decimal specification.trailing or leading whitespace and underscores are not permitted."trailing or leading whitespace and ""underscores are not permitted."diagnostic info too long in NaNCreates a new Decimal instance from a float but rounding using self + as the context. + + >>> context = Context(prec=5, rounding=ROUND_DOWN) + >>> context.create_decimal_from_float(3.1415926535897932) + Decimal('3.1415') + >>> context = Context(prec=5, traps=[Inexact]) + >>> context.create_decimal_from_float(3.1415926535897932) + Traceback (most recent call last): + ... + decimal.Inexact: None + + Returns the absolute value of the operand. + + If the operand is negative, the result is the same as using the minus + operation on the operand. Otherwise, the result is the same as using + the plus operation on the operand. + + >>> ExtendedContext.abs(Decimal('2.1')) + Decimal('2.1') + >>> ExtendedContext.abs(Decimal('-100')) + Decimal('100') + >>> ExtendedContext.abs(Decimal('101.5')) + Decimal('101.5') + >>> ExtendedContext.abs(Decimal('-101.5')) + Decimal('101.5') + >>> ExtendedContext.abs(-1) + Decimal('1') + Return the sum of the two operands. + + >>> ExtendedContext.add(Decimal('12'), Decimal('7.00')) + Decimal('19.00') + >>> ExtendedContext.add(Decimal('1E+2'), Decimal('1.01E+4')) + Decimal('1.02E+4') + >>> ExtendedContext.add(1, Decimal(2)) + Decimal('3') + >>> ExtendedContext.add(Decimal(8), 5) + Decimal('13') + >>> ExtendedContext.add(5, 5) + Decimal('10') + Unable to convert %s to DecimalReturns the same Decimal object. + + As we do not have different encodings for the same number, the + received object already is in its canonical form. + + >>> ExtendedContext.canonical(Decimal('2.50')) + Decimal('2.50') + canonical requires a Decimal as an argument.Compares values numerically. + + If the signs of the operands differ, a value representing each operand + ('-1' if the operand is less than zero, '0' if the operand is zero or + negative zero, or '1' if the operand is greater than zero) is used in + place of that operand for the comparison instead of the actual + operand. + + The comparison is then effected by subtracting the second operand from + the first and then returning a value according to the result of the + subtraction: '-1' if the result is less than zero, '0' if the result is + zero or negative zero, or '1' if the result is greater than zero. + + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('3')) + Decimal('-1') + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('2.1')) + Decimal('0') + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('2.10')) + Decimal('0') + >>> ExtendedContext.compare(Decimal('3'), Decimal('2.1')) + Decimal('1') + >>> ExtendedContext.compare(Decimal('2.1'), Decimal('-3')) + Decimal('1') + >>> ExtendedContext.compare(Decimal('-3'), Decimal('2.1')) + Decimal('-1') + >>> ExtendedContext.compare(1, 2) + Decimal('-1') + >>> ExtendedContext.compare(Decimal(1), 2) + Decimal('-1') + >>> ExtendedContext.compare(1, Decimal(2)) + Decimal('-1') + Compares the values of the two operands numerically. + + It's pretty much like compare(), but all NaNs signal, with signaling + NaNs taking precedence over quiet NaNs. + + >>> c = ExtendedContext + >>> c.compare_signal(Decimal('2.1'), Decimal('3')) + Decimal('-1') + >>> c.compare_signal(Decimal('2.1'), Decimal('2.1')) + Decimal('0') + >>> c.flags[InvalidOperation] = 0 + >>> print(c.flags[InvalidOperation]) + 0 + >>> c.compare_signal(Decimal('NaN'), Decimal('2.1')) + Decimal('NaN') + >>> print(c.flags[InvalidOperation]) + 1 + >>> c.flags[InvalidOperation] = 0 + >>> print(c.flags[InvalidOperation]) + 0 + >>> c.compare_signal(Decimal('sNaN'), Decimal('2.1')) + Decimal('NaN') + >>> print(c.flags[InvalidOperation]) + 1 + >>> c.compare_signal(-1, 2) + Decimal('-1') + >>> c.compare_signal(Decimal(-1), 2) + Decimal('-1') + >>> c.compare_signal(-1, Decimal(2)) + Decimal('-1') + Compares two operands using their abstract representation. + + This is not like the standard compare, which use their numerical + value. Note that a total ordering is defined for all possible abstract + representations. + + >>> ExtendedContext.compare_total(Decimal('12.73'), Decimal('127.9')) + Decimal('-1') + >>> ExtendedContext.compare_total(Decimal('-127'), Decimal('12')) + Decimal('-1') + >>> ExtendedContext.compare_total(Decimal('12.30'), Decimal('12.3')) + Decimal('-1') + >>> ExtendedContext.compare_total(Decimal('12.30'), Decimal('12.30')) + Decimal('0') + >>> ExtendedContext.compare_total(Decimal('12.3'), Decimal('12.300')) + Decimal('1') + >>> ExtendedContext.compare_total(Decimal('12.3'), Decimal('NaN')) + Decimal('-1') + >>> ExtendedContext.compare_total(1, 2) + Decimal('-1') + >>> ExtendedContext.compare_total(Decimal(1), 2) + Decimal('-1') + >>> ExtendedContext.compare_total(1, Decimal(2)) + Decimal('-1') + Compares two operands using their abstract representation ignoring sign. + + Like compare_total, but with operand's sign ignored and assumed to be 0. + Returns a copy of the operand with the sign set to 0. + + >>> ExtendedContext.copy_abs(Decimal('2.1')) + Decimal('2.1') + >>> ExtendedContext.copy_abs(Decimal('-100')) + Decimal('100') + >>> ExtendedContext.copy_abs(-1) + Decimal('1') + Returns a copy of the decimal object. + + >>> ExtendedContext.copy_decimal(Decimal('2.1')) + Decimal('2.1') + >>> ExtendedContext.copy_decimal(Decimal('-1.00')) + Decimal('-1.00') + >>> ExtendedContext.copy_decimal(1) + Decimal('1') + Returns a copy of the operand with the sign inverted. + + >>> ExtendedContext.copy_negate(Decimal('101.5')) + Decimal('-101.5') + >>> ExtendedContext.copy_negate(Decimal('-101.5')) + Decimal('101.5') + >>> ExtendedContext.copy_negate(1) + Decimal('-1') + Copies the second operand's sign to the first one. + + In detail, it returns a copy of the first operand with the sign + equal to the sign of the second operand. + + >>> ExtendedContext.copy_sign(Decimal( '1.50'), Decimal('7.33')) + Decimal('1.50') + >>> ExtendedContext.copy_sign(Decimal('-1.50'), Decimal('7.33')) + Decimal('1.50') + >>> ExtendedContext.copy_sign(Decimal( '1.50'), Decimal('-7.33')) + Decimal('-1.50') + >>> ExtendedContext.copy_sign(Decimal('-1.50'), Decimal('-7.33')) + Decimal('-1.50') + >>> ExtendedContext.copy_sign(1, -2) + Decimal('-1') + >>> ExtendedContext.copy_sign(Decimal(1), -2) + Decimal('-1') + >>> ExtendedContext.copy_sign(1, Decimal(-2)) + Decimal('-1') + Decimal division in a specified context. + + >>> ExtendedContext.divide(Decimal('1'), Decimal('3')) + Decimal('0.333333333') + >>> ExtendedContext.divide(Decimal('2'), Decimal('3')) + Decimal('0.666666667') + >>> ExtendedContext.divide(Decimal('5'), Decimal('2')) + Decimal('2.5') + >>> ExtendedContext.divide(Decimal('1'), Decimal('10')) + Decimal('0.1') + >>> ExtendedContext.divide(Decimal('12'), Decimal('12')) + Decimal('1') + >>> ExtendedContext.divide(Decimal('8.00'), Decimal('2')) + Decimal('4.00') + >>> ExtendedContext.divide(Decimal('2.400'), Decimal('2.0')) + Decimal('1.20') + >>> ExtendedContext.divide(Decimal('1000'), Decimal('100')) + Decimal('10') + >>> ExtendedContext.divide(Decimal('1000'), Decimal('1')) + Decimal('1000') + >>> ExtendedContext.divide(Decimal('2.40E+6'), Decimal('2')) + Decimal('1.20E+6') + >>> ExtendedContext.divide(5, 5) + Decimal('1') + >>> ExtendedContext.divide(Decimal(5), 5) + Decimal('1') + >>> ExtendedContext.divide(5, Decimal(5)) + Decimal('1') + Divides two numbers and returns the integer part of the result. + + >>> ExtendedContext.divide_int(Decimal('2'), Decimal('3')) + Decimal('0') + >>> ExtendedContext.divide_int(Decimal('10'), Decimal('3')) + Decimal('3') + >>> ExtendedContext.divide_int(Decimal('1'), Decimal('0.3')) + Decimal('3') + >>> ExtendedContext.divide_int(10, 3) + Decimal('3') + >>> ExtendedContext.divide_int(Decimal(10), 3) + Decimal('3') + >>> ExtendedContext.divide_int(10, Decimal(3)) + Decimal('3') + Return (a // b, a % b). + + >>> ExtendedContext.divmod(Decimal(8), Decimal(3)) + (Decimal('2'), Decimal('2')) + >>> ExtendedContext.divmod(Decimal(8), Decimal(4)) + (Decimal('2'), Decimal('0')) + >>> ExtendedContext.divmod(8, 4) + (Decimal('2'), Decimal('0')) + >>> ExtendedContext.divmod(Decimal(8), 4) + (Decimal('2'), Decimal('0')) + >>> ExtendedContext.divmod(8, Decimal(4)) + (Decimal('2'), Decimal('0')) + Returns e ** a. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.exp(Decimal('-Infinity')) + Decimal('0') + >>> c.exp(Decimal('-1')) + Decimal('0.367879441') + >>> c.exp(Decimal('0')) + Decimal('1') + >>> c.exp(Decimal('1')) + Decimal('2.71828183') + >>> c.exp(Decimal('0.693147181')) + Decimal('2.00000000') + >>> c.exp(Decimal('+Infinity')) + Decimal('Infinity') + >>> c.exp(10) + Decimal('22026.4658') + Returns a multiplied by b, plus c. + + The first two operands are multiplied together, using multiply, + the third operand is then added to the result of that + multiplication, using add, all with only one final rounding. + + >>> ExtendedContext.fma(Decimal('3'), Decimal('5'), Decimal('7')) + Decimal('22') + >>> ExtendedContext.fma(Decimal('3'), Decimal('-5'), Decimal('7')) + Decimal('-8') + >>> ExtendedContext.fma(Decimal('888565290'), Decimal('1557.96930'), Decimal('-86087.7578')) + Decimal('1.38435736E+12') + >>> ExtendedContext.fma(1, 3, 4) + Decimal('7') + >>> ExtendedContext.fma(1, Decimal(3), 4) + Decimal('7') + >>> ExtendedContext.fma(1, 3, Decimal(4)) + Decimal('7') + Return True if the operand is canonical; otherwise return False. + + Currently, the encoding of a Decimal instance is always + canonical, so this method returns True for any Decimal. + + >>> ExtendedContext.is_canonical(Decimal('2.50')) + True + is_canonical requires a Decimal as an argument.Return True if the operand is finite; otherwise return False. + + A Decimal instance is considered finite if it is neither + infinite nor a NaN. + + >>> ExtendedContext.is_finite(Decimal('2.50')) + True + >>> ExtendedContext.is_finite(Decimal('-0.3')) + True + >>> ExtendedContext.is_finite(Decimal('0')) + True + >>> ExtendedContext.is_finite(Decimal('Inf')) + False + >>> ExtendedContext.is_finite(Decimal('NaN')) + False + >>> ExtendedContext.is_finite(1) + True + Return True if the operand is infinite; otherwise return False. + + >>> ExtendedContext.is_infinite(Decimal('2.50')) + False + >>> ExtendedContext.is_infinite(Decimal('-Inf')) + True + >>> ExtendedContext.is_infinite(Decimal('NaN')) + False + >>> ExtendedContext.is_infinite(1) + False + Return True if the operand is a qNaN or sNaN; + otherwise return False. + + >>> ExtendedContext.is_nan(Decimal('2.50')) + False + >>> ExtendedContext.is_nan(Decimal('NaN')) + True + >>> ExtendedContext.is_nan(Decimal('-sNaN')) + True + >>> ExtendedContext.is_nan(1) + False + Return True if the operand is a normal number; + otherwise return False. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.is_normal(Decimal('2.50')) + True + >>> c.is_normal(Decimal('0.1E-999')) + False + >>> c.is_normal(Decimal('0.00')) + False + >>> c.is_normal(Decimal('-Inf')) + False + >>> c.is_normal(Decimal('NaN')) + False + >>> c.is_normal(1) + True + Return True if the operand is a quiet NaN; otherwise return False. + + >>> ExtendedContext.is_qnan(Decimal('2.50')) + False + >>> ExtendedContext.is_qnan(Decimal('NaN')) + True + >>> ExtendedContext.is_qnan(Decimal('sNaN')) + False + >>> ExtendedContext.is_qnan(1) + False + Return True if the operand is negative; otherwise return False. + + >>> ExtendedContext.is_signed(Decimal('2.50')) + False + >>> ExtendedContext.is_signed(Decimal('-12')) + True + >>> ExtendedContext.is_signed(Decimal('-0')) + True + >>> ExtendedContext.is_signed(8) + False + >>> ExtendedContext.is_signed(-8) + True + Return True if the operand is a signaling NaN; + otherwise return False. + + >>> ExtendedContext.is_snan(Decimal('2.50')) + False + >>> ExtendedContext.is_snan(Decimal('NaN')) + False + >>> ExtendedContext.is_snan(Decimal('sNaN')) + True + >>> ExtendedContext.is_snan(1) + False + Return True if the operand is subnormal; otherwise return False. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.is_subnormal(Decimal('2.50')) + False + >>> c.is_subnormal(Decimal('0.1E-999')) + True + >>> c.is_subnormal(Decimal('0.00')) + False + >>> c.is_subnormal(Decimal('-Inf')) + False + >>> c.is_subnormal(Decimal('NaN')) + False + >>> c.is_subnormal(1) + False + Return True if the operand is a zero; otherwise return False. + + >>> ExtendedContext.is_zero(Decimal('0')) + True + >>> ExtendedContext.is_zero(Decimal('2.50')) + False + >>> ExtendedContext.is_zero(Decimal('-0E+2')) + True + >>> ExtendedContext.is_zero(1) + False + >>> ExtendedContext.is_zero(0) + True + Returns the natural (base e) logarithm of the operand. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.ln(Decimal('0')) + Decimal('-Infinity') + >>> c.ln(Decimal('1.000')) + Decimal('0') + >>> c.ln(Decimal('2.71828183')) + Decimal('1.00000000') + >>> c.ln(Decimal('10')) + Decimal('2.30258509') + >>> c.ln(Decimal('+Infinity')) + Decimal('Infinity') + >>> c.ln(1) + Decimal('0') + Returns the base 10 logarithm of the operand. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.log10(Decimal('0')) + Decimal('-Infinity') + >>> c.log10(Decimal('0.001')) + Decimal('-3') + >>> c.log10(Decimal('1.000')) + Decimal('0') + >>> c.log10(Decimal('2')) + Decimal('0.301029996') + >>> c.log10(Decimal('10')) + Decimal('1') + >>> c.log10(Decimal('70')) + Decimal('1.84509804') + >>> c.log10(Decimal('+Infinity')) + Decimal('Infinity') + >>> c.log10(0) + Decimal('-Infinity') + >>> c.log10(1) + Decimal('0') + Returns the exponent of the magnitude of the operand's MSD. + + The result is the integer which is the exponent of the magnitude + of the most significant digit of the operand (as though the + operand were truncated to a single digit while maintaining the + value of that digit and without limiting the resulting exponent). + + >>> ExtendedContext.logb(Decimal('250')) + Decimal('2') + >>> ExtendedContext.logb(Decimal('2.50')) + Decimal('0') + >>> ExtendedContext.logb(Decimal('0.03')) + Decimal('-2') + >>> ExtendedContext.logb(Decimal('0')) + Decimal('-Infinity') + >>> ExtendedContext.logb(1) + Decimal('0') + >>> ExtendedContext.logb(10) + Decimal('1') + >>> ExtendedContext.logb(100) + Decimal('2') + Applies the logical operation 'and' between each operand's digits. + + The operands must be both logical numbers. + + >>> ExtendedContext.logical_and(Decimal('0'), Decimal('0')) + Decimal('0') + >>> ExtendedContext.logical_and(Decimal('0'), Decimal('1')) + Decimal('0') + >>> ExtendedContext.logical_and(Decimal('1'), Decimal('0')) + Decimal('0') + >>> ExtendedContext.logical_and(Decimal('1'), Decimal('1')) + Decimal('1') + >>> ExtendedContext.logical_and(Decimal('1100'), Decimal('1010')) + Decimal('1000') + >>> ExtendedContext.logical_and(Decimal('1111'), Decimal('10')) + Decimal('10') + >>> ExtendedContext.logical_and(110, 1101) + Decimal('100') + >>> ExtendedContext.logical_and(Decimal(110), 1101) + Decimal('100') + >>> ExtendedContext.logical_and(110, Decimal(1101)) + Decimal('100') + Invert all the digits in the operand. + + The operand must be a logical number. + + >>> ExtendedContext.logical_invert(Decimal('0')) + Decimal('111111111') + >>> ExtendedContext.logical_invert(Decimal('1')) + Decimal('111111110') + >>> ExtendedContext.logical_invert(Decimal('111111111')) + Decimal('0') + >>> ExtendedContext.logical_invert(Decimal('101010101')) + Decimal('10101010') + >>> ExtendedContext.logical_invert(1101) + Decimal('111110010') + Applies the logical operation 'or' between each operand's digits. + + The operands must be both logical numbers. + + >>> ExtendedContext.logical_or(Decimal('0'), Decimal('0')) + Decimal('0') + >>> ExtendedContext.logical_or(Decimal('0'), Decimal('1')) + Decimal('1') + >>> ExtendedContext.logical_or(Decimal('1'), Decimal('0')) + Decimal('1') + >>> ExtendedContext.logical_or(Decimal('1'), Decimal('1')) + Decimal('1') + >>> ExtendedContext.logical_or(Decimal('1100'), Decimal('1010')) + Decimal('1110') + >>> ExtendedContext.logical_or(Decimal('1110'), Decimal('10')) + Decimal('1110') + >>> ExtendedContext.logical_or(110, 1101) + Decimal('1111') + >>> ExtendedContext.logical_or(Decimal(110), 1101) + Decimal('1111') + >>> ExtendedContext.logical_or(110, Decimal(1101)) + Decimal('1111') + Applies the logical operation 'xor' between each operand's digits. + + The operands must be both logical numbers. + + >>> ExtendedContext.logical_xor(Decimal('0'), Decimal('0')) + Decimal('0') + >>> ExtendedContext.logical_xor(Decimal('0'), Decimal('1')) + Decimal('1') + >>> ExtendedContext.logical_xor(Decimal('1'), Decimal('0')) + Decimal('1') + >>> ExtendedContext.logical_xor(Decimal('1'), Decimal('1')) + Decimal('0') + >>> ExtendedContext.logical_xor(Decimal('1100'), Decimal('1010')) + Decimal('110') + >>> ExtendedContext.logical_xor(Decimal('1111'), Decimal('10')) + Decimal('1101') + >>> ExtendedContext.logical_xor(110, 1101) + Decimal('1011') + >>> ExtendedContext.logical_xor(Decimal(110), 1101) + Decimal('1011') + >>> ExtendedContext.logical_xor(110, Decimal(1101)) + Decimal('1011') + max compares two values numerically and returns the maximum. + + If either operand is a NaN then the general rules apply. + Otherwise, the operands are compared as though by the compare + operation. If they are numerically equal then the left-hand operand + is chosen as the result. Otherwise the maximum (closer to positive + infinity) of the two operands is chosen as the result. + + >>> ExtendedContext.max(Decimal('3'), Decimal('2')) + Decimal('3') + >>> ExtendedContext.max(Decimal('-10'), Decimal('3')) + Decimal('3') + >>> ExtendedContext.max(Decimal('1.0'), Decimal('1')) + Decimal('1') + >>> ExtendedContext.max(Decimal('7'), Decimal('NaN')) + Decimal('7') + >>> ExtendedContext.max(1, 2) + Decimal('2') + >>> ExtendedContext.max(Decimal(1), 2) + Decimal('2') + >>> ExtendedContext.max(1, Decimal(2)) + Decimal('2') + Compares the values numerically with their sign ignored. + + >>> ExtendedContext.max_mag(Decimal('7'), Decimal('NaN')) + Decimal('7') + >>> ExtendedContext.max_mag(Decimal('7'), Decimal('-10')) + Decimal('-10') + >>> ExtendedContext.max_mag(1, -2) + Decimal('-2') + >>> ExtendedContext.max_mag(Decimal(1), -2) + Decimal('-2') + >>> ExtendedContext.max_mag(1, Decimal(-2)) + Decimal('-2') + min compares two values numerically and returns the minimum. + + If either operand is a NaN then the general rules apply. + Otherwise, the operands are compared as though by the compare + operation. If they are numerically equal then the left-hand operand + is chosen as the result. Otherwise the minimum (closer to negative + infinity) of the two operands is chosen as the result. + + >>> ExtendedContext.min(Decimal('3'), Decimal('2')) + Decimal('2') + >>> ExtendedContext.min(Decimal('-10'), Decimal('3')) + Decimal('-10') + >>> ExtendedContext.min(Decimal('1.0'), Decimal('1')) + Decimal('1.0') + >>> ExtendedContext.min(Decimal('7'), Decimal('NaN')) + Decimal('7') + >>> ExtendedContext.min(1, 2) + Decimal('1') + >>> ExtendedContext.min(Decimal(1), 2) + Decimal('1') + >>> ExtendedContext.min(1, Decimal(29)) + Decimal('1') + Compares the values numerically with their sign ignored. + + >>> ExtendedContext.min_mag(Decimal('3'), Decimal('-2')) + Decimal('-2') + >>> ExtendedContext.min_mag(Decimal('-3'), Decimal('NaN')) + Decimal('-3') + >>> ExtendedContext.min_mag(1, -2) + Decimal('1') + >>> ExtendedContext.min_mag(Decimal(1), -2) + Decimal('1') + >>> ExtendedContext.min_mag(1, Decimal(-2)) + Decimal('1') + Minus corresponds to unary prefix minus in Python. + + The operation is evaluated using the same rules as subtract; the + operation minus(a) is calculated as subtract('0', a) where the '0' + has the same exponent as the operand. + + >>> ExtendedContext.minus(Decimal('1.3')) + Decimal('-1.3') + >>> ExtendedContext.minus(Decimal('-1.3')) + Decimal('1.3') + >>> ExtendedContext.minus(1) + Decimal('-1') + multiply multiplies two operands. + + If either operand is a special value then the general rules apply. + Otherwise, the operands are multiplied together + ('long multiplication'), resulting in a number which may be as long as + the sum of the lengths of the two operands. + + >>> ExtendedContext.multiply(Decimal('1.20'), Decimal('3')) + Decimal('3.60') + >>> ExtendedContext.multiply(Decimal('7'), Decimal('3')) + Decimal('21') + >>> ExtendedContext.multiply(Decimal('0.9'), Decimal('0.8')) + Decimal('0.72') + >>> ExtendedContext.multiply(Decimal('0.9'), Decimal('-0')) + Decimal('-0.0') + >>> ExtendedContext.multiply(Decimal('654321'), Decimal('654321')) + Decimal('4.28135971E+11') + >>> ExtendedContext.multiply(7, 7) + Decimal('49') + >>> ExtendedContext.multiply(Decimal(7), 7) + Decimal('49') + >>> ExtendedContext.multiply(7, Decimal(7)) + Decimal('49') + Returns the largest representable number smaller than a. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> ExtendedContext.next_minus(Decimal('1')) + Decimal('0.999999999') + >>> c.next_minus(Decimal('1E-1007')) + Decimal('0E-1007') + >>> ExtendedContext.next_minus(Decimal('-1.00000003')) + Decimal('-1.00000004') + >>> c.next_minus(Decimal('Infinity')) + Decimal('9.99999999E+999') + >>> c.next_minus(1) + Decimal('0.999999999') + Returns the smallest representable number larger than a. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> ExtendedContext.next_plus(Decimal('1')) + Decimal('1.00000001') + >>> c.next_plus(Decimal('-1E-1007')) + Decimal('-0E-1007') + >>> ExtendedContext.next_plus(Decimal('-1.00000003')) + Decimal('-1.00000002') + >>> c.next_plus(Decimal('-Infinity')) + Decimal('-9.99999999E+999') + >>> c.next_plus(1) + Decimal('1.00000001') + Returns the number closest to a, in direction towards b. + + The result is the closest representable number from the first + operand (but not the first operand) that is in the direction + towards the second operand, unless the operands have the same + value. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.next_toward(Decimal('1'), Decimal('2')) + Decimal('1.00000001') + >>> c.next_toward(Decimal('-1E-1007'), Decimal('1')) + Decimal('-0E-1007') + >>> c.next_toward(Decimal('-1.00000003'), Decimal('0')) + Decimal('-1.00000002') + >>> c.next_toward(Decimal('1'), Decimal('0')) + Decimal('0.999999999') + >>> c.next_toward(Decimal('1E-1007'), Decimal('-100')) + Decimal('0E-1007') + >>> c.next_toward(Decimal('-1.00000003'), Decimal('-10')) + Decimal('-1.00000004') + >>> c.next_toward(Decimal('0.00'), Decimal('-0.0000')) + Decimal('-0.00') + >>> c.next_toward(0, 1) + Decimal('1E-1007') + >>> c.next_toward(Decimal(0), 1) + Decimal('1E-1007') + >>> c.next_toward(0, Decimal(1)) + Decimal('1E-1007') + normalize reduces an operand to its simplest form. + + Essentially a plus operation with all trailing zeros removed from the + result. + + >>> ExtendedContext.normalize(Decimal('2.1')) + Decimal('2.1') + >>> ExtendedContext.normalize(Decimal('-2.0')) + Decimal('-2') + >>> ExtendedContext.normalize(Decimal('1.200')) + Decimal('1.2') + >>> ExtendedContext.normalize(Decimal('-120')) + Decimal('-1.2E+2') + >>> ExtendedContext.normalize(Decimal('120.00')) + Decimal('1.2E+2') + >>> ExtendedContext.normalize(Decimal('0.00')) + Decimal('0') + >>> ExtendedContext.normalize(6) + Decimal('6') + Returns an indication of the class of the operand. + + The class is one of the following strings: + -sNaN + -NaN + -Infinity + -Normal + -Subnormal + -Zero + +Zero + +Subnormal + +Normal + +Infinity + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.number_class(Decimal('Infinity')) + '+Infinity' + >>> c.number_class(Decimal('1E-10')) + '+Normal' + >>> c.number_class(Decimal('2.50')) + '+Normal' + >>> c.number_class(Decimal('0.1E-999')) + '+Subnormal' + >>> c.number_class(Decimal('0')) + '+Zero' + >>> c.number_class(Decimal('-0')) + '-Zero' + >>> c.number_class(Decimal('-0.1E-999')) + '-Subnormal' + >>> c.number_class(Decimal('-1E-10')) + '-Normal' + >>> c.number_class(Decimal('-2.50')) + '-Normal' + >>> c.number_class(Decimal('-Infinity')) + '-Infinity' + >>> c.number_class(Decimal('NaN')) + 'NaN' + >>> c.number_class(Decimal('-NaN')) + 'NaN' + >>> c.number_class(Decimal('sNaN')) + 'sNaN' + >>> c.number_class(123) + '+Normal' + Plus corresponds to unary prefix plus in Python. + + The operation is evaluated using the same rules as add; the + operation plus(a) is calculated as add('0', a) where the '0' + has the same exponent as the operand. + + >>> ExtendedContext.plus(Decimal('1.3')) + Decimal('1.3') + >>> ExtendedContext.plus(Decimal('-1.3')) + Decimal('-1.3') + >>> ExtendedContext.plus(-1) + Decimal('-1') + Raises a to the power of b, to modulo if given. + + With two arguments, compute a**b. If a is negative then b + must be integral. The result will be inexact unless b is + integral and the result is finite and can be expressed exactly + in 'precision' digits. + + With three arguments, compute (a**b) % modulo. For the + three argument form, the following restrictions on the + arguments hold: + + - all three arguments must be integral + - b must be nonnegative + - at least one of a or b must be nonzero + - modulo must be nonzero and have at most 'precision' digits + + The result of pow(a, b, modulo) is identical to the result + that would be obtained by computing (a**b) % modulo with + unbounded precision, but is computed more efficiently. It is + always exact. + + >>> c = ExtendedContext.copy() + >>> c.Emin = -999 + >>> c.Emax = 999 + >>> c.power(Decimal('2'), Decimal('3')) + Decimal('8') + >>> c.power(Decimal('-2'), Decimal('3')) + Decimal('-8') + >>> c.power(Decimal('2'), Decimal('-3')) + Decimal('0.125') + >>> c.power(Decimal('1.7'), Decimal('8')) + Decimal('69.7575744') + >>> c.power(Decimal('10'), Decimal('0.301029996')) + Decimal('2.00000000') + >>> c.power(Decimal('Infinity'), Decimal('-1')) + Decimal('0') + >>> c.power(Decimal('Infinity'), Decimal('0')) + Decimal('1') + >>> c.power(Decimal('Infinity'), Decimal('1')) + Decimal('Infinity') + >>> c.power(Decimal('-Infinity'), Decimal('-1')) + Decimal('-0') + >>> c.power(Decimal('-Infinity'), Decimal('0')) + Decimal('1') + >>> c.power(Decimal('-Infinity'), Decimal('1')) + Decimal('-Infinity') + >>> c.power(Decimal('-Infinity'), Decimal('2')) + Decimal('Infinity') + >>> c.power(Decimal('0'), Decimal('0')) + Decimal('NaN') + + >>> c.power(Decimal('3'), Decimal('7'), Decimal('16')) + Decimal('11') + >>> c.power(Decimal('-3'), Decimal('7'), Decimal('16')) + Decimal('-11') + >>> c.power(Decimal('-3'), Decimal('8'), Decimal('16')) + Decimal('1') + >>> c.power(Decimal('3'), Decimal('7'), Decimal('-16')) + Decimal('11') + >>> c.power(Decimal('23E12345'), Decimal('67E189'), Decimal('123456789')) + Decimal('11729830') + >>> c.power(Decimal('-0'), Decimal('17'), Decimal('1729')) + Decimal('-0') + >>> c.power(Decimal('-23'), Decimal('0'), Decimal('65537')) + Decimal('1') + >>> ExtendedContext.power(7, 7) + Decimal('823543') + >>> ExtendedContext.power(Decimal(7), 7) + Decimal('823543') + >>> ExtendedContext.power(7, Decimal(7), 2) + Decimal('1') + Returns a value equal to 'a' (rounded), having the exponent of 'b'. + + The coefficient of the result is derived from that of the left-hand + operand. It may be rounded using the current rounding setting (if the + exponent is being increased), multiplied by a positive power of ten (if + the exponent is being decreased), or is unchanged (if the exponent is + already equal to that of the right-hand operand). + + Unlike other operations, if the length of the coefficient after the + quantize operation would be greater than precision then an Invalid + operation condition is raised. This guarantees that, unless there is + an error condition, the exponent of the result of a quantize is always + equal to that of the right-hand operand. + + Also unlike other operations, quantize will never raise Underflow, even + if the result is subnormal and inexact. + + >>> ExtendedContext.quantize(Decimal('2.17'), Decimal('0.001')) + Decimal('2.170') + >>> ExtendedContext.quantize(Decimal('2.17'), Decimal('0.01')) + Decimal('2.17') + >>> ExtendedContext.quantize(Decimal('2.17'), Decimal('0.1')) + Decimal('2.2') + >>> ExtendedContext.quantize(Decimal('2.17'), Decimal('1e+0')) + Decimal('2') + >>> ExtendedContext.quantize(Decimal('2.17'), Decimal('1e+1')) + Decimal('0E+1') + >>> ExtendedContext.quantize(Decimal('-Inf'), Decimal('Infinity')) + Decimal('-Infinity') + >>> ExtendedContext.quantize(Decimal('2'), Decimal('Infinity')) + Decimal('NaN') + >>> ExtendedContext.quantize(Decimal('-0.1'), Decimal('1')) + Decimal('-0') + >>> ExtendedContext.quantize(Decimal('-0'), Decimal('1e+5')) + Decimal('-0E+5') + >>> ExtendedContext.quantize(Decimal('+35236450.6'), Decimal('1e-2')) + Decimal('NaN') + >>> ExtendedContext.quantize(Decimal('-35236450.6'), Decimal('1e-2')) + Decimal('NaN') + >>> ExtendedContext.quantize(Decimal('217'), Decimal('1e-1')) + Decimal('217.0') + >>> ExtendedContext.quantize(Decimal('217'), Decimal('1e-0')) + Decimal('217') + >>> ExtendedContext.quantize(Decimal('217'), Decimal('1e+1')) + Decimal('2.2E+2') + >>> ExtendedContext.quantize(Decimal('217'), Decimal('1e+2')) + Decimal('2E+2') + >>> ExtendedContext.quantize(1, 2) + Decimal('1') + >>> ExtendedContext.quantize(Decimal(1), 2) + Decimal('1') + >>> ExtendedContext.quantize(1, Decimal(2)) + Decimal('1') + Just returns 10, as this is Decimal, :) + + >>> ExtendedContext.radix() + Decimal('10') + Returns the remainder from integer division. + + The result is the residue of the dividend after the operation of + calculating integer division as described for divide-integer, rounded + to precision digits if necessary. The sign of the result, if + non-zero, is the same as that of the original dividend. + + This operation will fail under the same conditions as integer division + (that is, if integer division on the same two operands would fail, the + remainder cannot be calculated). + + >>> ExtendedContext.remainder(Decimal('2.1'), Decimal('3')) + Decimal('2.1') + >>> ExtendedContext.remainder(Decimal('10'), Decimal('3')) + Decimal('1') + >>> ExtendedContext.remainder(Decimal('-10'), Decimal('3')) + Decimal('-1') + >>> ExtendedContext.remainder(Decimal('10.2'), Decimal('1')) + Decimal('0.2') + >>> ExtendedContext.remainder(Decimal('10'), Decimal('0.3')) + Decimal('0.1') + >>> ExtendedContext.remainder(Decimal('3.6'), Decimal('1.3')) + Decimal('1.0') + >>> ExtendedContext.remainder(22, 6) + Decimal('4') + >>> ExtendedContext.remainder(Decimal(22), 6) + Decimal('4') + >>> ExtendedContext.remainder(22, Decimal(6)) + Decimal('4') + Returns to be "a - b * n", where n is the integer nearest the exact + value of "x / b" (if two integers are equally near then the even one + is chosen). If the result is equal to 0 then its sign will be the + sign of a. + + This operation will fail under the same conditions as integer division + (that is, if integer division on the same two operands would fail, the + remainder cannot be calculated). + + >>> ExtendedContext.remainder_near(Decimal('2.1'), Decimal('3')) + Decimal('-0.9') + >>> ExtendedContext.remainder_near(Decimal('10'), Decimal('6')) + Decimal('-2') + >>> ExtendedContext.remainder_near(Decimal('10'), Decimal('3')) + Decimal('1') + >>> ExtendedContext.remainder_near(Decimal('-10'), Decimal('3')) + Decimal('-1') + >>> ExtendedContext.remainder_near(Decimal('10.2'), Decimal('1')) + Decimal('0.2') + >>> ExtendedContext.remainder_near(Decimal('10'), Decimal('0.3')) + Decimal('0.1') + >>> ExtendedContext.remainder_near(Decimal('3.6'), Decimal('1.3')) + Decimal('-0.3') + >>> ExtendedContext.remainder_near(3, 11) + Decimal('3') + >>> ExtendedContext.remainder_near(Decimal(3), 11) + Decimal('3') + >>> ExtendedContext.remainder_near(3, Decimal(11)) + Decimal('3') + Returns a rotated copy of a, b times. + + The coefficient of the result is a rotated copy of the digits in + the coefficient of the first operand. The number of places of + rotation is taken from the absolute value of the second operand, + with the rotation being to the left if the second operand is + positive or to the right otherwise. + + >>> ExtendedContext.rotate(Decimal('34'), Decimal('8')) + Decimal('400000003') + >>> ExtendedContext.rotate(Decimal('12'), Decimal('9')) + Decimal('12') + >>> ExtendedContext.rotate(Decimal('123456789'), Decimal('-2')) + Decimal('891234567') + >>> ExtendedContext.rotate(Decimal('123456789'), Decimal('0')) + Decimal('123456789') + >>> ExtendedContext.rotate(Decimal('123456789'), Decimal('+2')) + Decimal('345678912') + >>> ExtendedContext.rotate(1333333, 1) + Decimal('13333330') + >>> ExtendedContext.rotate(Decimal(1333333), 1) + Decimal('13333330') + >>> ExtendedContext.rotate(1333333, Decimal(1)) + Decimal('13333330') + Returns True if the two operands have the same exponent. + + The result is never affected by either the sign or the coefficient of + either operand. + + >>> ExtendedContext.same_quantum(Decimal('2.17'), Decimal('0.001')) + False + >>> ExtendedContext.same_quantum(Decimal('2.17'), Decimal('0.01')) + True + >>> ExtendedContext.same_quantum(Decimal('2.17'), Decimal('1')) + False + >>> ExtendedContext.same_quantum(Decimal('Inf'), Decimal('-Inf')) + True + >>> ExtendedContext.same_quantum(10000, -1) + True + >>> ExtendedContext.same_quantum(Decimal(10000), -1) + True + >>> ExtendedContext.same_quantum(10000, Decimal(-1)) + True + Returns the first operand after adding the second value its exp. + + >>> ExtendedContext.scaleb(Decimal('7.50'), Decimal('-2')) + Decimal('0.0750') + >>> ExtendedContext.scaleb(Decimal('7.50'), Decimal('0')) + Decimal('7.50') + >>> ExtendedContext.scaleb(Decimal('7.50'), Decimal('3')) + Decimal('7.50E+3') + >>> ExtendedContext.scaleb(1, 4) + Decimal('1E+4') + >>> ExtendedContext.scaleb(Decimal(1), 4) + Decimal('1E+4') + >>> ExtendedContext.scaleb(1, Decimal(4)) + Decimal('1E+4') + Returns a shifted copy of a, b times. + + The coefficient of the result is a shifted copy of the digits + in the coefficient of the first operand. The number of places + to shift is taken from the absolute value of the second operand, + with the shift being to the left if the second operand is + positive or to the right otherwise. Digits shifted into the + coefficient are zeros. + + >>> ExtendedContext.shift(Decimal('34'), Decimal('8')) + Decimal('400000000') + >>> ExtendedContext.shift(Decimal('12'), Decimal('9')) + Decimal('0') + >>> ExtendedContext.shift(Decimal('123456789'), Decimal('-2')) + Decimal('1234567') + >>> ExtendedContext.shift(Decimal('123456789'), Decimal('0')) + Decimal('123456789') + >>> ExtendedContext.shift(Decimal('123456789'), Decimal('+2')) + Decimal('345678900') + >>> ExtendedContext.shift(88888888, 2) + Decimal('888888800') + >>> ExtendedContext.shift(Decimal(88888888), 2) + Decimal('888888800') + >>> ExtendedContext.shift(88888888, Decimal(2)) + Decimal('888888800') + Square root of a non-negative number to context precision. + + If the result must be inexact, it is rounded using the round-half-even + algorithm. + + >>> ExtendedContext.sqrt(Decimal('0')) + Decimal('0') + >>> ExtendedContext.sqrt(Decimal('-0')) + Decimal('-0') + >>> ExtendedContext.sqrt(Decimal('0.39')) + Decimal('0.624499800') + >>> ExtendedContext.sqrt(Decimal('100')) + Decimal('10') + >>> ExtendedContext.sqrt(Decimal('1')) + Decimal('1') + >>> ExtendedContext.sqrt(Decimal('1.0')) + Decimal('1.0') + >>> ExtendedContext.sqrt(Decimal('1.00')) + Decimal('1.0') + >>> ExtendedContext.sqrt(Decimal('7')) + Decimal('2.64575131') + >>> ExtendedContext.sqrt(Decimal('10')) + Decimal('3.16227766') + >>> ExtendedContext.sqrt(2) + Decimal('1.41421356') + >>> ExtendedContext.prec + 9 + Return the difference between the two operands. + + >>> ExtendedContext.subtract(Decimal('1.3'), Decimal('1.07')) + Decimal('0.23') + >>> ExtendedContext.subtract(Decimal('1.3'), Decimal('1.30')) + Decimal('0.00') + >>> ExtendedContext.subtract(Decimal('1.3'), Decimal('2.07')) + Decimal('-0.77') + >>> ExtendedContext.subtract(8, 5) + Decimal('3') + >>> ExtendedContext.subtract(Decimal(8), 5) + Decimal('3') + >>> ExtendedContext.subtract(8, Decimal(5)) + Decimal('3') + Convert to a string, using engineering notation if an exponent is needed. + + Engineering notation has an exponent which is a multiple of 3. This + can leave up to 3 digits to the left of the decimal place and may + require the addition of either one or two trailing zeros. + + The operation is not affected by the context. + + >>> ExtendedContext.to_eng_string(Decimal('123E+1')) + '1.23E+3' + >>> ExtendedContext.to_eng_string(Decimal('123E+3')) + '123E+3' + >>> ExtendedContext.to_eng_string(Decimal('123E-10')) + '12.3E-9' + >>> ExtendedContext.to_eng_string(Decimal('-123E-12')) + '-123E-12' + >>> ExtendedContext.to_eng_string(Decimal('7E-7')) + '700E-9' + >>> ExtendedContext.to_eng_string(Decimal('7E+1')) + '70' + >>> ExtendedContext.to_eng_string(Decimal('0E+1')) + '0.00E+3' + + Converts a number to a string, using scientific notation. + + The operation is not affected by the context. + Rounds to an integer. + + When the operand has a negative exponent, the result is the same + as using the quantize() operation using the given operand as the + left-hand-operand, 1E+0 as the right-hand-operand, and the precision + of the operand as the precision setting; Inexact and Rounded flags + are allowed in this operation. The rounding mode is taken from the + context. + + >>> ExtendedContext.to_integral_exact(Decimal('2.1')) + Decimal('2') + >>> ExtendedContext.to_integral_exact(Decimal('100')) + Decimal('100') + >>> ExtendedContext.to_integral_exact(Decimal('100.0')) + Decimal('100') + >>> ExtendedContext.to_integral_exact(Decimal('101.5')) + Decimal('102') + >>> ExtendedContext.to_integral_exact(Decimal('-101.5')) + Decimal('-102') + >>> ExtendedContext.to_integral_exact(Decimal('10E+5')) + Decimal('1.0E+6') + >>> ExtendedContext.to_integral_exact(Decimal('7.89E+77')) + Decimal('7.89E+77') + >>> ExtendedContext.to_integral_exact(Decimal('-Inf')) + Decimal('-Infinity') + Rounds to an integer. + + When the operand has a negative exponent, the result is the same + as using the quantize() operation using the given operand as the + left-hand-operand, 1E+0 as the right-hand-operand, and the precision + of the operand as the precision setting, except that no flags will + be set. The rounding mode is taken from the context. + + >>> ExtendedContext.to_integral_value(Decimal('2.1')) + Decimal('2') + >>> ExtendedContext.to_integral_value(Decimal('100')) + Decimal('100') + >>> ExtendedContext.to_integral_value(Decimal('100.0')) + Decimal('100') + >>> ExtendedContext.to_integral_value(Decimal('101.5')) + Decimal('102') + >>> ExtendedContext.to_integral_value(Decimal('-101.5')) + Decimal('-102') + >>> ExtendedContext.to_integral_value(Decimal('10E+5')) + Decimal('1.0E+6') + >>> ExtendedContext.to_integral_value(Decimal('7.89E+77')) + Decimal('7.89E+77') + >>> ExtendedContext.to_integral_value(Decimal('-Inf')) + Decimal('-Infinity') + (%r, %r, %r)Normalizes op1, op2 to have the same exp and length of coefficient. + + Done during addition. + tmptmp_lenother_len Given integers n and e, return n * 10**e if it's an integer, else None. + + The computation is designed to avoid computing large powers of 10 + unnecessarily. + + >>> _decimal_lshift_exact(3, 4) + 30000 + >>> _decimal_lshift_exact(300, -999999999) # returns None + + str_nval_n_sqrt_nearestClosest integer to the square root of the positive integer n. a is + an initial approximation to the square root. Any positive integer + will do for a, but the closer a is to the square root of n the + faster convergence will be. + + Both arguments to _sqrt_nearest should be positive._rshift_nearestGiven an integer x and a nonnegative integer shift, return closest + integer to x / 2**shift; use round-to-even in case of a tie. + + _div_nearestClosest integer to a/b, a and b positive integers; rounds to even + in the case of a tie. + + _ilogMInteger approximation to M*log(x/M), with absolute error boundable + in terms only of x/M. + + Given positive integers x and M, return an integer approximation to + M * log(x/M). For L = 8 and 0.1 <= x/M <= 10 the difference + between the approximation and the exact result is at most 22. For + L = 8 and 1.0 <= x/M <= 10.0 the difference is at most 15. In + both cases these are upper bounds on the error; it will usually be + much smaller.RyshiftGiven integers c, e and p with c > 0, p >= 0, compute an integer + approximation to 10**p * log10(c*10**e), with an absolute error of + at most 1. Assumes that c*10**e is not exactly 1.log_d_log10_digitslog_10log_tenpowerGiven integers c, e and p with c > 0, compute an integer + approximation to 10**p * log(c*10**e), with an absolute error of + at most 1. Assumes that c*10**e is not exactly 1.f_log_ten_Log10MemoizeClass to compute, store, and allow retrieval of, digits of the + constant log(10) = 2.302585.... This constant is needed by + Decimal.ln, Decimal.log10, Decimal.exp and Decimal.__pow__.23025850929940456840179914546843642076011014886getdigitsGiven an integer p >= 0, return floor(10**p)*log(10). + + For example, self.getdigits(3) returns 2302. + p should be nonnegative_iexpGiven integers x and M, M > 0, such that x/M is small in absolute + value, compute an integer approximation to M*exp(x/M). For 0 <= + x/M <= 2.4, the absolute error in the result is bounded by 60 (and + is usually much smaller).MshiftCompute an approximation to exp(c*10**e), with p decimal places of + precision. + + Returns integers d, f such that: + + 10**(p-1) <= d <= 10**p, and + (d-1)*10**f < exp(c*10**e) < (d+1)*10**f + + In other words, d*10**f is an approximation to exp(c*10**e) with p + digits of precision, and with an error in d of at most 1. This is + almost, but not quite, the same as the error being < 1ulp: when d + = 10**(p-1) the error could be up to 10 ulp.cshiftquotGiven integers xc, xe, yc and ye representing Decimals x = xc*10**xe and + y = yc*10**ye, compute x**y. Returns a pair of integers (c, e) such that: + + 10**(p-1) <= c <= 10**p, and + (c-1)*10**e < x**y < (c+1)*10**e + + in other words, c*10**e is an approximation to x**y with p digits + of precision, and with an error in c of at most 1. (This is + almost, but not quite, the same as the error being < 1ulp: when c + == 10**(p-1) we can only guarantee error < 10ulp.) + + We assume that: x is positive and not equal to 1, and y is nonzero. + lxcpc70correctionCompute a lower bound for 100*log10(c) for a positive integer c.The argument to _log10_lb should be nonnegative.str_callow_floatConvert other to Decimal. + + Verifies that it's ok to use in an implicit construction. + If allow_float is true, allow conversion from float; this + is used in the comparison methods (__eq__ and friends). + + Given a Decimal instance self and a Python object other, return + a pair (s, o) of Decimal instances such that "s op o" is + equivalent to "self op other" for any of the 6 comparison + operators "op". + + RationalComplex999999 # A numeric string consists of: +# \s* + (?P[-+])? # an optional sign, followed by either... + ( + (?=\d|\.\d) # ...a number (with at least one digit) + (?P\d*) # having a (possibly empty) integer part + (\.(?P\d*))? # followed by an optional fractional part + (E(?P[-+]?\d+))? # followed by an optional exponent, or... + | + Inf(inity)? # ...an infinity, or... + | + (?Ps)? # ...an (optionally signaling) + NaN # NaN + (?P\d*) # with (possibly empty) diagnostic info. + ) +# \s* + \Z +0*$50*$\A +(?: + (?P.)? + (?P[<>=^]) +)? +(?P[-+ ])? +(?P\#)? +(?P0)? +(?P(?!0)\d+)? +(?P,)? +(?:\.(?P0|(?!0)\d+))? +(?P[eEfFgG@�qSm�x \ No newline at end of file