@rowstile/cli-linux-x64 0.1.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +202 -0
- package/README.md +5 -0
- package/package.json +26 -0
- package/python/bin/python3.13 +0 -0
- package/python/bin/python3.13-config +122 -0
- package/python/lib/libpython3.13.so.1.0 +0 -0
- package/python/lib/libpython3.so +0 -0
- package/python/lib/python3.13/LICENSE.txt +277 -0
- package/python/lib/python3.13/__future__.py +147 -0
- package/python/lib/python3.13/__hello__.py +16 -0
- package/python/lib/python3.13/_aix_support.py +108 -0
- package/python/lib/python3.13/_android_support.py +192 -0
- package/python/lib/python3.13/_apple_support.py +66 -0
- package/python/lib/python3.13/_collections_abc.py +1187 -0
- package/python/lib/python3.13/_colorize.py +119 -0
- package/python/lib/python3.13/_compat_pickle.py +251 -0
- package/python/lib/python3.13/_compression.py +162 -0
- package/python/lib/python3.13/_ios_support.py +71 -0
- package/python/lib/python3.13/_markupbase.py +396 -0
- package/python/lib/python3.13/_opcode_metadata.py +343 -0
- package/python/lib/python3.13/_osx_support.py +579 -0
- package/python/lib/python3.13/_py_abc.py +147 -0
- package/python/lib/python3.13/_pydatetime.py +2640 -0
- package/python/lib/python3.13/_pydecimal.py +6356 -0
- package/python/lib/python3.13/_pyio.py +2714 -0
- package/python/lib/python3.13/_pylong.py +363 -0
- package/python/lib/python3.13/_pyrepl/__init__.py +19 -0
- package/python/lib/python3.13/_pyrepl/__main__.py +10 -0
- package/python/lib/python3.13/_pyrepl/_minimal_curses.py +68 -0
- package/python/lib/python3.13/_pyrepl/_threading_handler.py +74 -0
- package/python/lib/python3.13/_pyrepl/base_eventqueue.py +110 -0
- package/python/lib/python3.13/_pyrepl/commands.py +492 -0
- package/python/lib/python3.13/_pyrepl/completing_reader.py +295 -0
- package/python/lib/python3.13/_pyrepl/console.py +229 -0
- package/python/lib/python3.13/_pyrepl/curses.py +33 -0
- package/python/lib/python3.13/_pyrepl/fancy_termios.py +82 -0
- package/python/lib/python3.13/_pyrepl/historical_reader.py +419 -0
- package/python/lib/python3.13/_pyrepl/input.py +114 -0
- package/python/lib/python3.13/_pyrepl/keymap.py +213 -0
- package/python/lib/python3.13/_pyrepl/main.py +59 -0
- package/python/lib/python3.13/_pyrepl/mypy.ini +29 -0
- package/python/lib/python3.13/_pyrepl/pager.py +175 -0
- package/python/lib/python3.13/_pyrepl/reader.py +764 -0
- package/python/lib/python3.13/_pyrepl/readline.py +599 -0
- package/python/lib/python3.13/_pyrepl/simple_interact.py +180 -0
- package/python/lib/python3.13/_pyrepl/trace.py +21 -0
- package/python/lib/python3.13/_pyrepl/types.py +10 -0
- package/python/lib/python3.13/_pyrepl/unix_console.py +852 -0
- package/python/lib/python3.13/_pyrepl/unix_eventqueue.py +76 -0
- package/python/lib/python3.13/_pyrepl/utils.py +83 -0
- package/python/lib/python3.13/_pyrepl/windows_console.py +687 -0
- package/python/lib/python3.13/_pyrepl/windows_eventqueue.py +42 -0
- package/python/lib/python3.13/_sitebuiltins.py +91 -0
- package/python/lib/python3.13/_strptime.py +800 -0
- package/python/lib/python3.13/_sysconfigdata__linux_x86_64-linux-gnu.py +1079 -0
- package/python/lib/python3.13/_threading_local.py +120 -0
- package/python/lib/python3.13/_weakrefset.py +205 -0
- package/python/lib/python3.13/abc.py +188 -0
- package/python/lib/python3.13/antigravity.py +17 -0
- package/python/lib/python3.13/argparse.py +2690 -0
- package/python/lib/python3.13/ast.py +1865 -0
- package/python/lib/python3.13/asyncio/__init__.py +47 -0
- package/python/lib/python3.13/asyncio/__main__.py +211 -0
- package/python/lib/python3.13/asyncio/base_events.py +2086 -0
- package/python/lib/python3.13/asyncio/base_futures.py +67 -0
- package/python/lib/python3.13/asyncio/base_subprocess.py +312 -0
- package/python/lib/python3.13/asyncio/base_tasks.py +94 -0
- package/python/lib/python3.13/asyncio/constants.py +41 -0
- package/python/lib/python3.13/asyncio/coroutines.py +109 -0
- package/python/lib/python3.13/asyncio/events.py +885 -0
- package/python/lib/python3.13/asyncio/exceptions.py +62 -0
- package/python/lib/python3.13/asyncio/format_helpers.py +84 -0
- package/python/lib/python3.13/asyncio/futures.py +425 -0
- package/python/lib/python3.13/asyncio/locks.py +617 -0
- package/python/lib/python3.13/asyncio/log.py +7 -0
- package/python/lib/python3.13/asyncio/mixins.py +21 -0
- package/python/lib/python3.13/asyncio/proactor_events.py +891 -0
- package/python/lib/python3.13/asyncio/protocols.py +216 -0
- package/python/lib/python3.13/asyncio/queues.py +309 -0
- package/python/lib/python3.13/asyncio/runners.py +217 -0
- package/python/lib/python3.13/asyncio/selector_events.py +1328 -0
- package/python/lib/python3.13/asyncio/sslproto.py +929 -0
- package/python/lib/python3.13/asyncio/staggered.py +174 -0
- package/python/lib/python3.13/asyncio/streams.py +787 -0
- package/python/lib/python3.13/asyncio/subprocess.py +229 -0
- package/python/lib/python3.13/asyncio/taskgroups.py +278 -0
- package/python/lib/python3.13/asyncio/tasks.py +1121 -0
- package/python/lib/python3.13/asyncio/threads.py +26 -0
- package/python/lib/python3.13/asyncio/timeouts.py +185 -0
- package/python/lib/python3.13/asyncio/transports.py +337 -0
- package/python/lib/python3.13/asyncio/trsock.py +98 -0
- package/python/lib/python3.13/asyncio/unix_events.py +1550 -0
- package/python/lib/python3.13/asyncio/windows_events.py +906 -0
- package/python/lib/python3.13/asyncio/windows_utils.py +181 -0
- package/python/lib/python3.13/base64.py +628 -0
- package/python/lib/python3.13/bdb.py +973 -0
- package/python/lib/python3.13/bisect.py +118 -0
- package/python/lib/python3.13/bz2.py +352 -0
- package/python/lib/python3.13/cProfile.py +197 -0
- package/python/lib/python3.13/calendar.py +813 -0
- package/python/lib/python3.13/cmd.py +409 -0
- package/python/lib/python3.13/code.py +386 -0
- package/python/lib/python3.13/codecs.py +1132 -0
- package/python/lib/python3.13/codeop.py +155 -0
- package/python/lib/python3.13/collections/__init__.py +1603 -0
- package/python/lib/python3.13/colorsys.py +166 -0
- package/python/lib/python3.13/compileall.py +470 -0
- package/python/lib/python3.13/concurrent/__init__.py +1 -0
- package/python/lib/python3.13/concurrent/futures/__init__.py +54 -0
- package/python/lib/python3.13/concurrent/futures/_base.py +660 -0
- package/python/lib/python3.13/concurrent/futures/process.py +892 -0
- package/python/lib/python3.13/concurrent/futures/thread.py +240 -0
- package/python/lib/python3.13/configparser.py +1396 -0
- package/python/lib/python3.13/contextlib.py +814 -0
- package/python/lib/python3.13/contextvars.py +4 -0
- package/python/lib/python3.13/copy.py +306 -0
- package/python/lib/python3.13/copyreg.py +217 -0
- package/python/lib/python3.13/csv.py +527 -0
- package/python/lib/python3.13/ctypes/__init__.py +605 -0
- package/python/lib/python3.13/ctypes/_aix.py +327 -0
- package/python/lib/python3.13/ctypes/_endian.py +78 -0
- package/python/lib/python3.13/ctypes/macholib/README.ctypes +7 -0
- package/python/lib/python3.13/ctypes/macholib/__init__.py +9 -0
- package/python/lib/python3.13/ctypes/macholib/dyld.py +165 -0
- package/python/lib/python3.13/ctypes/macholib/dylib.py +42 -0
- package/python/lib/python3.13/ctypes/macholib/fetch_macholib +2 -0
- package/python/lib/python3.13/ctypes/macholib/fetch_macholib.bat +1 -0
- package/python/lib/python3.13/ctypes/macholib/framework.py +42 -0
- package/python/lib/python3.13/ctypes/util.py +387 -0
- package/python/lib/python3.13/ctypes/wintypes.py +202 -0
- package/python/lib/python3.13/curses/__init__.py +101 -0
- package/python/lib/python3.13/curses/ascii.py +99 -0
- package/python/lib/python3.13/curses/has_key.py +192 -0
- package/python/lib/python3.13/curses/panel.py +6 -0
- package/python/lib/python3.13/curses/textpad.py +236 -0
- package/python/lib/python3.13/dataclasses.py +1679 -0
- package/python/lib/python3.13/datetime.py +9 -0
- package/python/lib/python3.13/dbm/__init__.py +194 -0
- package/python/lib/python3.13/dbm/dumb.py +319 -0
- package/python/lib/python3.13/dbm/gnu.py +3 -0
- package/python/lib/python3.13/dbm/ndbm.py +3 -0
- package/python/lib/python3.13/dbm/sqlite3.py +144 -0
- package/python/lib/python3.13/decimal.py +109 -0
- package/python/lib/python3.13/difflib.py +2058 -0
- package/python/lib/python3.13/dis.py +1075 -0
- package/python/lib/python3.13/doctest.py +2919 -0
- package/python/lib/python3.13/email/__init__.py +61 -0
- package/python/lib/python3.13/email/_encoded_words.py +233 -0
- package/python/lib/python3.13/email/_header_value_parser.py +3153 -0
- package/python/lib/python3.13/email/_parseaddr.py +563 -0
- package/python/lib/python3.13/email/_policybase.py +382 -0
- package/python/lib/python3.13/email/architecture.rst +216 -0
- package/python/lib/python3.13/email/base64mime.py +115 -0
- package/python/lib/python3.13/email/charset.py +396 -0
- package/python/lib/python3.13/email/contentmanager.py +254 -0
- package/python/lib/python3.13/email/encoders.py +65 -0
- package/python/lib/python3.13/email/errors.py +117 -0
- package/python/lib/python3.13/email/feedparser.py +536 -0
- package/python/lib/python3.13/email/generator.py +530 -0
- package/python/lib/python3.13/email/header.py +582 -0
- package/python/lib/python3.13/email/headerregistry.py +618 -0
- package/python/lib/python3.13/email/iterators.py +68 -0
- package/python/lib/python3.13/email/message.py +1217 -0
- package/python/lib/python3.13/email/mime/__init__.py +0 -0
- package/python/lib/python3.13/email/mime/application.py +37 -0
- package/python/lib/python3.13/email/mime/audio.py +97 -0
- package/python/lib/python3.13/email/mime/base.py +29 -0
- package/python/lib/python3.13/email/mime/image.py +152 -0
- package/python/lib/python3.13/email/mime/message.py +33 -0
- package/python/lib/python3.13/email/mime/multipart.py +47 -0
- package/python/lib/python3.13/email/mime/nonmultipart.py +21 -0
- package/python/lib/python3.13/email/mime/text.py +40 -0
- package/python/lib/python3.13/email/parser.py +127 -0
- package/python/lib/python3.13/email/policy.py +232 -0
- package/python/lib/python3.13/email/quoprimime.py +300 -0
- package/python/lib/python3.13/email/utils.py +497 -0
- package/python/lib/python3.13/encodings/__init__.py +179 -0
- package/python/lib/python3.13/encodings/__pycache__/__init__.cpython-313.pyc +0 -0
- package/python/lib/python3.13/encodings/__pycache__/aliases.cpython-313.pyc +0 -0
- package/python/lib/python3.13/encodings/__pycache__/utf_8.cpython-313.pyc +0 -0
- package/python/lib/python3.13/encodings/aliases.py +560 -0
- package/python/lib/python3.13/encodings/ascii.py +50 -0
- package/python/lib/python3.13/encodings/base64_codec.py +55 -0
- package/python/lib/python3.13/encodings/big5.py +39 -0
- package/python/lib/python3.13/encodings/big5hkscs.py +39 -0
- package/python/lib/python3.13/encodings/bz2_codec.py +78 -0
- package/python/lib/python3.13/encodings/charmap.py +69 -0
- package/python/lib/python3.13/encodings/cp037.py +307 -0
- package/python/lib/python3.13/encodings/cp1006.py +307 -0
- package/python/lib/python3.13/encodings/cp1026.py +307 -0
- package/python/lib/python3.13/encodings/cp1125.py +698 -0
- package/python/lib/python3.13/encodings/cp1140.py +307 -0
- package/python/lib/python3.13/encodings/cp1250.py +307 -0
- package/python/lib/python3.13/encodings/cp1251.py +307 -0
- package/python/lib/python3.13/encodings/cp1252.py +307 -0
- package/python/lib/python3.13/encodings/cp1253.py +307 -0
- package/python/lib/python3.13/encodings/cp1254.py +307 -0
- package/python/lib/python3.13/encodings/cp1255.py +307 -0
- package/python/lib/python3.13/encodings/cp1256.py +307 -0
- package/python/lib/python3.13/encodings/cp1257.py +307 -0
- package/python/lib/python3.13/encodings/cp1258.py +307 -0
- package/python/lib/python3.13/encodings/cp273.py +307 -0
- package/python/lib/python3.13/encodings/cp424.py +307 -0
- package/python/lib/python3.13/encodings/cp437.py +698 -0
- package/python/lib/python3.13/encodings/cp500.py +307 -0
- package/python/lib/python3.13/encodings/cp720.py +309 -0
- package/python/lib/python3.13/encodings/cp737.py +698 -0
- package/python/lib/python3.13/encodings/cp775.py +697 -0
- package/python/lib/python3.13/encodings/cp850.py +698 -0
- package/python/lib/python3.13/encodings/cp852.py +698 -0
- package/python/lib/python3.13/encodings/cp855.py +698 -0
- package/python/lib/python3.13/encodings/cp856.py +307 -0
- package/python/lib/python3.13/encodings/cp857.py +694 -0
- package/python/lib/python3.13/encodings/cp858.py +698 -0
- package/python/lib/python3.13/encodings/cp860.py +698 -0
- package/python/lib/python3.13/encodings/cp861.py +698 -0
- package/python/lib/python3.13/encodings/cp862.py +698 -0
- package/python/lib/python3.13/encodings/cp863.py +698 -0
- package/python/lib/python3.13/encodings/cp864.py +690 -0
- package/python/lib/python3.13/encodings/cp865.py +698 -0
- package/python/lib/python3.13/encodings/cp866.py +698 -0
- package/python/lib/python3.13/encodings/cp869.py +689 -0
- package/python/lib/python3.13/encodings/cp874.py +307 -0
- package/python/lib/python3.13/encodings/cp875.py +307 -0
- package/python/lib/python3.13/encodings/cp932.py +39 -0
- package/python/lib/python3.13/encodings/cp949.py +39 -0
- package/python/lib/python3.13/encodings/cp950.py +39 -0
- package/python/lib/python3.13/encodings/euc_jis_2004.py +39 -0
- package/python/lib/python3.13/encodings/euc_jisx0213.py +39 -0
- package/python/lib/python3.13/encodings/euc_jp.py +39 -0
- package/python/lib/python3.13/encodings/euc_kr.py +39 -0
- package/python/lib/python3.13/encodings/gb18030.py +39 -0
- package/python/lib/python3.13/encodings/gb2312.py +39 -0
- package/python/lib/python3.13/encodings/gbk.py +39 -0
- package/python/lib/python3.13/encodings/hex_codec.py +55 -0
- package/python/lib/python3.13/encodings/hp_roman8.py +314 -0
- package/python/lib/python3.13/encodings/hz.py +39 -0
- package/python/lib/python3.13/encodings/idna.py +387 -0
- package/python/lib/python3.13/encodings/iso2022_jp.py +39 -0
- package/python/lib/python3.13/encodings/iso2022_jp_1.py +39 -0
- package/python/lib/python3.13/encodings/iso2022_jp_2.py +39 -0
- package/python/lib/python3.13/encodings/iso2022_jp_2004.py +39 -0
- package/python/lib/python3.13/encodings/iso2022_jp_3.py +39 -0
- package/python/lib/python3.13/encodings/iso2022_jp_ext.py +39 -0
- package/python/lib/python3.13/encodings/iso2022_kr.py +39 -0
- package/python/lib/python3.13/encodings/iso8859_1.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_10.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_11.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_13.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_14.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_15.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_16.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_2.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_3.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_4.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_5.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_6.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_7.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_8.py +307 -0
- package/python/lib/python3.13/encodings/iso8859_9.py +307 -0
- package/python/lib/python3.13/encodings/johab.py +39 -0
- package/python/lib/python3.13/encodings/koi8_r.py +307 -0
- package/python/lib/python3.13/encodings/koi8_t.py +308 -0
- package/python/lib/python3.13/encodings/koi8_u.py +307 -0
- package/python/lib/python3.13/encodings/kz1048.py +307 -0
- package/python/lib/python3.13/encodings/latin_1.py +50 -0
- package/python/lib/python3.13/encodings/mac_arabic.py +698 -0
- package/python/lib/python3.13/encodings/mac_croatian.py +307 -0
- package/python/lib/python3.13/encodings/mac_cyrillic.py +307 -0
- package/python/lib/python3.13/encodings/mac_farsi.py +307 -0
- package/python/lib/python3.13/encodings/mac_greek.py +307 -0
- package/python/lib/python3.13/encodings/mac_iceland.py +307 -0
- package/python/lib/python3.13/encodings/mac_latin2.py +312 -0
- package/python/lib/python3.13/encodings/mac_roman.py +307 -0
- package/python/lib/python3.13/encodings/mac_romanian.py +307 -0
- package/python/lib/python3.13/encodings/mac_turkish.py +307 -0
- package/python/lib/python3.13/encodings/mbcs.py +47 -0
- package/python/lib/python3.13/encodings/oem.py +41 -0
- package/python/lib/python3.13/encodings/palmos.py +308 -0
- package/python/lib/python3.13/encodings/ptcp154.py +312 -0
- package/python/lib/python3.13/encodings/punycode.py +253 -0
- package/python/lib/python3.13/encodings/quopri_codec.py +56 -0
- package/python/lib/python3.13/encodings/raw_unicode_escape.py +46 -0
- package/python/lib/python3.13/encodings/rot_13.py +113 -0
- package/python/lib/python3.13/encodings/shift_jis.py +39 -0
- package/python/lib/python3.13/encodings/shift_jis_2004.py +39 -0
- package/python/lib/python3.13/encodings/shift_jisx0213.py +39 -0
- package/python/lib/python3.13/encodings/tis_620.py +307 -0
- package/python/lib/python3.13/encodings/undefined.py +49 -0
- package/python/lib/python3.13/encodings/unicode_escape.py +46 -0
- package/python/lib/python3.13/encodings/utf_16.py +155 -0
- package/python/lib/python3.13/encodings/utf_16_be.py +42 -0
- package/python/lib/python3.13/encodings/utf_16_le.py +42 -0
- package/python/lib/python3.13/encodings/utf_32.py +150 -0
- package/python/lib/python3.13/encodings/utf_32_be.py +37 -0
- package/python/lib/python3.13/encodings/utf_32_le.py +37 -0
- package/python/lib/python3.13/encodings/utf_7.py +38 -0
- package/python/lib/python3.13/encodings/utf_8.py +42 -0
- package/python/lib/python3.13/encodings/utf_8_sig.py +130 -0
- package/python/lib/python3.13/encodings/uu_codec.py +103 -0
- package/python/lib/python3.13/encodings/zlib_codec.py +77 -0
- package/python/lib/python3.13/enum.py +2183 -0
- package/python/lib/python3.13/filecmp.py +320 -0
- package/python/lib/python3.13/fileinput.py +442 -0
- package/python/lib/python3.13/fnmatch.py +192 -0
- package/python/lib/python3.13/fractions.py +1043 -0
- package/python/lib/python3.13/ftplib.py +975 -0
- package/python/lib/python3.13/functools.py +1036 -0
- package/python/lib/python3.13/genericpath.py +200 -0
- package/python/lib/python3.13/getopt.py +215 -0
- package/python/lib/python3.13/getpass.py +192 -0
- package/python/lib/python3.13/gettext.py +657 -0
- package/python/lib/python3.13/glob.py +572 -0
- package/python/lib/python3.13/graphlib.py +250 -0
- package/python/lib/python3.13/gzip.py +693 -0
- package/python/lib/python3.13/hashlib.py +255 -0
- package/python/lib/python3.13/heapq.py +603 -0
- package/python/lib/python3.13/hmac.py +220 -0
- package/python/lib/python3.13/html/__init__.py +132 -0
- package/python/lib/python3.13/html/entities.py +2513 -0
- package/python/lib/python3.13/html/parser.py +583 -0
- package/python/lib/python3.13/http/__init__.py +202 -0
- package/python/lib/python3.13/http/client.py +1598 -0
- package/python/lib/python3.13/http/cookiejar.py +2122 -0
- package/python/lib/python3.13/http/cookies.py +635 -0
- package/python/lib/python3.13/http/server.py +1355 -0
- package/python/lib/python3.13/imaplib.py +1769 -0
- package/python/lib/python3.13/importlib/__init__.py +136 -0
- package/python/lib/python3.13/importlib/_abc.py +39 -0
- package/python/lib/python3.13/importlib/_bootstrap.py +1559 -0
- package/python/lib/python3.13/importlib/_bootstrap_external.py +1826 -0
- package/python/lib/python3.13/importlib/abc.py +243 -0
- package/python/lib/python3.13/importlib/machinery.py +21 -0
- package/python/lib/python3.13/importlib/metadata/__init__.py +1093 -0
- package/python/lib/python3.13/importlib/metadata/_adapters.py +89 -0
- package/python/lib/python3.13/importlib/metadata/_collections.py +30 -0
- package/python/lib/python3.13/importlib/metadata/_functools.py +104 -0
- package/python/lib/python3.13/importlib/metadata/_itertools.py +73 -0
- package/python/lib/python3.13/importlib/metadata/_meta.py +67 -0
- package/python/lib/python3.13/importlib/metadata/_text.py +99 -0
- package/python/lib/python3.13/importlib/metadata/diagnose.py +21 -0
- package/python/lib/python3.13/importlib/readers.py +12 -0
- package/python/lib/python3.13/importlib/resources/__init__.py +43 -0
- package/python/lib/python3.13/importlib/resources/_adapters.py +168 -0
- package/python/lib/python3.13/importlib/resources/_common.py +211 -0
- package/python/lib/python3.13/importlib/resources/_functional.py +81 -0
- package/python/lib/python3.13/importlib/resources/_itertools.py +38 -0
- package/python/lib/python3.13/importlib/resources/abc.py +173 -0
- package/python/lib/python3.13/importlib/resources/readers.py +203 -0
- package/python/lib/python3.13/importlib/resources/simple.py +106 -0
- package/python/lib/python3.13/importlib/simple.py +14 -0
- package/python/lib/python3.13/importlib/util.py +274 -0
- package/python/lib/python3.13/inspect.py +3479 -0
- package/python/lib/python3.13/io.py +99 -0
- package/python/lib/python3.13/ipaddress.py +2440 -0
- package/python/lib/python3.13/json/__init__.py +365 -0
- package/python/lib/python3.13/json/decoder.py +364 -0
- package/python/lib/python3.13/json/encoder.py +446 -0
- package/python/lib/python3.13/json/scanner.py +73 -0
- package/python/lib/python3.13/json/tool.py +90 -0
- package/python/lib/python3.13/keyword.py +64 -0
- package/python/lib/python3.13/lib-dynload/.empty +0 -0
- package/python/lib/python3.13/lib-dynload/_dbm.cpython-313-x86_64-linux-gnu.so +0 -0
- package/python/lib/python3.13/linecache.py +236 -0
- package/python/lib/python3.13/locale.py +1987 -0
- package/python/lib/python3.13/logging/__init__.py +2330 -0
- package/python/lib/python3.13/logging/config.py +1080 -0
- package/python/lib/python3.13/logging/handlers.py +1629 -0
- package/python/lib/python3.13/lzma.py +364 -0
- package/python/lib/python3.13/mailbox.py +2219 -0
- package/python/lib/python3.13/mimetypes.py +679 -0
- package/python/lib/python3.13/modulefinder.py +671 -0
- package/python/lib/python3.13/multiprocessing/__init__.py +37 -0
- package/python/lib/python3.13/multiprocessing/connection.py +1216 -0
- package/python/lib/python3.13/multiprocessing/context.py +383 -0
- package/python/lib/python3.13/multiprocessing/dummy/__init__.py +126 -0
- package/python/lib/python3.13/multiprocessing/dummy/connection.py +75 -0
- package/python/lib/python3.13/multiprocessing/forkserver.py +373 -0
- package/python/lib/python3.13/multiprocessing/heap.py +337 -0
- package/python/lib/python3.13/multiprocessing/managers.py +1397 -0
- package/python/lib/python3.13/multiprocessing/pool.py +957 -0
- package/python/lib/python3.13/multiprocessing/popen_fork.py +97 -0
- package/python/lib/python3.13/multiprocessing/popen_forkserver.py +74 -0
- package/python/lib/python3.13/multiprocessing/popen_spawn_posix.py +76 -0
- package/python/lib/python3.13/multiprocessing/popen_spawn_win32.py +147 -0
- package/python/lib/python3.13/multiprocessing/process.py +436 -0
- package/python/lib/python3.13/multiprocessing/queues.py +399 -0
- package/python/lib/python3.13/multiprocessing/reduction.py +281 -0
- package/python/lib/python3.13/multiprocessing/resource_sharer.py +154 -0
- package/python/lib/python3.13/multiprocessing/resource_tracker.py +499 -0
- package/python/lib/python3.13/multiprocessing/shared_memory.py +544 -0
- package/python/lib/python3.13/multiprocessing/sharedctypes.py +240 -0
- package/python/lib/python3.13/multiprocessing/spawn.py +307 -0
- package/python/lib/python3.13/multiprocessing/synchronize.py +404 -0
- package/python/lib/python3.13/multiprocessing/util.py +562 -0
- package/python/lib/python3.13/netrc.py +199 -0
- package/python/lib/python3.13/ntpath.py +872 -0
- package/python/lib/python3.13/nturl2path.py +69 -0
- package/python/lib/python3.13/numbers.py +427 -0
- package/python/lib/python3.13/opcode.py +115 -0
- package/python/lib/python3.13/operator.py +467 -0
- package/python/lib/python3.13/optparse.py +1681 -0
- package/python/lib/python3.13/os.py +1184 -0
- package/python/lib/python3.13/pathlib/__init__.py +12 -0
- package/python/lib/python3.13/pathlib/_abc.py +930 -0
- package/python/lib/python3.13/pathlib/_local.py +861 -0
- package/python/lib/python3.13/pdb.py +2550 -0
- package/python/lib/python3.13/pickle.py +1860 -0
- package/python/lib/python3.13/pickletools.py +2904 -0
- package/python/lib/python3.13/pkgutil.py +529 -0
- package/python/lib/python3.13/platform.py +1454 -0
- package/python/lib/python3.13/plistlib.py +948 -0
- package/python/lib/python3.13/poplib.py +477 -0
- package/python/lib/python3.13/posixpath.py +578 -0
- package/python/lib/python3.13/pprint.py +658 -0
- package/python/lib/python3.13/profile.py +616 -0
- package/python/lib/python3.13/pstats.py +778 -0
- package/python/lib/python3.13/pty.py +211 -0
- package/python/lib/python3.13/py_compile.py +212 -0
- package/python/lib/python3.13/pyclbr.py +314 -0
- package/python/lib/python3.13/pydoc.py +2861 -0
- package/python/lib/python3.13/queue.py +383 -0
- package/python/lib/python3.13/quopri.py +237 -0
- package/python/lib/python3.13/random.py +1078 -0
- package/python/lib/python3.13/re/__init__.py +428 -0
- package/python/lib/python3.13/re/_casefix.py +106 -0
- package/python/lib/python3.13/re/_compiler.py +768 -0
- package/python/lib/python3.13/re/_constants.py +222 -0
- package/python/lib/python3.13/re/_parser.py +1081 -0
- package/python/lib/python3.13/reprlib.py +230 -0
- package/python/lib/python3.13/rlcompleter.py +222 -0
- package/python/lib/python3.13/runpy.py +326 -0
- package/python/lib/python3.13/sched.py +167 -0
- package/python/lib/python3.13/secrets.py +71 -0
- package/python/lib/python3.13/selectors.py +603 -0
- package/python/lib/python3.13/shelve.py +250 -0
- package/python/lib/python3.13/shlex.py +345 -0
- package/python/lib/python3.13/shutil.py +1569 -0
- package/python/lib/python3.13/signal.py +94 -0
- package/python/lib/python3.13/site.py +773 -0
- package/python/lib/python3.13/smtplib.py +1123 -0
- package/python/lib/python3.13/socket.py +988 -0
- package/python/lib/python3.13/socketserver.py +863 -0
- package/python/lib/python3.13/sqlite3/__init__.py +70 -0
- package/python/lib/python3.13/sqlite3/__main__.py +139 -0
- package/python/lib/python3.13/sqlite3/dbapi2.py +108 -0
- package/python/lib/python3.13/sqlite3/dump.py +118 -0
- package/python/lib/python3.13/sre_compile.py +7 -0
- package/python/lib/python3.13/sre_constants.py +7 -0
- package/python/lib/python3.13/sre_parse.py +7 -0
- package/python/lib/python3.13/ssl.py +1541 -0
- package/python/lib/python3.13/stat.py +212 -0
- package/python/lib/python3.13/statistics.py +1817 -0
- package/python/lib/python3.13/string.py +314 -0
- package/python/lib/python3.13/stringprep.py +272 -0
- package/python/lib/python3.13/struct.py +15 -0
- package/python/lib/python3.13/subprocess.py +2258 -0
- package/python/lib/python3.13/symtable.py +414 -0
- package/python/lib/python3.13/sysconfig/__init__.py +734 -0
- package/python/lib/python3.13/sysconfig/__main__.py +248 -0
- package/python/lib/python3.13/tabnanny.py +340 -0
- package/python/lib/python3.13/tarfile.py +3136 -0
- package/python/lib/python3.13/tempfile.py +958 -0
- package/python/lib/python3.13/textwrap.py +497 -0
- package/python/lib/python3.13/this.py +28 -0
- package/python/lib/python3.13/threading.py +1602 -0
- package/python/lib/python3.13/timeit.py +381 -0
- package/python/lib/python3.13/token.py +141 -0
- package/python/lib/python3.13/tokenize.py +592 -0
- package/python/lib/python3.13/tomllib/__init__.py +10 -0
- package/python/lib/python3.13/tomllib/_parser.py +703 -0
- package/python/lib/python3.13/tomllib/_re.py +107 -0
- package/python/lib/python3.13/tomllib/_types.py +10 -0
- package/python/lib/python3.13/tomllib/mypy.ini +15 -0
- package/python/lib/python3.13/trace.py +754 -0
- package/python/lib/python3.13/traceback.py +1639 -0
- package/python/lib/python3.13/tracemalloc.py +560 -0
- package/python/lib/python3.13/tty.py +73 -0
- package/python/lib/python3.13/types.py +346 -0
- package/python/lib/python3.13/typing.py +3846 -0
- package/python/lib/python3.13/unittest/__init__.py +80 -0
- package/python/lib/python3.13/unittest/__main__.py +18 -0
- package/python/lib/python3.13/unittest/_log.py +86 -0
- package/python/lib/python3.13/unittest/async_case.py +146 -0
- package/python/lib/python3.13/unittest/case.py +1478 -0
- package/python/lib/python3.13/unittest/loader.py +460 -0
- package/python/lib/python3.13/unittest/main.py +280 -0
- package/python/lib/python3.13/unittest/mock.py +3189 -0
- package/python/lib/python3.13/unittest/result.py +256 -0
- package/python/lib/python3.13/unittest/runner.py +292 -0
- package/python/lib/python3.13/unittest/signals.py +71 -0
- package/python/lib/python3.13/unittest/suite.py +379 -0
- package/python/lib/python3.13/unittest/util.py +170 -0
- package/python/lib/python3.13/urllib/__init__.py +0 -0
- package/python/lib/python3.13/urllib/error.py +74 -0
- package/python/lib/python3.13/urllib/parse.py +1264 -0
- package/python/lib/python3.13/urllib/request.py +2796 -0
- package/python/lib/python3.13/urllib/response.py +84 -0
- package/python/lib/python3.13/urllib/robotparser.py +363 -0
- package/python/lib/python3.13/uuid.py +784 -0
- package/python/lib/python3.13/warnings.py +735 -0
- package/python/lib/python3.13/wave.py +665 -0
- package/python/lib/python3.13/weakref.py +674 -0
- package/python/lib/python3.13/webbrowser.py +724 -0
- package/python/lib/python3.13/wsgiref/__init__.py +25 -0
- package/python/lib/python3.13/wsgiref/handlers.py +575 -0
- package/python/lib/python3.13/wsgiref/headers.py +192 -0
- package/python/lib/python3.13/wsgiref/simple_server.py +161 -0
- package/python/lib/python3.13/wsgiref/types.py +54 -0
- package/python/lib/python3.13/wsgiref/util.py +159 -0
- package/python/lib/python3.13/wsgiref/validate.py +438 -0
- package/python/lib/python3.13/xml/__init__.py +20 -0
- package/python/lib/python3.13/xml/dom/NodeFilter.py +27 -0
- package/python/lib/python3.13/xml/dom/__init__.py +140 -0
- package/python/lib/python3.13/xml/dom/domreg.py +99 -0
- package/python/lib/python3.13/xml/dom/expatbuilder.py +962 -0
- package/python/lib/python3.13/xml/dom/minicompat.py +109 -0
- package/python/lib/python3.13/xml/dom/minidom.py +2024 -0
- package/python/lib/python3.13/xml/dom/pulldom.py +336 -0
- package/python/lib/python3.13/xml/dom/xmlbuilder.py +389 -0
- package/python/lib/python3.13/xml/etree/ElementInclude.py +186 -0
- package/python/lib/python3.13/xml/etree/ElementPath.py +430 -0
- package/python/lib/python3.13/xml/etree/ElementTree.py +2116 -0
- package/python/lib/python3.13/xml/etree/__init__.py +33 -0
- package/python/lib/python3.13/xml/etree/cElementTree.py +3 -0
- package/python/lib/python3.13/xml/parsers/__init__.py +8 -0
- package/python/lib/python3.13/xml/parsers/expat.py +8 -0
- package/python/lib/python3.13/xml/sax/__init__.py +94 -0
- package/python/lib/python3.13/xml/sax/_exceptions.py +127 -0
- package/python/lib/python3.13/xml/sax/expatreader.py +454 -0
- package/python/lib/python3.13/xml/sax/handler.py +387 -0
- package/python/lib/python3.13/xml/sax/saxutils.py +369 -0
- package/python/lib/python3.13/xml/sax/xmlreader.py +378 -0
- package/python/lib/python3.13/xmlrpc/__init__.py +1 -0
- package/python/lib/python3.13/xmlrpc/client.py +1503 -0
- package/python/lib/python3.13/xmlrpc/server.py +1002 -0
- package/python/lib/python3.13/zipapp.py +229 -0
- package/python/lib/python3.13/zipfile/__init__.py +2391 -0
- package/python/lib/python3.13/zipfile/__main__.py +4 -0
- package/python/lib/python3.13/zipfile/_path/__init__.py +452 -0
- package/python/lib/python3.13/zipfile/_path/glob.py +113 -0
- package/python/lib/python3.13/zipimport.py +803 -0
- package/python/lib/python3.13/zoneinfo/__init__.py +34 -0
- package/python/lib/python3.13/zoneinfo/_common.py +172 -0
- package/python/lib/python3.13/zoneinfo/_tzpath.py +189 -0
- package/python/lib/python3.13/zoneinfo/_zoneinfo.py +779 -0
- package/python/licenses/LICENSE.bdb.txt +126 -0
- package/python/licenses/LICENSE.bzip2.txt +37 -0
- package/python/licenses/LICENSE.cpython.txt +771 -0
- package/python/licenses/LICENSE.expat.txt +21 -0
- package/python/licenses/LICENSE.libX11.txt +942 -0
- package/python/licenses/LICENSE.libXau.txt +21 -0
- package/python/licenses/LICENSE.libedit.txt +29 -0
- package/python/licenses/LICENSE.libffi.txt +21 -0
- package/python/licenses/LICENSE.liblzma.txt +13 -0
- package/python/licenses/LICENSE.libuuid.txt +27 -0
- package/python/licenses/LICENSE.libxcb.txt +30 -0
- package/python/licenses/LICENSE.mpdecimal.txt +24 -0
- package/python/licenses/LICENSE.ncurses.txt +29 -0
- package/python/licenses/LICENSE.openssl-1.1.txt +124 -0
- package/python/licenses/LICENSE.openssl-3.txt +177 -0
- package/python/licenses/LICENSE.sqlite.txt +23 -0
- package/python/licenses/LICENSE.tcl.txt +40 -0
- package/python/licenses/LICENSE.tix.txt +54 -0
- package/python/licenses/LICENSE.zlib.txt +21 -0
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
"""A collection of string constants.
|
|
2
|
+
|
|
3
|
+
Public module variables:
|
|
4
|
+
|
|
5
|
+
whitespace -- a string containing all ASCII whitespace
|
|
6
|
+
ascii_lowercase -- a string containing all ASCII lowercase letters
|
|
7
|
+
ascii_uppercase -- a string containing all ASCII uppercase letters
|
|
8
|
+
ascii_letters -- a string containing all ASCII letters
|
|
9
|
+
digits -- a string containing all ASCII decimal digits
|
|
10
|
+
hexdigits -- a string containing all ASCII hexadecimal digits
|
|
11
|
+
octdigits -- a string containing all ASCII octal digits
|
|
12
|
+
punctuation -- a string containing all ASCII punctuation characters
|
|
13
|
+
printable -- a string containing all ASCII characters considered printable
|
|
14
|
+
|
|
15
|
+
"""
|
|
16
|
+
|
|
17
|
+
__all__ = ["ascii_letters", "ascii_lowercase", "ascii_uppercase", "capwords",
|
|
18
|
+
"digits", "hexdigits", "octdigits", "printable", "punctuation",
|
|
19
|
+
"whitespace", "Formatter", "Template"]
|
|
20
|
+
|
|
21
|
+
import _string
|
|
22
|
+
|
|
23
|
+
# Some strings for ctype-style character classification
|
|
24
|
+
whitespace = ' \t\n\r\v\f'
|
|
25
|
+
ascii_lowercase = 'abcdefghijklmnopqrstuvwxyz'
|
|
26
|
+
ascii_uppercase = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
|
|
27
|
+
ascii_letters = ascii_lowercase + ascii_uppercase
|
|
28
|
+
digits = '0123456789'
|
|
29
|
+
hexdigits = digits + 'abcdef' + 'ABCDEF'
|
|
30
|
+
octdigits = '01234567'
|
|
31
|
+
punctuation = r"""!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~"""
|
|
32
|
+
printable = digits + ascii_letters + punctuation + whitespace
|
|
33
|
+
|
|
34
|
+
# Functions which aren't available as string methods.
|
|
35
|
+
|
|
36
|
+
# Capitalize the words in a string, e.g. " aBc dEf " -> "Abc Def".
|
|
37
|
+
def capwords(s, sep=None):
|
|
38
|
+
"""capwords(s [,sep]) -> string
|
|
39
|
+
|
|
40
|
+
Split the argument into words using split, capitalize each
|
|
41
|
+
word using capitalize, and join the capitalized words using
|
|
42
|
+
join. If the optional second argument sep is absent or None,
|
|
43
|
+
runs of whitespace characters are replaced by a single space
|
|
44
|
+
and leading and trailing whitespace are removed, otherwise
|
|
45
|
+
sep is used to split and join the words.
|
|
46
|
+
|
|
47
|
+
"""
|
|
48
|
+
return (sep or ' ').join(map(str.capitalize, s.split(sep)))
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
####################################################################
|
|
52
|
+
import re as _re
|
|
53
|
+
from collections import ChainMap as _ChainMap
|
|
54
|
+
|
|
55
|
+
_sentinel_dict = {}
|
|
56
|
+
|
|
57
|
+
class Template:
|
|
58
|
+
"""A string class for supporting $-substitutions."""
|
|
59
|
+
|
|
60
|
+
delimiter = '$'
|
|
61
|
+
# r'[a-z]' matches to non-ASCII letters when used with IGNORECASE, but
|
|
62
|
+
# without the ASCII flag. We can't add re.ASCII to flags because of
|
|
63
|
+
# backward compatibility. So we use the ?a local flag and [a-z] pattern.
|
|
64
|
+
# See https://bugs.python.org/issue31672
|
|
65
|
+
idpattern = r'(?a:[_a-z][_a-z0-9]*)'
|
|
66
|
+
braceidpattern = None
|
|
67
|
+
flags = _re.IGNORECASE
|
|
68
|
+
|
|
69
|
+
def __init_subclass__(cls):
|
|
70
|
+
super().__init_subclass__()
|
|
71
|
+
if 'pattern' in cls.__dict__:
|
|
72
|
+
pattern = cls.pattern
|
|
73
|
+
if isinstance(pattern, _re.Pattern):
|
|
74
|
+
# An already-compiled pattern (which the documentation allows)
|
|
75
|
+
# is used as-is; re.compile() rejects flags on a compiled
|
|
76
|
+
# pattern.
|
|
77
|
+
return
|
|
78
|
+
else:
|
|
79
|
+
delim = _re.escape(cls.delimiter)
|
|
80
|
+
id = cls.idpattern
|
|
81
|
+
bid = cls.braceidpattern or cls.idpattern
|
|
82
|
+
pattern = fr"""
|
|
83
|
+
{delim}(?:
|
|
84
|
+
(?P<escaped>{delim}) | # Escape sequence of two delimiters
|
|
85
|
+
(?P<named>{id}) | # delimiter and a Python identifier
|
|
86
|
+
{{(?P<braced>{bid})}} | # delimiter and a braced identifier
|
|
87
|
+
(?P<invalid>) # Other ill-formed delimiter exprs
|
|
88
|
+
)
|
|
89
|
+
"""
|
|
90
|
+
cls.pattern = _re.compile(pattern, cls.flags | _re.VERBOSE)
|
|
91
|
+
|
|
92
|
+
def __init__(self, template):
|
|
93
|
+
self.template = template
|
|
94
|
+
|
|
95
|
+
# Search for $$, $identifier, ${identifier}, and any bare $'s
|
|
96
|
+
|
|
97
|
+
def _invalid(self, mo):
|
|
98
|
+
i = mo.start('invalid')
|
|
99
|
+
lines = self.template[:i].splitlines(keepends=True)
|
|
100
|
+
if not lines:
|
|
101
|
+
colno = 1
|
|
102
|
+
lineno = 1
|
|
103
|
+
else:
|
|
104
|
+
colno = i - len(''.join(lines[:-1]))
|
|
105
|
+
lineno = len(lines)
|
|
106
|
+
raise ValueError('Invalid placeholder in string: line %d, col %d' %
|
|
107
|
+
(lineno, colno))
|
|
108
|
+
|
|
109
|
+
def substitute(self, mapping=_sentinel_dict, /, **kws):
|
|
110
|
+
if mapping is _sentinel_dict:
|
|
111
|
+
mapping = kws
|
|
112
|
+
elif kws:
|
|
113
|
+
mapping = _ChainMap(kws, mapping)
|
|
114
|
+
# Helper function for .sub()
|
|
115
|
+
def convert(mo):
|
|
116
|
+
# Check the most common path first.
|
|
117
|
+
named = mo.group('named') or mo.group('braced')
|
|
118
|
+
if named is not None:
|
|
119
|
+
return str(mapping[named])
|
|
120
|
+
if mo.group('escaped') is not None:
|
|
121
|
+
return self.delimiter
|
|
122
|
+
if mo.group('invalid') is not None:
|
|
123
|
+
self._invalid(mo)
|
|
124
|
+
raise ValueError('Unrecognized named group in pattern',
|
|
125
|
+
self.pattern)
|
|
126
|
+
return self.pattern.sub(convert, self.template)
|
|
127
|
+
|
|
128
|
+
def safe_substitute(self, mapping=_sentinel_dict, /, **kws):
|
|
129
|
+
if mapping is _sentinel_dict:
|
|
130
|
+
mapping = kws
|
|
131
|
+
elif kws:
|
|
132
|
+
mapping = _ChainMap(kws, mapping)
|
|
133
|
+
# Helper function for .sub()
|
|
134
|
+
def convert(mo):
|
|
135
|
+
named = mo.group('named') or mo.group('braced')
|
|
136
|
+
if named is not None:
|
|
137
|
+
try:
|
|
138
|
+
return str(mapping[named])
|
|
139
|
+
except KeyError:
|
|
140
|
+
return mo.group()
|
|
141
|
+
if mo.group('escaped') is not None:
|
|
142
|
+
return self.delimiter
|
|
143
|
+
if mo.group('invalid') is not None:
|
|
144
|
+
return mo.group()
|
|
145
|
+
raise ValueError('Unrecognized named group in pattern',
|
|
146
|
+
self.pattern)
|
|
147
|
+
return self.pattern.sub(convert, self.template)
|
|
148
|
+
|
|
149
|
+
def is_valid(self):
|
|
150
|
+
for mo in self.pattern.finditer(self.template):
|
|
151
|
+
if mo.group('invalid') is not None:
|
|
152
|
+
return False
|
|
153
|
+
if (mo.group('named') is None
|
|
154
|
+
and mo.group('braced') is None
|
|
155
|
+
and mo.group('escaped') is None):
|
|
156
|
+
# If all the groups are None, there must be
|
|
157
|
+
# another group we're not expecting
|
|
158
|
+
raise ValueError('Unrecognized named group in pattern',
|
|
159
|
+
self.pattern)
|
|
160
|
+
return True
|
|
161
|
+
|
|
162
|
+
def get_identifiers(self):
|
|
163
|
+
ids = []
|
|
164
|
+
for mo in self.pattern.finditer(self.template):
|
|
165
|
+
named = mo.group('named') or mo.group('braced')
|
|
166
|
+
if named is not None and named not in ids:
|
|
167
|
+
# add a named group only the first time it appears
|
|
168
|
+
ids.append(named)
|
|
169
|
+
elif (named is None
|
|
170
|
+
and mo.group('invalid') is None
|
|
171
|
+
and mo.group('escaped') is None):
|
|
172
|
+
# If all the groups are None, there must be
|
|
173
|
+
# another group we're not expecting
|
|
174
|
+
raise ValueError('Unrecognized named group in pattern',
|
|
175
|
+
self.pattern)
|
|
176
|
+
return ids
|
|
177
|
+
|
|
178
|
+
# Initialize Template.pattern. __init_subclass__() is automatically called
|
|
179
|
+
# only for subclasses, not for the Template class itself.
|
|
180
|
+
Template.__init_subclass__()
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
########################################################################
|
|
184
|
+
# the Formatter class
|
|
185
|
+
# see PEP 3101 for details and purpose of this class
|
|
186
|
+
|
|
187
|
+
# The hard parts are reused from the C implementation. They're exposed as "_"
|
|
188
|
+
# prefixed methods of str.
|
|
189
|
+
|
|
190
|
+
# The overall parser is implemented in _string.formatter_parser.
|
|
191
|
+
# The field name parser is implemented in _string.formatter_field_name_split
|
|
192
|
+
|
|
193
|
+
class Formatter:
|
|
194
|
+
def format(self, format_string, /, *args, **kwargs):
|
|
195
|
+
return self.vformat(format_string, args, kwargs)
|
|
196
|
+
|
|
197
|
+
def vformat(self, format_string, args, kwargs):
|
|
198
|
+
used_args = set()
|
|
199
|
+
result, _ = self._vformat(format_string, args, kwargs, used_args, 2)
|
|
200
|
+
self.check_unused_args(used_args, args, kwargs)
|
|
201
|
+
return result
|
|
202
|
+
|
|
203
|
+
def _vformat(self, format_string, args, kwargs, used_args, recursion_depth,
|
|
204
|
+
auto_arg_index=0):
|
|
205
|
+
if recursion_depth < 0:
|
|
206
|
+
raise ValueError('Max string recursion exceeded')
|
|
207
|
+
result = []
|
|
208
|
+
for literal_text, field_name, format_spec, conversion in \
|
|
209
|
+
self.parse(format_string):
|
|
210
|
+
|
|
211
|
+
# output the literal text
|
|
212
|
+
if literal_text:
|
|
213
|
+
result.append(literal_text)
|
|
214
|
+
|
|
215
|
+
# if there's a field, output it
|
|
216
|
+
if field_name is not None:
|
|
217
|
+
# this is some markup, find the object and do
|
|
218
|
+
# the formatting
|
|
219
|
+
|
|
220
|
+
# handle arg indexing when empty field_names are given.
|
|
221
|
+
if field_name == '':
|
|
222
|
+
if auto_arg_index is False:
|
|
223
|
+
raise ValueError('cannot switch from manual field '
|
|
224
|
+
'specification to automatic field '
|
|
225
|
+
'numbering')
|
|
226
|
+
field_name = str(auto_arg_index)
|
|
227
|
+
auto_arg_index += 1
|
|
228
|
+
elif field_name.isdigit():
|
|
229
|
+
if auto_arg_index:
|
|
230
|
+
raise ValueError('cannot switch from manual field '
|
|
231
|
+
'specification to automatic field '
|
|
232
|
+
'numbering')
|
|
233
|
+
# disable auto arg incrementing, if it gets
|
|
234
|
+
# used later on, then an exception will be raised
|
|
235
|
+
auto_arg_index = False
|
|
236
|
+
|
|
237
|
+
# given the field_name, find the object it references
|
|
238
|
+
# and the argument it came from
|
|
239
|
+
obj, arg_used = self.get_field(field_name, args, kwargs)
|
|
240
|
+
used_args.add(arg_used)
|
|
241
|
+
|
|
242
|
+
# do any conversion on the resulting object
|
|
243
|
+
obj = self.convert_field(obj, conversion)
|
|
244
|
+
|
|
245
|
+
# expand the format spec, if needed
|
|
246
|
+
format_spec, auto_arg_index = self._vformat(
|
|
247
|
+
format_spec, args, kwargs,
|
|
248
|
+
used_args, recursion_depth-1,
|
|
249
|
+
auto_arg_index=auto_arg_index)
|
|
250
|
+
|
|
251
|
+
# format the object and append to the result
|
|
252
|
+
result.append(self.format_field(obj, format_spec))
|
|
253
|
+
|
|
254
|
+
return ''.join(result), auto_arg_index
|
|
255
|
+
|
|
256
|
+
|
|
257
|
+
def get_value(self, key, args, kwargs):
|
|
258
|
+
if isinstance(key, int):
|
|
259
|
+
return args[key]
|
|
260
|
+
else:
|
|
261
|
+
return kwargs[key]
|
|
262
|
+
|
|
263
|
+
|
|
264
|
+
def check_unused_args(self, used_args, args, kwargs):
|
|
265
|
+
pass
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
def format_field(self, value, format_spec):
|
|
269
|
+
return format(value, format_spec)
|
|
270
|
+
|
|
271
|
+
|
|
272
|
+
def convert_field(self, value, conversion):
|
|
273
|
+
# do any conversion on the resulting object
|
|
274
|
+
if conversion is None:
|
|
275
|
+
return value
|
|
276
|
+
elif conversion == 's':
|
|
277
|
+
return str(value)
|
|
278
|
+
elif conversion == 'r':
|
|
279
|
+
return repr(value)
|
|
280
|
+
elif conversion == 'a':
|
|
281
|
+
return ascii(value)
|
|
282
|
+
raise ValueError("Unknown conversion specifier {0!s}".format(conversion))
|
|
283
|
+
|
|
284
|
+
|
|
285
|
+
# returns an iterable that contains tuples of the form:
|
|
286
|
+
# (literal_text, field_name, format_spec, conversion)
|
|
287
|
+
# literal_text can be zero length
|
|
288
|
+
# field_name can be None, in which case there's no
|
|
289
|
+
# object to format and output
|
|
290
|
+
# if field_name is not None, it is looked up, formatted
|
|
291
|
+
# with format_spec and conversion and then used
|
|
292
|
+
def parse(self, format_string):
|
|
293
|
+
return _string.formatter_parser(format_string)
|
|
294
|
+
|
|
295
|
+
|
|
296
|
+
# given a field_name, find the object it references.
|
|
297
|
+
# field_name: the field being looked up, e.g. "0.name"
|
|
298
|
+
# or "lookup[3]"
|
|
299
|
+
# used_args: a set of which args have been used
|
|
300
|
+
# args, kwargs: as passed in to vformat
|
|
301
|
+
def get_field(self, field_name, args, kwargs):
|
|
302
|
+
first, rest = _string.formatter_field_name_split(field_name)
|
|
303
|
+
|
|
304
|
+
obj = self.get_value(first, args, kwargs)
|
|
305
|
+
|
|
306
|
+
# loop through the rest of the field_name, doing
|
|
307
|
+
# getattr or getitem as needed
|
|
308
|
+
for is_attr, i in rest:
|
|
309
|
+
if is_attr:
|
|
310
|
+
obj = getattr(obj, i)
|
|
311
|
+
else:
|
|
312
|
+
obj = obj[i]
|
|
313
|
+
|
|
314
|
+
return obj, first
|
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
# This file is generated by mkstringprep.py. DO NOT EDIT.
|
|
2
|
+
"""Library that exposes various tables found in the StringPrep RFC 3454.
|
|
3
|
+
|
|
4
|
+
There are two kinds of tables: sets, for which a member test is provided,
|
|
5
|
+
and mappings, for which a mapping function is provided.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
from unicodedata import ucd_3_2_0 as unicodedata
|
|
9
|
+
|
|
10
|
+
assert unicodedata.unidata_version == '3.2.0'
|
|
11
|
+
|
|
12
|
+
def in_table_a1(code):
|
|
13
|
+
if unicodedata.category(code) != 'Cn': return False
|
|
14
|
+
c = ord(code)
|
|
15
|
+
if 0xFDD0 <= c < 0xFDF0: return False
|
|
16
|
+
return (c & 0xFFFF) not in (0xFFFE, 0xFFFF)
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
b1_set = set([173, 847, 6150, 6155, 6156, 6157, 8203, 8204, 8205, 8288, 65279] + list(range(65024,65040)))
|
|
20
|
+
def in_table_b1(code):
|
|
21
|
+
return ord(code) in b1_set
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
b3_exceptions = {
|
|
25
|
+
0xb5:'\u03bc', 0xdf:'ss', 0x130:'i\u0307', 0x149:'\u02bcn',
|
|
26
|
+
0x17f:'s', 0x1f0:'j\u030c', 0x345:'\u03b9', 0x37a:' \u03b9',
|
|
27
|
+
0x390:'\u03b9\u0308\u0301', 0x3b0:'\u03c5\u0308\u0301', 0x3c2:'\u03c3', 0x3d0:'\u03b2',
|
|
28
|
+
0x3d1:'\u03b8', 0x3d2:'\u03c5', 0x3d3:'\u03cd', 0x3d4:'\u03cb',
|
|
29
|
+
0x3d5:'\u03c6', 0x3d6:'\u03c0', 0x3f0:'\u03ba', 0x3f1:'\u03c1',
|
|
30
|
+
0x3f2:'\u03c3', 0x3f5:'\u03b5', 0x587:'\u0565\u0582', 0x1e96:'h\u0331',
|
|
31
|
+
0x1e97:'t\u0308', 0x1e98:'w\u030a', 0x1e99:'y\u030a', 0x1e9a:'a\u02be',
|
|
32
|
+
0x1e9b:'\u1e61', 0x1f50:'\u03c5\u0313', 0x1f52:'\u03c5\u0313\u0300', 0x1f54:'\u03c5\u0313\u0301',
|
|
33
|
+
0x1f56:'\u03c5\u0313\u0342', 0x1f80:'\u1f00\u03b9', 0x1f81:'\u1f01\u03b9', 0x1f82:'\u1f02\u03b9',
|
|
34
|
+
0x1f83:'\u1f03\u03b9', 0x1f84:'\u1f04\u03b9', 0x1f85:'\u1f05\u03b9', 0x1f86:'\u1f06\u03b9',
|
|
35
|
+
0x1f87:'\u1f07\u03b9', 0x1f88:'\u1f00\u03b9', 0x1f89:'\u1f01\u03b9', 0x1f8a:'\u1f02\u03b9',
|
|
36
|
+
0x1f8b:'\u1f03\u03b9', 0x1f8c:'\u1f04\u03b9', 0x1f8d:'\u1f05\u03b9', 0x1f8e:'\u1f06\u03b9',
|
|
37
|
+
0x1f8f:'\u1f07\u03b9', 0x1f90:'\u1f20\u03b9', 0x1f91:'\u1f21\u03b9', 0x1f92:'\u1f22\u03b9',
|
|
38
|
+
0x1f93:'\u1f23\u03b9', 0x1f94:'\u1f24\u03b9', 0x1f95:'\u1f25\u03b9', 0x1f96:'\u1f26\u03b9',
|
|
39
|
+
0x1f97:'\u1f27\u03b9', 0x1f98:'\u1f20\u03b9', 0x1f99:'\u1f21\u03b9', 0x1f9a:'\u1f22\u03b9',
|
|
40
|
+
0x1f9b:'\u1f23\u03b9', 0x1f9c:'\u1f24\u03b9', 0x1f9d:'\u1f25\u03b9', 0x1f9e:'\u1f26\u03b9',
|
|
41
|
+
0x1f9f:'\u1f27\u03b9', 0x1fa0:'\u1f60\u03b9', 0x1fa1:'\u1f61\u03b9', 0x1fa2:'\u1f62\u03b9',
|
|
42
|
+
0x1fa3:'\u1f63\u03b9', 0x1fa4:'\u1f64\u03b9', 0x1fa5:'\u1f65\u03b9', 0x1fa6:'\u1f66\u03b9',
|
|
43
|
+
0x1fa7:'\u1f67\u03b9', 0x1fa8:'\u1f60\u03b9', 0x1fa9:'\u1f61\u03b9', 0x1faa:'\u1f62\u03b9',
|
|
44
|
+
0x1fab:'\u1f63\u03b9', 0x1fac:'\u1f64\u03b9', 0x1fad:'\u1f65\u03b9', 0x1fae:'\u1f66\u03b9',
|
|
45
|
+
0x1faf:'\u1f67\u03b9', 0x1fb2:'\u1f70\u03b9', 0x1fb3:'\u03b1\u03b9', 0x1fb4:'\u03ac\u03b9',
|
|
46
|
+
0x1fb6:'\u03b1\u0342', 0x1fb7:'\u03b1\u0342\u03b9', 0x1fbc:'\u03b1\u03b9', 0x1fbe:'\u03b9',
|
|
47
|
+
0x1fc2:'\u1f74\u03b9', 0x1fc3:'\u03b7\u03b9', 0x1fc4:'\u03ae\u03b9', 0x1fc6:'\u03b7\u0342',
|
|
48
|
+
0x1fc7:'\u03b7\u0342\u03b9', 0x1fcc:'\u03b7\u03b9', 0x1fd2:'\u03b9\u0308\u0300', 0x1fd3:'\u03b9\u0308\u0301',
|
|
49
|
+
0x1fd6:'\u03b9\u0342', 0x1fd7:'\u03b9\u0308\u0342', 0x1fe2:'\u03c5\u0308\u0300', 0x1fe3:'\u03c5\u0308\u0301',
|
|
50
|
+
0x1fe4:'\u03c1\u0313', 0x1fe6:'\u03c5\u0342', 0x1fe7:'\u03c5\u0308\u0342', 0x1ff2:'\u1f7c\u03b9',
|
|
51
|
+
0x1ff3:'\u03c9\u03b9', 0x1ff4:'\u03ce\u03b9', 0x1ff6:'\u03c9\u0342', 0x1ff7:'\u03c9\u0342\u03b9',
|
|
52
|
+
0x1ffc:'\u03c9\u03b9', 0x20a8:'rs', 0x2102:'c', 0x2103:'\xb0c',
|
|
53
|
+
0x2107:'\u025b', 0x2109:'\xb0f', 0x210b:'h', 0x210c:'h',
|
|
54
|
+
0x210d:'h', 0x2110:'i', 0x2111:'i', 0x2112:'l',
|
|
55
|
+
0x2115:'n', 0x2116:'no', 0x2119:'p', 0x211a:'q',
|
|
56
|
+
0x211b:'r', 0x211c:'r', 0x211d:'r', 0x2120:'sm',
|
|
57
|
+
0x2121:'tel', 0x2122:'tm', 0x2124:'z', 0x2128:'z',
|
|
58
|
+
0x212c:'b', 0x212d:'c', 0x2130:'e', 0x2131:'f',
|
|
59
|
+
0x2133:'m', 0x213e:'\u03b3', 0x213f:'\u03c0', 0x2145:'d',
|
|
60
|
+
0x3371:'hpa', 0x3373:'au', 0x3375:'ov', 0x3380:'pa',
|
|
61
|
+
0x3381:'na', 0x3382:'\u03bca', 0x3383:'ma', 0x3384:'ka',
|
|
62
|
+
0x3385:'kb', 0x3386:'mb', 0x3387:'gb', 0x338a:'pf',
|
|
63
|
+
0x338b:'nf', 0x338c:'\u03bcf', 0x3390:'hz', 0x3391:'khz',
|
|
64
|
+
0x3392:'mhz', 0x3393:'ghz', 0x3394:'thz', 0x33a9:'pa',
|
|
65
|
+
0x33aa:'kpa', 0x33ab:'mpa', 0x33ac:'gpa', 0x33b4:'pv',
|
|
66
|
+
0x33b5:'nv', 0x33b6:'\u03bcv', 0x33b7:'mv', 0x33b8:'kv',
|
|
67
|
+
0x33b9:'mv', 0x33ba:'pw', 0x33bb:'nw', 0x33bc:'\u03bcw',
|
|
68
|
+
0x33bd:'mw', 0x33be:'kw', 0x33bf:'mw', 0x33c0:'k\u03c9',
|
|
69
|
+
0x33c1:'m\u03c9', 0x33c3:'bq', 0x33c6:'c\u2215kg', 0x33c7:'co.',
|
|
70
|
+
0x33c8:'db', 0x33c9:'gy', 0x33cb:'hp', 0x33cd:'kk',
|
|
71
|
+
0x33ce:'km', 0x33d7:'ph', 0x33d9:'ppm', 0x33da:'pr',
|
|
72
|
+
0x33dc:'sv', 0x33dd:'wb', 0xfb00:'ff', 0xfb01:'fi',
|
|
73
|
+
0xfb02:'fl', 0xfb03:'ffi', 0xfb04:'ffl', 0xfb05:'st',
|
|
74
|
+
0xfb06:'st', 0xfb13:'\u0574\u0576', 0xfb14:'\u0574\u0565', 0xfb15:'\u0574\u056b',
|
|
75
|
+
0xfb16:'\u057e\u0576', 0xfb17:'\u0574\u056d', 0x1d400:'a', 0x1d401:'b',
|
|
76
|
+
0x1d402:'c', 0x1d403:'d', 0x1d404:'e', 0x1d405:'f',
|
|
77
|
+
0x1d406:'g', 0x1d407:'h', 0x1d408:'i', 0x1d409:'j',
|
|
78
|
+
0x1d40a:'k', 0x1d40b:'l', 0x1d40c:'m', 0x1d40d:'n',
|
|
79
|
+
0x1d40e:'o', 0x1d40f:'p', 0x1d410:'q', 0x1d411:'r',
|
|
80
|
+
0x1d412:'s', 0x1d413:'t', 0x1d414:'u', 0x1d415:'v',
|
|
81
|
+
0x1d416:'w', 0x1d417:'x', 0x1d418:'y', 0x1d419:'z',
|
|
82
|
+
0x1d434:'a', 0x1d435:'b', 0x1d436:'c', 0x1d437:'d',
|
|
83
|
+
0x1d438:'e', 0x1d439:'f', 0x1d43a:'g', 0x1d43b:'h',
|
|
84
|
+
0x1d43c:'i', 0x1d43d:'j', 0x1d43e:'k', 0x1d43f:'l',
|
|
85
|
+
0x1d440:'m', 0x1d441:'n', 0x1d442:'o', 0x1d443:'p',
|
|
86
|
+
0x1d444:'q', 0x1d445:'r', 0x1d446:'s', 0x1d447:'t',
|
|
87
|
+
0x1d448:'u', 0x1d449:'v', 0x1d44a:'w', 0x1d44b:'x',
|
|
88
|
+
0x1d44c:'y', 0x1d44d:'z', 0x1d468:'a', 0x1d469:'b',
|
|
89
|
+
0x1d46a:'c', 0x1d46b:'d', 0x1d46c:'e', 0x1d46d:'f',
|
|
90
|
+
0x1d46e:'g', 0x1d46f:'h', 0x1d470:'i', 0x1d471:'j',
|
|
91
|
+
0x1d472:'k', 0x1d473:'l', 0x1d474:'m', 0x1d475:'n',
|
|
92
|
+
0x1d476:'o', 0x1d477:'p', 0x1d478:'q', 0x1d479:'r',
|
|
93
|
+
0x1d47a:'s', 0x1d47b:'t', 0x1d47c:'u', 0x1d47d:'v',
|
|
94
|
+
0x1d47e:'w', 0x1d47f:'x', 0x1d480:'y', 0x1d481:'z',
|
|
95
|
+
0x1d49c:'a', 0x1d49e:'c', 0x1d49f:'d', 0x1d4a2:'g',
|
|
96
|
+
0x1d4a5:'j', 0x1d4a6:'k', 0x1d4a9:'n', 0x1d4aa:'o',
|
|
97
|
+
0x1d4ab:'p', 0x1d4ac:'q', 0x1d4ae:'s', 0x1d4af:'t',
|
|
98
|
+
0x1d4b0:'u', 0x1d4b1:'v', 0x1d4b2:'w', 0x1d4b3:'x',
|
|
99
|
+
0x1d4b4:'y', 0x1d4b5:'z', 0x1d4d0:'a', 0x1d4d1:'b',
|
|
100
|
+
0x1d4d2:'c', 0x1d4d3:'d', 0x1d4d4:'e', 0x1d4d5:'f',
|
|
101
|
+
0x1d4d6:'g', 0x1d4d7:'h', 0x1d4d8:'i', 0x1d4d9:'j',
|
|
102
|
+
0x1d4da:'k', 0x1d4db:'l', 0x1d4dc:'m', 0x1d4dd:'n',
|
|
103
|
+
0x1d4de:'o', 0x1d4df:'p', 0x1d4e0:'q', 0x1d4e1:'r',
|
|
104
|
+
0x1d4e2:'s', 0x1d4e3:'t', 0x1d4e4:'u', 0x1d4e5:'v',
|
|
105
|
+
0x1d4e6:'w', 0x1d4e7:'x', 0x1d4e8:'y', 0x1d4e9:'z',
|
|
106
|
+
0x1d504:'a', 0x1d505:'b', 0x1d507:'d', 0x1d508:'e',
|
|
107
|
+
0x1d509:'f', 0x1d50a:'g', 0x1d50d:'j', 0x1d50e:'k',
|
|
108
|
+
0x1d50f:'l', 0x1d510:'m', 0x1d511:'n', 0x1d512:'o',
|
|
109
|
+
0x1d513:'p', 0x1d514:'q', 0x1d516:'s', 0x1d517:'t',
|
|
110
|
+
0x1d518:'u', 0x1d519:'v', 0x1d51a:'w', 0x1d51b:'x',
|
|
111
|
+
0x1d51c:'y', 0x1d538:'a', 0x1d539:'b', 0x1d53b:'d',
|
|
112
|
+
0x1d53c:'e', 0x1d53d:'f', 0x1d53e:'g', 0x1d540:'i',
|
|
113
|
+
0x1d541:'j', 0x1d542:'k', 0x1d543:'l', 0x1d544:'m',
|
|
114
|
+
0x1d546:'o', 0x1d54a:'s', 0x1d54b:'t', 0x1d54c:'u',
|
|
115
|
+
0x1d54d:'v', 0x1d54e:'w', 0x1d54f:'x', 0x1d550:'y',
|
|
116
|
+
0x1d56c:'a', 0x1d56d:'b', 0x1d56e:'c', 0x1d56f:'d',
|
|
117
|
+
0x1d570:'e', 0x1d571:'f', 0x1d572:'g', 0x1d573:'h',
|
|
118
|
+
0x1d574:'i', 0x1d575:'j', 0x1d576:'k', 0x1d577:'l',
|
|
119
|
+
0x1d578:'m', 0x1d579:'n', 0x1d57a:'o', 0x1d57b:'p',
|
|
120
|
+
0x1d57c:'q', 0x1d57d:'r', 0x1d57e:'s', 0x1d57f:'t',
|
|
121
|
+
0x1d580:'u', 0x1d581:'v', 0x1d582:'w', 0x1d583:'x',
|
|
122
|
+
0x1d584:'y', 0x1d585:'z', 0x1d5a0:'a', 0x1d5a1:'b',
|
|
123
|
+
0x1d5a2:'c', 0x1d5a3:'d', 0x1d5a4:'e', 0x1d5a5:'f',
|
|
124
|
+
0x1d5a6:'g', 0x1d5a7:'h', 0x1d5a8:'i', 0x1d5a9:'j',
|
|
125
|
+
0x1d5aa:'k', 0x1d5ab:'l', 0x1d5ac:'m', 0x1d5ad:'n',
|
|
126
|
+
0x1d5ae:'o', 0x1d5af:'p', 0x1d5b0:'q', 0x1d5b1:'r',
|
|
127
|
+
0x1d5b2:'s', 0x1d5b3:'t', 0x1d5b4:'u', 0x1d5b5:'v',
|
|
128
|
+
0x1d5b6:'w', 0x1d5b7:'x', 0x1d5b8:'y', 0x1d5b9:'z',
|
|
129
|
+
0x1d5d4:'a', 0x1d5d5:'b', 0x1d5d6:'c', 0x1d5d7:'d',
|
|
130
|
+
0x1d5d8:'e', 0x1d5d9:'f', 0x1d5da:'g', 0x1d5db:'h',
|
|
131
|
+
0x1d5dc:'i', 0x1d5dd:'j', 0x1d5de:'k', 0x1d5df:'l',
|
|
132
|
+
0x1d5e0:'m', 0x1d5e1:'n', 0x1d5e2:'o', 0x1d5e3:'p',
|
|
133
|
+
0x1d5e4:'q', 0x1d5e5:'r', 0x1d5e6:'s', 0x1d5e7:'t',
|
|
134
|
+
0x1d5e8:'u', 0x1d5e9:'v', 0x1d5ea:'w', 0x1d5eb:'x',
|
|
135
|
+
0x1d5ec:'y', 0x1d5ed:'z', 0x1d608:'a', 0x1d609:'b',
|
|
136
|
+
0x1d60a:'c', 0x1d60b:'d', 0x1d60c:'e', 0x1d60d:'f',
|
|
137
|
+
0x1d60e:'g', 0x1d60f:'h', 0x1d610:'i', 0x1d611:'j',
|
|
138
|
+
0x1d612:'k', 0x1d613:'l', 0x1d614:'m', 0x1d615:'n',
|
|
139
|
+
0x1d616:'o', 0x1d617:'p', 0x1d618:'q', 0x1d619:'r',
|
|
140
|
+
0x1d61a:'s', 0x1d61b:'t', 0x1d61c:'u', 0x1d61d:'v',
|
|
141
|
+
0x1d61e:'w', 0x1d61f:'x', 0x1d620:'y', 0x1d621:'z',
|
|
142
|
+
0x1d63c:'a', 0x1d63d:'b', 0x1d63e:'c', 0x1d63f:'d',
|
|
143
|
+
0x1d640:'e', 0x1d641:'f', 0x1d642:'g', 0x1d643:'h',
|
|
144
|
+
0x1d644:'i', 0x1d645:'j', 0x1d646:'k', 0x1d647:'l',
|
|
145
|
+
0x1d648:'m', 0x1d649:'n', 0x1d64a:'o', 0x1d64b:'p',
|
|
146
|
+
0x1d64c:'q', 0x1d64d:'r', 0x1d64e:'s', 0x1d64f:'t',
|
|
147
|
+
0x1d650:'u', 0x1d651:'v', 0x1d652:'w', 0x1d653:'x',
|
|
148
|
+
0x1d654:'y', 0x1d655:'z', 0x1d670:'a', 0x1d671:'b',
|
|
149
|
+
0x1d672:'c', 0x1d673:'d', 0x1d674:'e', 0x1d675:'f',
|
|
150
|
+
0x1d676:'g', 0x1d677:'h', 0x1d678:'i', 0x1d679:'j',
|
|
151
|
+
0x1d67a:'k', 0x1d67b:'l', 0x1d67c:'m', 0x1d67d:'n',
|
|
152
|
+
0x1d67e:'o', 0x1d67f:'p', 0x1d680:'q', 0x1d681:'r',
|
|
153
|
+
0x1d682:'s', 0x1d683:'t', 0x1d684:'u', 0x1d685:'v',
|
|
154
|
+
0x1d686:'w', 0x1d687:'x', 0x1d688:'y', 0x1d689:'z',
|
|
155
|
+
0x1d6a8:'\u03b1', 0x1d6a9:'\u03b2', 0x1d6aa:'\u03b3', 0x1d6ab:'\u03b4',
|
|
156
|
+
0x1d6ac:'\u03b5', 0x1d6ad:'\u03b6', 0x1d6ae:'\u03b7', 0x1d6af:'\u03b8',
|
|
157
|
+
0x1d6b0:'\u03b9', 0x1d6b1:'\u03ba', 0x1d6b2:'\u03bb', 0x1d6b3:'\u03bc',
|
|
158
|
+
0x1d6b4:'\u03bd', 0x1d6b5:'\u03be', 0x1d6b6:'\u03bf', 0x1d6b7:'\u03c0',
|
|
159
|
+
0x1d6b8:'\u03c1', 0x1d6b9:'\u03b8', 0x1d6ba:'\u03c3', 0x1d6bb:'\u03c4',
|
|
160
|
+
0x1d6bc:'\u03c5', 0x1d6bd:'\u03c6', 0x1d6be:'\u03c7', 0x1d6bf:'\u03c8',
|
|
161
|
+
0x1d6c0:'\u03c9', 0x1d6d3:'\u03c3', 0x1d6e2:'\u03b1', 0x1d6e3:'\u03b2',
|
|
162
|
+
0x1d6e4:'\u03b3', 0x1d6e5:'\u03b4', 0x1d6e6:'\u03b5', 0x1d6e7:'\u03b6',
|
|
163
|
+
0x1d6e8:'\u03b7', 0x1d6e9:'\u03b8', 0x1d6ea:'\u03b9', 0x1d6eb:'\u03ba',
|
|
164
|
+
0x1d6ec:'\u03bb', 0x1d6ed:'\u03bc', 0x1d6ee:'\u03bd', 0x1d6ef:'\u03be',
|
|
165
|
+
0x1d6f0:'\u03bf', 0x1d6f1:'\u03c0', 0x1d6f2:'\u03c1', 0x1d6f3:'\u03b8',
|
|
166
|
+
0x1d6f4:'\u03c3', 0x1d6f5:'\u03c4', 0x1d6f6:'\u03c5', 0x1d6f7:'\u03c6',
|
|
167
|
+
0x1d6f8:'\u03c7', 0x1d6f9:'\u03c8', 0x1d6fa:'\u03c9', 0x1d70d:'\u03c3',
|
|
168
|
+
0x1d71c:'\u03b1', 0x1d71d:'\u03b2', 0x1d71e:'\u03b3', 0x1d71f:'\u03b4',
|
|
169
|
+
0x1d720:'\u03b5', 0x1d721:'\u03b6', 0x1d722:'\u03b7', 0x1d723:'\u03b8',
|
|
170
|
+
0x1d724:'\u03b9', 0x1d725:'\u03ba', 0x1d726:'\u03bb', 0x1d727:'\u03bc',
|
|
171
|
+
0x1d728:'\u03bd', 0x1d729:'\u03be', 0x1d72a:'\u03bf', 0x1d72b:'\u03c0',
|
|
172
|
+
0x1d72c:'\u03c1', 0x1d72d:'\u03b8', 0x1d72e:'\u03c3', 0x1d72f:'\u03c4',
|
|
173
|
+
0x1d730:'\u03c5', 0x1d731:'\u03c6', 0x1d732:'\u03c7', 0x1d733:'\u03c8',
|
|
174
|
+
0x1d734:'\u03c9', 0x1d747:'\u03c3', 0x1d756:'\u03b1', 0x1d757:'\u03b2',
|
|
175
|
+
0x1d758:'\u03b3', 0x1d759:'\u03b4', 0x1d75a:'\u03b5', 0x1d75b:'\u03b6',
|
|
176
|
+
0x1d75c:'\u03b7', 0x1d75d:'\u03b8', 0x1d75e:'\u03b9', 0x1d75f:'\u03ba',
|
|
177
|
+
0x1d760:'\u03bb', 0x1d761:'\u03bc', 0x1d762:'\u03bd', 0x1d763:'\u03be',
|
|
178
|
+
0x1d764:'\u03bf', 0x1d765:'\u03c0', 0x1d766:'\u03c1', 0x1d767:'\u03b8',
|
|
179
|
+
0x1d768:'\u03c3', 0x1d769:'\u03c4', 0x1d76a:'\u03c5', 0x1d76b:'\u03c6',
|
|
180
|
+
0x1d76c:'\u03c7', 0x1d76d:'\u03c8', 0x1d76e:'\u03c9', 0x1d781:'\u03c3',
|
|
181
|
+
0x1d790:'\u03b1', 0x1d791:'\u03b2', 0x1d792:'\u03b3', 0x1d793:'\u03b4',
|
|
182
|
+
0x1d794:'\u03b5', 0x1d795:'\u03b6', 0x1d796:'\u03b7', 0x1d797:'\u03b8',
|
|
183
|
+
0x1d798:'\u03b9', 0x1d799:'\u03ba', 0x1d79a:'\u03bb', 0x1d79b:'\u03bc',
|
|
184
|
+
0x1d79c:'\u03bd', 0x1d79d:'\u03be', 0x1d79e:'\u03bf', 0x1d79f:'\u03c0',
|
|
185
|
+
0x1d7a0:'\u03c1', 0x1d7a1:'\u03b8', 0x1d7a2:'\u03c3', 0x1d7a3:'\u03c4',
|
|
186
|
+
0x1d7a4:'\u03c5', 0x1d7a5:'\u03c6', 0x1d7a6:'\u03c7', 0x1d7a7:'\u03c8',
|
|
187
|
+
0x1d7a8:'\u03c9', 0x1d7bb:'\u03c3', }
|
|
188
|
+
|
|
189
|
+
def map_table_b3(code):
|
|
190
|
+
r = b3_exceptions.get(ord(code))
|
|
191
|
+
if r is not None: return r
|
|
192
|
+
return code.lower()
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
def map_table_b2(a):
|
|
196
|
+
al = map_table_b3(a)
|
|
197
|
+
b = unicodedata.normalize("NFKC", al)
|
|
198
|
+
bl = "".join([map_table_b3(ch) for ch in b])
|
|
199
|
+
c = unicodedata.normalize("NFKC", bl)
|
|
200
|
+
if b != c:
|
|
201
|
+
return c
|
|
202
|
+
else:
|
|
203
|
+
return al
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
def in_table_c11(code):
|
|
207
|
+
return code == " "
|
|
208
|
+
|
|
209
|
+
|
|
210
|
+
def in_table_c12(code):
|
|
211
|
+
return unicodedata.category(code) == "Zs" and code != " "
|
|
212
|
+
|
|
213
|
+
def in_table_c11_c12(code):
|
|
214
|
+
return unicodedata.category(code) == "Zs"
|
|
215
|
+
|
|
216
|
+
|
|
217
|
+
def in_table_c21(code):
|
|
218
|
+
return ord(code) < 128 and unicodedata.category(code) == "Cc"
|
|
219
|
+
|
|
220
|
+
c22_specials = set([1757, 1807, 6158, 8204, 8205, 8232, 8233, 65279] + list(range(8288,8292)) + list(range(8298,8304)) + list(range(65529,65533)) + list(range(119155,119163)))
|
|
221
|
+
def in_table_c22(code):
|
|
222
|
+
c = ord(code)
|
|
223
|
+
if c < 128: return False
|
|
224
|
+
if unicodedata.category(code) == "Cc": return True
|
|
225
|
+
return c in c22_specials
|
|
226
|
+
|
|
227
|
+
def in_table_c21_c22(code):
|
|
228
|
+
return unicodedata.category(code) == "Cc" or \
|
|
229
|
+
ord(code) in c22_specials
|
|
230
|
+
|
|
231
|
+
|
|
232
|
+
def in_table_c3(code):
|
|
233
|
+
return unicodedata.category(code) == "Co"
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
def in_table_c4(code):
|
|
237
|
+
c = ord(code)
|
|
238
|
+
if c < 0xFDD0: return False
|
|
239
|
+
if c < 0xFDF0: return True
|
|
240
|
+
return (ord(code) & 0xFFFF) in (0xFFFE, 0xFFFF)
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
def in_table_c5(code):
|
|
244
|
+
return unicodedata.category(code) == "Cs"
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
c6_set = set(range(65529,65534))
|
|
248
|
+
def in_table_c6(code):
|
|
249
|
+
return ord(code) in c6_set
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
c7_set = set(range(12272,12284))
|
|
253
|
+
def in_table_c7(code):
|
|
254
|
+
return ord(code) in c7_set
|
|
255
|
+
|
|
256
|
+
|
|
257
|
+
c8_set = set([832, 833, 8206, 8207] + list(range(8234,8239)) + list(range(8298,8304)))
|
|
258
|
+
def in_table_c8(code):
|
|
259
|
+
return ord(code) in c8_set
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
c9_set = set([917505] + list(range(917536,917632)))
|
|
263
|
+
def in_table_c9(code):
|
|
264
|
+
return ord(code) in c9_set
|
|
265
|
+
|
|
266
|
+
|
|
267
|
+
def in_table_d1(code):
|
|
268
|
+
return unicodedata.bidirectional(code) in ("R","AL")
|
|
269
|
+
|
|
270
|
+
|
|
271
|
+
def in_table_d2(code):
|
|
272
|
+
return unicodedata.bidirectional(code) == "L"
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
__all__ = [
|
|
2
|
+
# Functions
|
|
3
|
+
'calcsize', 'pack', 'pack_into', 'unpack', 'unpack_from',
|
|
4
|
+
'iter_unpack',
|
|
5
|
+
|
|
6
|
+
# Classes
|
|
7
|
+
'Struct',
|
|
8
|
+
|
|
9
|
+
# Exceptions
|
|
10
|
+
'error'
|
|
11
|
+
]
|
|
12
|
+
|
|
13
|
+
from _struct import *
|
|
14
|
+
from _struct import _clearcache
|
|
15
|
+
from _struct import __doc__
|